summaryrefslogtreecommitdiffstats
path: root/roles/docker/defaults
diff options
context:
space:
mode:
authorMichael Gugino <mgugino@redhat.com>2017-08-24 17:24:41 -0400
committerMichael Gugino <mgugino@redhat.com>2017-09-21 15:27:28 -0400
commitb35272a794a572f60034293dd8cb7f057cf3fc8c (patch)
tree638339fb7d7b9b9bbc64326a4c0c160d9405a063 /roles/docker/defaults
parent457e0f80784820b9ff0fb6a7407c271731f5b1d9 (diff)
downloadopenshift-b35272a794a572f60034293dd8cb7f057cf3fc8c.tar.gz
openshift-b35272a794a572f60034293dd8cb7f057cf3fc8c.tar.bz2
openshift-b35272a794a572f60034293dd8cb7f057cf3fc8c.tar.xz
openshift-b35272a794a572f60034293dd8cb7f057cf3fc8c.zip
Move additional/block/insecure registires to /etc/containers/registries.conf
This commit moves additional/block/insecure registries to /etc/containers/registries.conf and comments existing lines in /etc/sysconfig/docker. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1460930
Diffstat (limited to 'roles/docker/defaults')
-rw-r--r--roles/docker/defaults/main.yml14
1 files changed, 14 insertions, 0 deletions
diff --git a/roles/docker/defaults/main.yml b/roles/docker/defaults/main.yml
index 7e206ded1..273919062 100644
--- a/roles/docker/defaults/main.yml
+++ b/roles/docker/defaults/main.yml
@@ -4,3 +4,17 @@ docker_cli_auth_config_path: '/root/.docker'
oreg_url: ''
oreg_host: "{{ oreg_url.split('/')[0] if '.' in oreg_url.split('/')[0] else '' }}"
oreg_auth_credentials_replace: False
+
+openshift_docker_additional_registries: []
+openshift_docker_blocked_registries: []
+openshift_docker_insecure_registries: []
+
+# The l2_docker_* variables convert csv strings to lists, if
+# necessary. These variables should be used in place of their respective
+# openshift_docker_* counterparts to ensure the properly formatted lists are
+# utilized.
+l2_docker_additional_registries: "{% if openshift_docker_additional_registries is string %}{% if openshift_docker_additional_registries == '' %}[]{% elif ',' in openshift_docker_additional_registries %}{{ openshift_docker_additional_registries.split(',') | list }}{% else %}{{ [ openshift_docker_additional_registries ] }}{% endif %}{% else %}{{ openshift_docker_additional_registries }}{% endif %}"
+l2_docker_blocked_registries: "{% if openshift_docker_blocked_registries is string %}{% if openshift_docker_blocked_registries == '' %}[]{% elif ',' in openshift_docker_blocked_registries %}{{ openshift_docker_blocked_registries.split(',') | list }}{% else %}{{ [ openshift_docker_blocked_registries ] }}{% endif %}{% else %}{{ openshift_docker_blocked_registries }}{% endif %}"
+l2_docker_insecure_registries: "{% if openshift_docker_insecure_registries is string %}{% if openshift_docker_insecure_registries == '' %}[]{% elif ',' in openshift_docker_insecure_registries %}{{ openshift_docker_insecure_registries.split(',') | list }}{% else %}{{ [ openshift_docker_insecure_registries ] }}{% endif %}{% else %}{{ openshift_docker_insecure_registries }}{% endif %}"
+
+containers_registries_conf_path: /etc/containers/registries.conf