
The Vultr Container Registry (VCR) is a managed container image repository that supports the Open Container Initiative (OCI) format. It provides a secure and scalable platform for storing and distributing container images across global infrastructure. Compared to DigitalOcean Container Registry (DOCR), VCR offers enhanced performance, competitive pricing, and improved integration with Kubernetes environments.
In this guide, you will migrate container images from DigitalOcean to the Vultr Container Registry. You will use both Docker and skopeo to perform single-image and bulk transfers between registries. The process includes authentication, tagging, pushing, and verifying your migrated images.
Before you begin:
Follow the steps below to authenticate with DigitalOcean, list available images in your container registry, and prepare for migration.
Log in to your migration workstation via SSH.
Install the DigitalOcean CLI (doctl):
Authenticate doctl using your API token:
Generate your API token from the DigitalOcean dashboard and paste it when prompted.
Allow doctl to interact with Docker (required if installed via Snap):
Log in to your DigitalOcean Container Registry.
List all repositories and images available in your registry.
Identify the images you want to migrate and note their names and tags.
Before migrating, ensure your Vultr Container Registry is set up with push access.
For a full walkthrough of VCR configuration, refer to the Vultr Container Registry Product Documentation.
This section shows how to migrate one container image from DigitalOcean Container Registry to Vultr Container Registry using Docker commands.
Pull an image (for example, ubuntu) from your DigitalOcean registry. Replace <your-docr> with your actual registry name:
This command downloads the ubuntu image from the DigitalOcean registry to your migration workstation.
Verify that the image exists locally.
Tag the image for the Vultr registry.
Replace <your-vcr> with your actual Vultr registry URL.
Verify that the new tag was applied.
Output.
Log in to Vultr Container Registry.
Push the image to the Vultr registry.
Remove the local copy to save disk space (optional).
Pull the image from Vultr to verify it's available.
Run the container to verify the image works.
Verify the running container:
Output.
This confirms that the image was successfully migrated and runs correctly from the Vultr Container Registry.
Automate multi-image migrations by fetching image names from DigitalOcean Container Registry using doctl and looping through them in a Bash script. This approach reduces manual effort when transferring multiple repositories.
Log in to your Vultr Container Registry.
Replace <your-vcr> and <credentials> with your actual registry URL and credentials.
Create a migration shell script to automate the migration process.
Add the following content to the script.
Replace <your-docr> and <your-vcr> with your actual DigitalOcean and Vultr registry names.
This script retrieves all image names from your DigitalOcean Container Registry using doctl, then loops through each image to:
Save and run the script.
Verify that all images are available in your Vultr Container Registry.
Output:
skopeo for Direct Registry Transfersskopeo is an efficient alternative to Docker for registry-to-registry transfers. Use it when you want to avoid local disk usage or integrate into CI/CD pipelines.
After migrating your images, verify their availability and functionality to ensure a successful transition.
Pull the image from the Vultr Container Registry.
Run a container from the pulled image to verify it works.
Verify that the container is running.
Output.
This confirms that the image was pushed successfully and runs as expected from the Vultr Container Registry.
After confirming that your images work on Vultr, update your Kubernetes, Docker Compose, and CI/CD configurations to use the new image paths.
Update your Kubernetes manifests to use the Vultr Container Registry.
Update your Docker Compose files.
Update your CI/CD pipelines (e.g., GitHub Actions, GitLab CI) to pull images from the new registry.
Remove or deprecate the old DigitalOcean Container Registry if it's no longer needed.
Monitor your application's performance and logs to ensure services operate normally.
Periodically pull and run images from Vultr to validate that they remain functional and uncorrupted.
You've successfully migrated container images from the DigitalOcean Container Registry to the Vultr Container Registry using Docker or skopeo. Always test your images after migration and update your deployments accordingly. To learn more about managing your container images on Vultr, see the Vultr Container Registry Reference Guide.
0 Comments
Be the first to comment and share your perspective with the community.