remove some "$" usage in instructions, theres no good way to escape it in nginx literals
bump to 0.2.4pull/17/head 0.2.4
parent
d9bce2b880
commit
3e71b6fd57
|
@ -35,7 +35,7 @@ docker run --rm --name docker_registry_proxy -it \
|
||||||
-v $(pwd)/docker_mirror_certs:/ca \
|
-v $(pwd)/docker_mirror_certs:/ca \
|
||||||
-e REGISTRIES="k8s.gcr.io gcr.io quay.io your.own.registry another.public.registry" \
|
-e REGISTRIES="k8s.gcr.io gcr.io quay.io your.own.registry another.public.registry" \
|
||||||
-e AUTH_REGISTRIES="auth.docker.io:dockerhub_username:dockerhub_password your.own.registry:username:password" \
|
-e AUTH_REGISTRIES="auth.docker.io:dockerhub_username:dockerhub_password your.own.registry:username:password" \
|
||||||
rpardini/docker-registry-proxy:0.2.3
|
rpardini/docker-registry-proxy:0.2.4
|
||||||
```
|
```
|
||||||
|
|
||||||
Let's say you did this on host `192.168.66.72`, you can then `curl http://192.168.66.72:3128/ca.crt` and get the proxy CA certificate.
|
Let's say you did this on host `192.168.66.72`, you can then `curl http://192.168.66.72:3128/ca.crt` and get the proxy CA certificate.
|
||||||
|
|
14
nginx.conf
14
nginx.conf
|
@ -124,23 +124,13 @@ http {
|
||||||
location /setup/systemd {
|
location /setup/systemd {
|
||||||
add_header "Content-type" "text/plain" always;
|
add_header "Content-type" "text/plain" always;
|
||||||
return 200 '
|
return 200 '
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
if [ ! -d /etc/systemd ]; then
|
if [ ! -d /etc/systemd ]; then
|
||||||
echo "Not a systemd system"
|
echo "Not a systemd system"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $EUID -ne 0 ]]; then
|
|
||||||
echo "Must be root to change system files"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ $(systemctl is-active --quiet docker.service) -ne 0 ]]; then
|
|
||||||
echo "Docker service missing"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
mkdir -p /etc/systemd/system/docker.service.d
|
mkdir -p /etc/systemd/system/docker.service.d
|
||||||
cat << EOD > /etc/systemd/system/docker.service.d/http-proxy.conf
|
cat << EOD > /etc/systemd/system/docker.service.d/http-proxy.conf
|
||||||
[Service]
|
[Service]
|
||||||
|
|
Loading…
Reference in New Issue