diff --git a/CI_CD_PIPELINE_SETUP_GUIDE.md b/CI_CD_PIPELINE_SETUP_GUIDE.md index 2571d23..f03a353 100644 --- a/CI_CD_PIPELINE_SETUP_GUIDE.md +++ b/CI_CD_PIPELINE_SETUP_GUIDE.md @@ -1003,12 +1003,7 @@ docker rmi YOUR_DOMAIN_NAME/APP_NAME/unauthorized:latest exit ``` -**Important**: For Option B, you'll also need to update the registry config file to use your domain: - -```bash -# Update registry config for domain-based setup -sudo sed -i "s/YOUR_ACTUAL_IP_ADDRESS/YOUR_DOMAIN_NAME/g" /opt/APP_NAME/registry/config.yml -``` +**Important**: For Option B, the registry configuration is handled via environment variables in the Docker Compose file, so no additional configuration changes are needed. **Expected behavior**: - ✅ Push requires authentication with `registry-user` credentials on port 4443 diff --git a/registry/README.md b/registry/README.md index 7b2b14a..cc649be 100644 --- a/registry/README.md +++ b/registry/README.md @@ -6,7 +6,7 @@ This folder contains the configuration files for the Docker Registry setup used - **`docker-compose.registry.yml`**: Docker Compose configuration for the registry and Caddy reverse proxy - **`Caddyfile`**: Caddy configuration for HTTPS and authentication -- **`config.yml`**: Docker Registry configuration file +- **`docker-registry.service`**: Systemd service file for Docker Registry - **`README.md`**: This documentation file ## Architecture @@ -14,7 +14,7 @@ This folder contains the configuration files for the Docker Registry setup used The registry setup uses: - **Docker Registry**: Basic registry for storing Docker images - **Caddy**: Reverse proxy with automatic HTTPS and authentication -- **Environment Variables**: For authentication credentials +- **Environment Variables**: For authentication credentials and registry configuration - **Service User**: The registry and Caddy services run as the existing `CI_SERVICE_USER` (not a separate registry user) ## Authentication Model @@ -38,11 +38,12 @@ The registry setup uses: ## Configuration The setup is configured through: -1. **Environment Variables**: Stored in `.env` file (created during setup) -2. **Caddyfile**: Handles HTTPS and authentication -3. **Docker Compose**: Orchestrates the registry and Caddy services -4. **Registry Config**: `config.yml` contains the Docker Registry configuration -5. **User/Permissions**: All files and services are owned and run by `CI_SERVICE_USER` for consistency and security +1. **Environment Variables**: Stored in `.env` file (created during setup) for authentication +2. **Docker Compose Environment**: Registry configuration via environment variables +3. **Caddyfile**: Handles HTTPS and authentication +4. **Docker Compose**: Orchestrates the registry and Caddy services +5. **Systemd Service**: Manages the Docker Registry service lifecycle +6. **User/Permissions**: All files and services are owned and run by `CI_SERVICE_USER` for consistency and security ## Usage diff --git a/registry/config.yml b/registry/config.yml deleted file mode 100644 index 09d7a38..0000000 --- a/registry/config.yml +++ /dev/null @@ -1,12 +0,0 @@ -version: 0.1 -log: - level: debug -storage: - filesystem: - rootdirectory: /var/lib/registry - delete: - enabled: true -http: - addr: :5000 - headers: - X-Content-Type-Options: [nosniff] \ No newline at end of file