Create registry config.yml as SERVICE_USER too
Some checks are pending
Some checks are pending
This commit is contained in:
parent
02569c8cf4
commit
a4ef13b5dd
1 changed files with 8 additions and 2 deletions
|
@ -440,6 +440,9 @@ sudo chown SERVICE_USER:SERVICE_USER /opt/registry
|
|||
#### 4.2 Create Registry Configuration
|
||||
|
||||
```bash
|
||||
# Switch to SERVICE_USER (registry directory owner)
|
||||
sudo su - SERVICE_USER
|
||||
|
||||
cat > /opt/registry/config.yml << 'EOF'
|
||||
version: 0.1
|
||||
log:
|
||||
|
@ -468,6 +471,9 @@ health:
|
|||
interval: 10s
|
||||
threshold: 3
|
||||
EOF
|
||||
|
||||
# Exit SERVICE_USER shell
|
||||
exit
|
||||
```
|
||||
|
||||
**What this configuration does:**
|
||||
|
@ -476,6 +482,8 @@ EOF
|
|||
- **Security Headers**: Protects against common web vulnerabilities
|
||||
- **No Secret Key**: The `secret` field was unnecessary and has been removed
|
||||
|
||||
**Security Note**: We switch to SERVICE_USER because the registry directory is owned by SERVICE_USER, maintaining proper file ownership and security.
|
||||
|
||||
#### 4.3 Create Authentication File
|
||||
|
||||
```bash
|
||||
|
@ -499,8 +507,6 @@ exit
|
|||
|
||||
**Note**: Pull operations are public and don't require authentication, but push operations require these credentials.
|
||||
|
||||
**Security Note**: We switch to SERVICE_USER because the registry directory is owned by SERVICE_USER, maintaining proper file ownership and security.
|
||||
|
||||
#### 4.4 Create Docker Compose for Registry
|
||||
|
||||
```bash
|
||||
|
|
Loading…
Add table
Reference in a new issue