When building your application, you have the option to use the Replicated private registry, or any supported external private or public registry.
Replicated Registry
Every application created in Replicated has a private, completely isolated Docker registry available. You can push images to your private registry by finding the endpoint at (https://vendor.replicated.com/#/images) and using the Docker CLI to tag and push images. When using the Swarm Scheduler, Replicated will be able to automatically use the customer license file to authenticate and pull any images from the Replicated Registry.
Tagging Images
The first thing you will need to do is tag your image. Replicated accepts images in the standard Docker format: registry.replicated.com/<application-slug>/<image-name>:<version>
. You can find your application slug on the Images page of the Replicated Vendor Portal.
An example of tagging an existing image is:
$ sudo docker tag worker registry.replicated.com/myapp/worker:1.0.1
Logging In
Next you will need to log into the Replicated private registry with your account credentials. When prompted, you will use your email address for your username.
$ sudo docker login registry.replicated.com
Username: my@mycompany.com
Password: <your password>
Login Succeeded
Pushing Images
Finally you can push your image to the Replicated private registry.
$ sudo docker push registry.replicated.com/myapp/worker:1.0.1
The push refers to a repository [registry.replicated.com/myapp/worker] (len: 1)
Sending image list
Pushing repository registry.replicated.com/myapp/worker (1 tags)
07595b42e5d5: Image successfully pushed
f9910c2fd14a: Image successfully pushed
4f409c5d1046: Image successfully pushed
8e471642d573: Image successfully pushed
Pushing tag for rev [8e471642d573] on {https://registry.replicated.com/v1/repositories/myapp/worker/tags/1.0.1}
For additional information on building, tagging and pushing docker images, please refer to the Docker CLI Documentation.
Using External Registries
When using Docker Swarm, Replicated supports pulling public, unauthenticated images from any Docker registry that supports the standard Docker Registry HTTP API.
Additionally, Replicated supports private images hosted in other registries including Docker Hub, Quay.io and more.
To use private images from an external registry, you need to add the registry via the Vendor website. The guide for integrating a third party registry explains this in further detail. You’ll also need to declare any external registry images in an images
section in your Replicated YAML.
Declaring Images
To include images in your application, you’ll need to add them to your YAML as follows.
All public and private images included in your Swarm application must be specified in this images
section of your YAML in order to be included in the airgap bundle your customer will download and install.
images:
- source: mythirdpartyprivateregistry
name: namespace/imagename
tag: 2.0.0
- source: public
name: redis
tag: 3.2-alpine
- source: public
name: postgres
tag: 9.4
- source: replicated
name: app
tag: v1