본문 바로가기
IT/기타

Kubernetis Proxy으로 이미지 다운로드 경로 지정 (config 포함)

by JGSHIN 2025. 2. 18.
SMALL

kubernetis 내부망으로 사용할때, 자꾸 외부에서 다운받으려 해서 내부 레포지토리를 사용하기 위해

프록시 설정을 해줘야 합니다..

 

 

# vi /lib/systemd/system/docker.service

 

서비스 부분에 아래 내용 추가

 

 

[Service]

Type=notify

# the default is not to use systemd for cgroups because the delegate issues still

# exists and systemd currently does not support the cgroup feature set required

# for containers run by docker

ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock

ExecReload=/bin/kill -s HUP $MAINPID

TimeoutStartSec=0

RestartSec=2

Restart=always

 

Environment="HTTP_PROXY=http://ip:3128"

Environment="HTTPS_PROXY=http://ip:3128"

Environment="NO_PROXY=jgshin.co.kr,localhost,127.0.0.1/8,192.168.0.0/16,.local"

 

https:// 아닌 https_proxy http 하면 된다

 

 

 

# systemctl daemon-reload

# systemctl restart docker

LIST
📧 이메일 문의
by @ 2025 JGSHIN