aboutsummaryrefslogtreecommitdiffstats
path: root/docker
diff options
context:
space:
mode:
authorMartin André <m.andre@redhat.com>2016-09-06 14:58:00 +0200
committerMartin André <m.andre@redhat.com>2016-10-06 11:14:20 +0200
commit704a78d342ad1a735e50f29768d15636b866fc98 (patch)
tree4c8faed3d73a0a75ad74d3dec8615355bd33c108 /docker
parentc3611e0f701a2b104d52125861b27da44a6c7763 (diff)
Be more inclusive in insecure registry regex
The regex failed to match the INSECURE_REGISTRY string used in latest atomic host image due to it expecting a whitespace after --insecure-registry. Change-Id: Ib8f288d844b4d94b0f6309bfd04bb05930d8c4c5
Diffstat (limited to 'docker')
-rw-r--r--docker/firstboot/start_docker_agents.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/docker/firstboot/start_docker_agents.sh b/docker/firstboot/start_docker_agents.sh
index 65c4e6dc..68625032 100644
--- a/docker/firstboot/start_docker_agents.sh
+++ b/docker/firstboot/start_docker_agents.sh
@@ -23,7 +23,7 @@ if [ $docker_namespace_is_registry ]; then
# if namespace is used with local registry, trim all namespacing
trim_var=$docker_registry
registry_host="${trim_var%%/*}"
- /bin/sed -i "s/# INSECURE_REGISTRY='--insecure-registry[ ]'/INSECURE_REGISTRY='--insecure-registry $registry_host'/g" /etc/sysconfig/docker
+ /bin/sed -i -r "s/^[# ]*INSECURE_REGISTRY *=.+$/INSECURE_REGISTRY='--insecure-registry $registry_host'/" /etc/sysconfig/docker
/usr/bin/systemctl start --no-block docker.service
fi