From 1a19f799bd1774607dd2914cf5690390b736e116 Mon Sep 17 00:00:00 2001 From: renzaspiras Date: Tue, 4 Nov 2025 10:17:37 -0800 Subject: [PATCH] adawale --- .env.example | 2 -- README.md | 14 ++++++-------- docker-compose.yml | 8 ++++---- setup.sh | 8 ++++---- 4 files changed, 14 insertions(+), 18 deletions(-) diff --git a/.env.example b/.env.example index f5127f6..055ad36 100644 --- a/.env.example +++ b/.env.example @@ -2,7 +2,6 @@ # Copy this file to .env and customize for your environment # Registry Configuration -REGISTRY_PORT=5000 REGISTRY_STORAGE_PATH=/var/lib/registry REGISTRY_DATA_PATH=./data REGISTRY_LOG_LEVEL=info @@ -20,7 +19,6 @@ REGISTRY_TLS_KEY_PATH=/certs/server.key REGISTRY_TLS_PATH=./certs # UI Configuration -UI_PORT=8080 REGISTRY_TITLE=Docker Registry REGISTRY_URL=http://registry:5000 SINGLE_REGISTRY=true diff --git a/README.md b/README.md index 6522d63..652f52d 100644 --- a/README.md +++ b/README.md @@ -22,16 +22,14 @@ docker-compose up -d ``` 3. Access: -- Registry API: http://localhost:5000 -- Web UI: http://localhost:8080 +- Registry API: http://your-domain:5000 +- Web UI: http://your-domain ## Coolify Deployment In Coolify, set these environment variables as needed: ### Basic Configuration -- `REGISTRY_PORT`: Registry port (default: 5000) -- `UI_PORT`: UI port (default: 8080) - `REGISTRY_TITLE`: Registry title for UI - `REGISTRY_URL`: Internal registry URL @@ -54,18 +52,18 @@ In Coolify, set these environment variables as needed: ### Push an image ```bash -docker tag myimage localhost:5000/myimage -docker push localhost:5000/myimage +docker tag myimage your-domain:5000/myimage +docker push your-domain:5000/myimage ``` ### Pull an image ```bash -docker pull localhost:5000/myimage +docker pull your-domain:5000/myimage ``` ### List images ```bash -curl http://localhost:5000/v2/_catalog +curl http://your-domain:5000/v2/_catalog ``` ## Authentication (Optional) diff --git a/docker-compose.yml b/docker-compose.yml index 5dca9b3..bac6ca1 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,8 +5,8 @@ services: image: registry:2 container_name: registry restart: unless-stopped - ports: - - "${REGISTRY_PORT:-5000}:5000" + expose: + - "5000" environment: - REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY=${REGISTRY_STORAGE_PATH:-/var/lib/registry} - REGISTRY_AUTH=${REGISTRY_AUTH_ENABLED:-false} @@ -27,8 +27,8 @@ services: image: joxit/docker-registry-ui:latest container_name: registry-ui restart: unless-stopped - ports: - - "${UI_PORT:-8080}:80" + expose: + - "80" environment: - SINGLE_REGISTRY=${SINGLE_REGISTRY:-true} - REGISTRY_TITLE=${REGISTRY_TITLE:-Docker Registry} diff --git a/setup.sh b/setup.sh index ec21691..2eddcf4 100755 --- a/setup.sh +++ b/setup.sh @@ -23,11 +23,11 @@ docker-compose up -d echo "" echo "✅ Registry is running!" -echo "📊 Web UI: http://localhost:8080" -echo "🔌 Registry API: http://localhost:5000" +echo "📊 Web UI: http://your-domain" +echo "🔌 Registry API: http://your-domain:5000" echo "" echo "💡 To push an image:" -echo " docker tag myimage localhost:5000/myimage" -echo " docker push localhost:5000/myimage" +echo " docker tag myimage your-domain:5000/myimage" +echo " docker push your-domain:5000/myimage" echo "" echo "📝 Edit .env file to customize configuration" \ No newline at end of file