"Docker 프록시 설정하기"의 두 판 사이의 차이

 
(같은 사용자의 중간 판 2개는 보이지 않습니다)
3번째 줄: 3번째 줄:


<syntaxhighlight lang='bash'>
<syntaxhighlight lang='bash'>
sudo -i
mkdir -p /etc/systemd/system/docker.service.d
mkdir -p /etc/systemd/system/docker.service.d
</syntaxhighlight>
</syntaxhighlight>
8번째 줄: 9번째 줄:
cat <<EOF > /etc/systemd/system/docker.service.d/http-proxy.conf
cat <<EOF > /etc/systemd/system/docker.service.d/http-proxy.conf
[Service]
[Service]
Environment="HTTP_PROXY=http://proxy.example.com:80/"
Environment="HTTP_PROXY=http://proxy.example.com:3128"
Environment="HTTPS_PROXY=https://proxy.example.com:3129"
Environment="NO_PROXY=localhost,127.0.0.1,docker-registry.example.com,.corp"
Environment="NO_PROXY=localhost,127.0.0.1,docker-registry.example.com,.corp"
EOF
EOF
15번째 줄: 17번째 줄:
systemctl daemon-reload
systemctl daemon-reload
systemctl restart docker
systemctl restart docker
systemctl show --property=Environment docker | cat
</syntaxhighlight>
</syntaxhighlight>



2024년 4월 26일 (금) 15:52 기준 최신판

1 개요[ | ]

Docker 프록시 설정
sudo -i
mkdir -p /etc/systemd/system/docker.service.d
cat <<EOF > /etc/systemd/system/docker.service.d/http-proxy.conf
[Service]
Environment="HTTP_PROXY=http://proxy.example.com:3128"
Environment="HTTPS_PROXY=https://proxy.example.com:3129"
Environment="NO_PROXY=localhost,127.0.0.1,docker-registry.example.com,.corp"
EOF
systemctl daemon-reload
systemctl restart docker
systemctl show --property=Environment docker | cat

2 같이 보기[ | ]

3 참고[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}