You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

38 lines
1.2 KiB

upstream docker-registry {
server 172.16.0.3:20500;
}
server {
listen 443;
server_name registry.bing89.com;
ssl on;
ssl_certificate conf.d/ssl/registry.bing89.com.pem;
ssl_certificate_key conf.d/ssl/registry.bing89.com.key;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
client_max_body_size 0;
chunked_transfer_encoding on;
add_header 'Docker-Distribution-Api-Version' 'registry/2.0' always;
location / {
auth_basic "Restricted";
auth_basic_user_file conf.d/auth/registry.bing89.com.txt;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_read_timeout 900;
proxy_pass http://docker-registry;
}
location /_ping {
auth_basic off;
proxy_pass http://docker-registry;
}
location /v2/_ping {
auth_basic off;
proxy_pass http://docker-registry;
}
location /v2/_catalog {
auth_basic off;
proxy_pass http://docker-registry;
}
}