# Copy your repositories from Nexus

> Copy your Nexus 3 repositories into Telesphorepo, keep them in sync, then switch over.

Source: https://docs.telesphorepo.com/move-from-nexus/

The move from Nexus has three parts:

1. **Copy** the repositories into Telesphorepo. This page.
2. **Move** each project, [by hand](/move-projects-by-hand/) or [with an AI agent](/move-projects-with-an-agent/).
3. **Switch over**, so that your builds publish to Telesphorepo.

Your builds keep using Nexus until the switch-over. Telesphorepo only reads from Nexus.

Moving off Nexus has three stages. Before: builds publish to Nexus. During: Telesphorepo copies new uploads from Nexus, and builds still publish to Nexus. After: builds publish to Telesphorepo.

## Copy the repositories

1. Back up Telesphorepo first. See [Back up](/back-up-and-restore/#back-up).

2. Open **Settings › Nexus migration**, and click **Add a Nexus server**.

3. Fill in the form, then click **Add server**:

   - **Name:** a short name, such as `old-nexus`
   - **Address:** such as `https://nexus.example.com`
   - **Username** and **Password:** a Nexus account that can read every repository you copy

4. Under **Repositories to copy**, tick each repository.

5. In **Name here**, type its name in Telesphorepo. In **Who can download**, choose **Public** or **Private**.

6. Click **Copy 3 repositories**. The button counts the repositories you ticked.

The first sync copies every file, and the page shows the progress. Then Telesphorepo checks Nexus for new files every 15 minutes. Click **Sync now** to check at once.

## Move your projects

The copies are read only until the switch-over. Your builds can download from them now.

Each project still names Nexus. Move each one [by hand](/move-projects-by-hand/) or [with an AI agent](/move-projects-with-an-agent/). The addresses change like this:

| Nexus                                                      | Telesphorepo                                        |
| ---------------------------------------------------------- | --------------------------------------------------- |
| `https://nexus.example.com/repository/maven-releases/`     | `https://repo.example.com/maven/maven-releases`     |
| `https://nexus.example.com/repository/npm-hosted/`         | `https://repo.example.com/npm/npm-hosted/`          |
| `https://nexus.example.com/repository/pypi-hosted/simple/` | `https://repo.example.com/pypi/pypi-hosted/simple/` |
| `nexus.example.com:8082/team/app:1.0`                      | `repo.example.com/docker-hosted/team/app:1.0`       |

[Repository addresses](/commands-and-settings/#repository-addresses) has every format.

## Switch over

1. In each project, set up publishing and rehearse it on a test repository. See [Move publishing](/move-projects-by-hand/#move-publishing) and [Rehearse publishing](/move-projects-by-hand/#rehearse-publishing).

2. Stop all publishing to Nexus. A file that reaches Nexus after the final sync is not copied.

3. Open the page of the Nexus server, and click **Switch over**.

4. Read the count of failed files. Then click **Run the final sync and switch over**.

5. In each project, point `telesphorepo.toml` at the real repository, and publish. See [After the switch-over](/move-projects-by-hand/#after-the-switch-over).

After the final sync, the repositories take uploads, and Telesphorepo deletes the saved Nexus password.

You can then delete the Nexus server: click **Delete** on its page. The repositories and their files stay.

## What gets copied

| Nexus         | Telesphorepo                                  |
| ------------- | --------------------------------------------- |
| Maven hosted  | Maven, every file at its path                 |
| npm hosted    | npm, with the dist-tags of Nexus              |
| PyPI hosted   | Python, each wheel and sdist                  |
| Cargo hosted  | Cargo, each crate with its index entry        |
| NuGet hosted  | NuGet, each package                           |
| Docker hosted | Docker, each tag with its layers              |
| Raw hosted    | Raw, every file at its path                   |
| Apt hosted    | Debian, every package in the component `main` |
| A proxy       | A proxy of the same remote                    |
| A group       | A group of the copied members                 |

Proxies and groups work for Maven, npm, PyPI, Cargo, NuGet and Docker. Proxies also work for apt.

## If something goes wrong

Some files failed

A sync goes on when a file fails. The page lists each failed file with the reason.

A common reason is a release file with the same path but other bytes than the copy in Telesphorepo.

Fix failed files before you switch over. After the switch-over, Telesphorepo cannot read Nexus again.

The final sync stopped

A whole repository failed, for example because Nexus did not answer. The repositories stay read only.

Fix the cause, then click **Switch over** again.

A repository cannot be ticked

The table shows the reason next to the repository. A repository that is offline in Nexus cannot be copied.

An apt repository asks for a signing key

Choose the key in the **Signing key** column. Choose the Nexus key to keep the key that your machines trust already.

Nexus does not give the passphrase of its key. Type it in **Passphrase of the Nexus key**, under the table.

New files take too long to arrive

Open **Settings › General**, and lower **Nexus sync interval**. The shortest is 1 minute.
