LUNA_WORK="/home/ubuntu/luna_workspace"
echo ${LUNA_WORK}
mkdir -p ${LUNA_WORK}
HARBOR_VERSION="v2.12.2"
wget -P ${LUNA_WORK} https://github.com/goharbor/harbor/releases/download/${HARBOR_VERSION}/harbor-offline-installer-${HARBOR_VERSION}.tgz
ls -al ${LUNA_WORK}/harbor-offline-installer-${HARBOR_VERSION}.tgz
tar -xvzf ${LUNA_WORK}/harbor-offline-installer-${HARBOR_VERSION}.tgz -C ${LUNA_WORK}
cp ${LUNA_WORK}/harbor/harbor.yml.tmpl ${LUNA_WORK}/harbor/harbor.yml
cp harbor/harbor.yml.tmpl harbor/harbor.yml
harbor.yml 설정 파일 수정cp ${LUNA_WORK}/harbor/harbor.yml.tmpl ${LUNA_WORK}/harbor/harbor.yml
cp harbor/harbor.yml.tmpl harbor/harbor.yml
vim ${LUNA_WORK}/harbor/harbor.yml
vi ${LUNA_WORK}/harbor/harbor.yml
`
hostname: <VM_IP>
http:
port: 5000
# https:
# port: 443
# certificate: /path/to/cert
# private_key: /path/to/key
harbor_admin_password: Luna@2025
database:
password: Luna@2025
`
<VM_IP> 부분을 실제 VM의 IP로 변경 (curl ifconfig.me)
sudo ${LUNA_WORK}/harbor/install.sh
sudo docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
b088510a2025 goharbor/harbor-jobservice:v2.12.2 "/harbor/entrypoint.…" 22 seconds ago Up 15 seconds (health: starting) harbor-jobservice
3a77f8eb3487 goharbor/nginx-photon:v2.12.2 "nginx -g 'daemon of…" 22 seconds ago Up 20 seconds (health: starting) 0.0.0.0:5000->8080/tcp, [::]:5000->8080/tcp nginx
3e0ea05f300d goharbor/harbor-core:v2.12.2 "/harbor/entrypoint.…" 22 seconds ago Up 20 seconds (health: starting) harbor-core
61bdb4670e89 goharbor/harbor-db:v2.12.2 "/docker-entrypoint.…" 22 seconds ago Up 21 seconds (health: starting) harbor-db
43c060c2dc8d goharbor/harbor-portal:v2.12.2 "nginx -g 'daemon of…" 22 seconds ago Up 21 seconds (health: starting) harbor-portal
65d3215e476a goharbor/registry-photon:v2.12.2 "/home/harbor/entryp…" 22 seconds ago Up 21 seconds (health: starting) registry
a334b017a862 goharbor/harbor-registryctl:v2.12.2 "/home/harbor/start.…" 22 seconds ago Up 21 seconds (health: starting) registryctl
daf80484b857 goharbor/redis-photon:v2.12.2 "redis-server /etc/r…" 22 seconds ago Up 21 seconds (health: starting) redis
41f27ce59720 goharbor/harbor-log:v2.12.2 "/bin/sh -c /usr/loc…" 22 seconds ago Up 21 seconds (health: starting) 127.0.0.1:1514->10514/tcp harbor-log
a839f9a743d5 hello-world "/hello" 8 minutes ago Exited (0) 8 minutes ago dazzling_mahavira
브라우저에서 http://<VM_IP>:5000 접속
로그인 정보:
새 프로젝트 클릭luna-devops-project