Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kolla Ansible
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Very Demiurge Very Mindful
Kolla Ansible
Commits
11e6b4a8
Commit
11e6b4a8
authored
4 years ago
by
Zuul
Committed by
Gerrit Code Review
4 years ago
Browse files
Options
Downloads
Plain Diff
Merge "docs: Improve multinode Docker registry setup"
parents
db3f0fa0
34cce4c5
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
doc/source/user/multinode.rst
+41
-54
41 additions, 54 deletions
doc/source/user/multinode.rst
with
41 additions
and
54 deletions
doc/source/user/multinode.rst
+
41
−
54
View file @
11e6b4a8
...
...
@@ -18,77 +18,64 @@ registry services.
The Docker registry prior to version 2.3 has extremely bad performance because
all container data is pushed for every image rather than taking advantage of
Docker layering to optimize push operations. For more information reference
`pokey registry <https://github.com/docker/docker/issues/14018>`__.
`pokey registry <https://github.com/docker/docker/issues/14018>`__. The Kolla
community recommends using registry 2.3 or later.
Edit the ``/etc/kolla/globals.yml`` and add the following where 192.168.1.100
is the IP address of the machine and 5000 is the port where the registry is
currently running:
The registry may be configured either as a local registry with support for
storing images, or as a pull-through cache for Docker hub.
.. code-block:: yaml
docker_registry: 192.168.1.100:5000
The Kolla community recommends using registry 2.3 or later. To deploy registry
with version 2.3 or later, do the following:
Option 1: local registry
------------------------
.. code-block:: console
cd kolla
tools/start-registry
The Docker registry can be configured as a pull through cache to proxy the
official Kolla images hosted in Docker Hub. In order to configure the local
registry as a pull through cache, in the host machine set the environment
variable ``REGISTRY_PROXY_REMOTEURL`` to the URL for the repository on
Docker Hub.
.. code-block:: console
export REGISTRY_PROXY_REMOTEURL=https://registry-1.docker.io
.. note::
Pushing to a registry configured as a pull-through cache is unsupported.
For more information, Reference the `Docker Documentation
<https://docs.docker.com/registry/configuration/>`__.
.. _configure_docker_all_nodes:
Configure Docker on all nodes
=============================
.. note::
docker run -d \
--name registry \
--restart=always \
-p 4000:5000 \
-v registry:/var/lib/registry \
registry:2
As the subtitle for this section implies, these steps should be
applied to all nodes, not just the deployment node.
Here we are using port 4000 to avoid a conflict with Keystone. If the registry
is not running on the same host as Keystone, the ``-p`` argument may be
omitted.
After starting the registry, it is necessary to instruct Docker that
it will be communicating with an insecure registry.
For example, To enable insecure registry communication,
modify the ``/etc/docker/daemon.json`` file to contain the following where
``192.168.1.100`` is the IP address of the machine where the registry
is currently running:
Edit ``globals.yml`` and add the following, where ``192.168.1.100:4000`` is the
IP address and port on which the registry is listening:
.. path /etc/docker/daemon.json
.. code-block:: json
.. code-block:: yaml
{
"insecure-registries" : ["192.168.1.100:5000"]
}
docker_registry: 192.168.1.100:4000
Restart Docker by executing the following commands:
Option 2: registry mirror
-------------------------
For CentOS or Ubuntu with systemd:
The Docker registry can be configured as a pull through cache to proxy the
official Kolla images hosted in Docker Hub. In order to configure the local
registry as a pull through cache, pass the environment variable
``REGISTRY_PROXY_REMOTEURL`` through to the registry container. Pushing to a
registry configured as a pull-through cache is unsupported. For more
information, Reference the `Docker Documentation
<https://docs.docker.com/registry/configuration/>`__.
.. code-block:: console
systemctl restart docker
docker run -d \
--name registry \
--restart=always \
-p 4000:5000 \
-v registry:/var/lib/registry \
-e REGISTRY_PROXY_REMOTEURL=https://registry-1.docker.io \
registry:2
For Ubuntu with upstart or sysvinit:
Edit ``globals.yml`` and add the following, where ``192.168.1.100:4000`` is the
IP address and port on which the registry is listening:
.. code-block::
console
.. code-block::
yaml
service docker restart
docker_custom_config:
registry-mirrors:
- 192.168.1.100:4000
.. _edit-inventory:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment