> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/on-premises/ko/user-and-project-management/user-management/username-migration.md).

# 사용자 이름 마이그레이션

## 사용자 이름 마이그레이션

로그인 관점에서 사용자의 기본 식별자는 이메일 주소입니다. 로컬 기반 인증에서 SSO로 마이그레이션하거나 한 IdP에서 다른 IdP로 마이그레이션하는 경우, 사용자 이메일 주소를 업데이트해야 할 수 있습니다.

이를 돕기 위해, 다음 형식의 CSV 파일을 사용하여 사용자 이메일을 마이그레이션하는 스크립트가 제공됩니다:

`oldEmail,newEmail`

몇 가지 검증을 수행한 후, 스크립트는 CSV 파일을 순회하며 다음에서 사용자 이메일 주소를 업데이트합니다. `oldEmail` 에서 `newEmail`.

### **검증**

마이그레이션을 실행하기 전에 `<csv_file>` 다음 사항이 확인됩니다:

* 각 행에 대해, 다음 두 항목 모두 `oldEmail` 및 `newEmail` 유효한 이메일 주소입니다
* 중복 항목이 없습니다. 예를 들어, 서로 다른 사용자들을 동일한 새 이메일 주소로 업데이트하려고 하거나, 이미 사용된 이메일 주소로 동일한 사용자 계정을 업데이트하려고 하지 않아야 합니다

### **사용법** <a href="#usage" id="usage"></a>

{% code overflow="wrap" %}

```bash
docker cp <csv_file> sharelatex:/overleaf/services/web/<csv_file> docker exec sharelatex /bin/bash -c "cd /overleaf/services/web;node ./modules/server-ce-scripts/scripts/migrate-user-emails.js [--commit] [--continue|--ignore-missing] [--admin-id=ADMIN_USER_ID] <csv_file>"
```

{% endcode %}

### **플래그** <a href="#flags" id="flags"></a>

| 이름                 | 설명                                                                                                                                                                       |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `--commit`         | <p>다음의 포함은 <code>--commit</code> 플래그는 실제로 마이그레이션을 수행합니다. 생략하면 마이그레이션은 변경 사항 없이 실행되는 드라이런 모드로 진행되지만, 유효성 검사는 계속 수행됩니다.<br><br><strong>기본값</strong>:<code>false</code></p> |
| `--continue`       | 해당 `--continue` 플래그는 계정의 이메일 주소가 이미 업데이트된 사용자 계정이 있는 경우 마이그레이션 프로세스를 계속합니다                                                                                               |
| `--ignore-missing` | 해당 `--ignore-missing` 플래그는 사용자 계정을 찾지 못한 경우 마이그레이션 프로세스를 계속합니다                                                                                                           |
| `--admin-id`       | 해당 `--admin-id` 마이그레이션을 수행하는 관리자 ID로 설정해야 하며, 감사 로그 항목에 사용됩니다. 다음으로 이동하여 **관리자** > **사용자 관리** 이메일 주소를 검색한 다음 첫 번째 결과를 클릭하여 사용자 ID를 찾으세요.                                 |
| `<csv_file>`       | 해당 `<csv_file>` 는 이전 및 새 이메일 주소가 들어 있는 파일입니다.                                                                                                                            |

### **완료** <a href="#completion" id="completion"></a>

마이그레이션 스크립트를 실행하는 동안 선택한 플래그에 따라 오류가 콘솔에 기록된 후 계속될지, 아니면 콘솔에 기록된 후 종료될지가 결정됩니다. 스크립트가 오류로 인해 조기에 종료되면, 실패를 나타내기 위해 종료 코드 1로 종료됩니다.

마이그레이션이 완료되면 스크립트는 성공, 실패, 건너뜀 업데이트의 수를 콘솔에 기록합니다. 마이그레이션이 성공적으로 완료되면 종료 코드 0으로 종료됩니다.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://overleaf-pro.ayaka.space/on-premises/ko/user-and-project-management/user-management/username-migration.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
