Docker

Docker registry 구성과 image pull & push

haniru 2025. 11. 14. 01:14

host1 서버

더보기

docker image tag myweb:v1.1 192.168.56.101:5000/myweb:v1.1

curl -X GET http://192.168.56.101:5000/v2/myweb/tags/list

docker push 192.168.56.101:5000/myweb:v1.1

curl -X GET http://192.168.56.101:5000/v2/_catalog

curl -X GET http://192.168.56.101:5000/v2/myweb/tags/list

 

host2 서버 -> 조회는 동일하게 되지만, pull이 안돼서 host1처럼 설정해줌

더보기

curl -X GET http://192.168.56.101:5000/v2/myweb/tags/list

docker pull 192.168.56.101:5000/myweb:v1.0

sudo vi /etc/init.d/docker

sudo vi /etc/docker/daemon.json

sudo systemctl restart docker.service

docker info

docker pull 192.168.56.101:5000/myweb:v1.0

docker images | grep 192

 

host1 서버

더보기

git clone https://github.com/hylee-kevin/fastcampus.git

 

GitHub - hylee-kevin/fastcampus: CI/CD all in one stop: from Docker to GitOps.

CI/CD all in one stop: from Docker to GitOps. Contribute to hylee-kevin/fastcampus development by creating an account on GitHub.

github.com

cd fastcampus

cd ch04

ls

docker build -t phpserver:1.0 .

docker images | grep phpserver

curl localhost:8004

docker image tag phpserver:1.0 192.168.56.101:5000/phpserver:1.0

docker push 192.168.56.101:5000/phpserver:1.0

curl -X GET http://192.168.56.101:5000/v2/_catalog

curl -X GET http://192.168.56.101:5000/v2/myweb/tags/list

host2 서버

더보기

curl -X GET http://192.168.56.101:5000/v2/_catalog

curl -X GET http://192.168.56.101:5000/v2/myweb/tags/list

docker pull 192.168.56.101:5000/phpserver:1.0

docker run -it -d -p 8004:80 -h phpserver --name=phpserver 192.168.56.101:5000/phpserver:1.0

docker ps | grep php

curl localhost:8004

 

로컬 레지스트리 컨테이너 - 가벼운 용량

하버, 넷서스

'Docker' 카테고리의 다른 글

Docker image 관리  (0) 2025.11.14
Docker hub repository에 이미지 푸쉬  (0) 2025.11.04
도커 이미지 확인  (0) 2025.11.03
도커 엔진 업데이트  (0) 2025.11.03
Docker 플랫폼 환경 구성  (0) 2025.11.03