|
| 1 | +--- |
| 2 | +title: "End Of Life (EOL) Harbor 1.x - How to replicate and migrate your data to Harbor 2.x" |
| 3 | +excerpt: "Find out how to replicate an old private registry (in Harbor 1.x) to a recent OVHcloud Managed Private Registry (in Harbor 2.x)" |
| 4 | +slug: eol-harbor-v1x |
| 5 | +section: 'Getting started' |
| 6 | +order: 06 |
| 7 | +routes: |
| 8 | + canonical: 'https://docs.ovh.com/gb/en/private-registry/eol-harbor-1.x/' |
| 9 | +updated: 2023-03-10 |
| 10 | +--- |
| 11 | + |
| 12 | +**Last updated 10th March, 2023.** |
| 13 | + |
| 14 | +<style> |
| 15 | + pre { |
| 16 | + font-size: 14px; |
| 17 | + } |
| 18 | + pre.console { |
| 19 | + background-color: #300A24; |
| 20 | + color: #ccc; |
| 21 | + font-family: monospace; |
| 22 | + padding: 5px; |
| 23 | + margin-bottom: 5px; |
| 24 | + } |
| 25 | + pre.console code { |
| 26 | + border: solid 0px transparent; |
| 27 | + color: #ccc; |
| 28 | + font-family: monospace !important; |
| 29 | + font-size: 0.75em; |
| 30 | + } |
| 31 | + .small { |
| 32 | + font-size: 0.75em; |
| 33 | + } |
| 34 | +</style> |
| 35 | + |
| 36 | +## Objective |
| 37 | + |
| 38 | +The OVHcloud Managed Private Registry service provides you a managed, authenticated Docker registry where you can privately store your Docker images. |
| 39 | + |
| 40 | +Managed Private Registry is built on Open Source solutions such as Docker and the CNCF Harbor project, to guarantee its interoperability. |
| 41 | + |
| 42 | +The Managed Private Registries based on Harbor 1.x will terminate on August 1st 2023. The aim of this guide is to show you how to create a new private registry (based on Harbor 2.x) and migrate your data from your 1.x private registry to this new one. |
| 43 | + |
| 44 | +## Instructions |
| 45 | + |
| 46 | +First, follow the guide [Creating a private registry](https://docs.ovh.com/de/private-registry/creating-a-private-registry/) to create a new private registry named `my-new-registry` for example, with the latest version of Harbor. |
| 47 | + |
| 48 | + |
| 49 | + |
| 50 | +Follow the guide [Connecting to the UI](https://docs.ovh.com/gb/en/private-registry/connecting-to-the-ui/) to connect to your new private registry. |
| 51 | + |
| 52 | +Now you will configure a replication between your old private registry (in Harbor 1.x) and the new one. |
| 53 | + |
| 54 | +In the `Administration` menu, click on `Registries`{.action}. |
| 55 | + |
| 56 | +{.thumbnail} |
| 57 | + |
| 58 | +Click on `New endpoint`{.action} button to create a replication endpoint. |
| 59 | + |
| 60 | +Now fill the form with the following information: |
| 61 | + |
| 62 | +- Provider: `Harbor` |
| 63 | +- Name: `harbor-1.10` |
| 64 | +- Endpoint URL: `<your Harbor 1.10 URL (https://xxxxxxxx.grax.container-registry.ovh.net/)>` |
| 65 | +- Access ID: `<Harbor 1.10 username>` |
| 66 | +- Access secret: `<Harbor 1.10 password>` |
| 67 | + |
| 68 | +{.thumbnail} |
| 69 | + |
| 70 | +Click on the button `Test connection`{.action} to ping the private registry and test your information. |
| 71 | + |
| 72 | +{.thumbnail} |
| 73 | + |
| 74 | +Click on the button `OK`{.action} to save your information. |
| 75 | + |
| 76 | +{.thumbnail} |
| 77 | + |
| 78 | +In the `Administration` menu, click on `Replications`{.action}. |
| 79 | + |
| 80 | +{.thumbnail} |
| 81 | + |
| 82 | +Click on the button `New replication rule`{.action} to create a new rule. |
| 83 | + |
| 84 | +Now fill the form with the following information: |
| 85 | + |
| 86 | +- Name: `harbor-1.10` |
| 87 | +- Replication mode: `Pull based` |
| 88 | +- Source registry: Select your registry started with `harbor-1.10-*` |
| 89 | +- Trigger mode: `Manual` or `Scheduled` |
| 90 | + |
| 91 | +> [!primary] |
| 92 | +> |
| 93 | +> **Manual**: Replicate the resources manually when needed. |
| 94 | +> |
| 95 | +> **Scheduled**: Replicate the resources periodically by defining a cron job. |
| 96 | +> |
| 97 | +> Note: In both cases, deletion operations are not replicated. |
| 98 | +
|
| 99 | +{.thumbnail} |
| 100 | + |
| 101 | +Click on `Save`{.action} to save your information. |
| 102 | + |
| 103 | +{.thumbnail} |
| 104 | + |
| 105 | +To run manually a replication rule, select your replication rule and click on the `Replicate`{.action} button. |
| 106 | + |
| 107 | +{.thumbnail} |
| 108 | + |
| 109 | +Then click on `Replicate`{.action} to run the replication. |
| 110 | + |
| 111 | +{.thumbnail} |
| 112 | + |
| 113 | +You should be able to see the status of the replication in the `Executions` section. |
| 114 | + |
| 115 | +First your replication should be in the status `InProgress` and then, after waiting a moment (depending on the size of the data to replicate), the status should change to `Succeeded`. |
| 116 | + |
| 117 | +{.thumbnail} |
| 118 | +{.thumbnail} |
| 119 | + |
| 120 | +> [!primary] |
| 121 | +> |
| 122 | +> If you run the same replications several times and you have Helm charts, the replication can fail the second time but it will work. |
| 123 | +
|
| 124 | +Finally, you must reconfigure your Harbor instance (users, robot accounts, garbage collection, retention rules, etc.). |
| 125 | +Once your registry is replicated, change both the Harbor URL and the credentials in your CI/CD and deployment platform if not already done. |
| 126 | + |
| 127 | +## Go further |
| 128 | + |
| 129 | +To have an overview of OVHcloud Managed Private Registry service, you can consult the [OVHcloud Managed Private Registry site](https://docs.ovh.com/de/private-registry/). |
| 130 | + |
| 131 | +Join our community of users on <https://community.ovh.com/en/>. |
0 commit comments