Advertisement
Guest User

Untitled

a guest
May 25th, 2016
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.99 KB | None | 0 0
  1. admin@vps58622:~/docker-registry$ docker pull www.opessolutions.com:5043/busybox
  2. Using default tag: latest
  3. latest: Pulling from busybox
  4. Digest: sha256:6757d4b17cd75742fc3b1fc1a8d02b45b637f2ac913ee9669f5c2aed0c9b26ba
  5. Status: Image is up to date for www.opessolutions.com:5043/busybox:latest
  6.  
  7. nginx_1 | 158.69.212.126 - - [25/May/2016:16:41:54 +0000] "GET /v2/ HTTP/1.1" 401 195 "-" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 x5C(linuxx5C))" "-"
  8. registry_1 | time="2016-05-25T16:41:54Z" level=info msg="response completed" go.version=go1.6.1 http.request.host="www.opessolutions.com:5043" http.request.id=4302d195-a4b4-4dfb-93b3-802ab6cacf28 http.request.method=GET http.request.remoteaddr=158.69.212.126 http.request.uri="/v2/busybox/manifests/latest" http.request.useragent="docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 \(linux\))" http.response.contenttype="application/vnd.docker.distribution.manifest.v2+json" http.response.duration=6.762288ms http.response.status=200 http.response.written=711 instance.id=701faf44-22ad-4386-9305-46a0167b95c8 version=v2.4.0
  9. registry_1 | 172.17.0.3 - - [25/May/2016:16:41:54 +0000] "GET /v2/busybox/manifests/latest HTTP/1.0" 200 711 "" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 \(linux\))"
  10. nginx_1 | 158.69.212.126 - derek [25/May/2016:16:41:54 +0000] "GET /v2/busybox/manifests/latest HTTP/1.1" 200 711 "-" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 x5C(linuxx5C))" "-"
  11.  
  12. derek@derek-lubuntu:~/Projects/docker-library$ docker pull www.opessolutions.com:5043/busybox
  13. Using default tag: latest
  14. Pulling repository www.opessolutions.com:5043/busybox
  15. Error: image busybox not found
  16.  
  17. nginx_1 | 66.171.168.90 - - [25/May/2016:16:42:05 +0000] "GET /v2/ HTTP/1.1" 401 195 "-" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 x5C(linuxx5C))" "-"
  18. nginx_1 | 2016/05/25 16:42:06 [error] 7#7: *5 open() "/etc/nginx/html/v1/_ping" failed (2: No such file or directory), client: 66.171.168.90, server: www.opessolutions.com, request: "GET /v1/_ping HTTP/1.1", host: "www.opessolutions.com:5043"
  19. nginx_1 | 66.171.168.90 - - [25/May/2016:16:42:06 +0000] "GET /v1/_ping HTTP/1.1" 404 169 "-" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 x5C(linuxx5C))" "-"
  20. nginx_1 | 2016/05/25 16:42:06 [error] 7#7: *6 open() "/etc/nginx/html/v1/repositories/busybox/images" failed (2: No such file or directory), client: 66.171.168.90, server: www.opessolutions.com, request: "GET /v1/repositories/busybox/images HTTP/1.1", host: "www.opessolutions.com:5043"
  21. nginx_1 | 66.171.168.90 - - [25/May/2016:16:42:06 +0000] "GET /v1/repositories/busybox/images HTTP/1.1" 404 169 "-" "docker/1.11.1 go/go1.5.4 git-commit/5604cbe kernel/4.4.0-22-generic os/linux arch/amd64 UpstreamClient(Docker-Client/1.11.1 x5C(linuxx5C))" "-"
  22.  
  23. upstream docker-registry {
  24. server registry:5000;
  25. }
  26.  
  27. ## Set a variable to help us decide if we need to add the
  28. ## 'Docker-Distribution-Api-Version' header.
  29. ## The registry always sets this header.
  30. ## In the case of nginx performing auth, the header will be unset
  31. ## since nginx is auth-ing before proxying.
  32. map $upstream_http_docker_distribution_api_version $docker_distribution_api_version {
  33. 'registry/2.0' '';
  34. default registry/2.0;
  35. }
  36.  
  37. server {
  38. listen 443 ssl;
  39. server_name www.opessolutions.com;
  40.  
  41. # SSL
  42. ssl_certificate /etc/nginx/conf.d/domain.crt;
  43. ssl_certificate_key /etc/nginx/conf.d/domain.key;
  44.  
  45. # Recommendations from https://raymii.org/s/tutorials/Strong_SSL_Security_On_nginx.html
  46. ssl_protocols TLSv1.1 TLSv1.2;
  47. ssl_ciphers 'EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH';
  48. ssl_prefer_server_ciphers on;
  49. ssl_session_cache shared:SSL:10m;
  50.  
  51. # disable any limits to avoid HTTP 413 for large image uploads
  52. client_max_body_size 0;
  53.  
  54. # required to avoid HTTP 411: see Issue #1486 (https://github.com/docker/docker/issues/1486)
  55. chunked_transfer_encoding on;
  56.  
  57. location /v2/ {
  58. # Do not allow connections from docker 1.5 and earlier
  59. # docker pre-1.6.0 did not properly set the user agent on ping, catch "Go *" user agents
  60. if ($http_user_agent ~ "^(docker/1.(3|4|5(?!.[0-9]-dev))|Go ).*$" ) {
  61. return 404;
  62. }
  63.  
  64. # To add basic authentication to v2 use auth_basic setting.
  65. auth_basic "Registry realm";
  66. auth_basic_user_file /etc/nginx/conf.d/registry.htpasswd;
  67.  
  68. ## If is empty, the header will not be added.
  69. ## See the map directive above where this variable is defined.
  70. add_header 'Docker-Distribution-Api-Version' $docker_distribution_api_version always;
  71.  
  72. proxy_pass http://docker-registry;
  73. proxy_set_header Host $http_host; # required for docker client's sake
  74. proxy_set_header X-Real-IP $remote_addr; # pass on real client's IP
  75. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  76. proxy_set_header X-Forwarded-Proto $scheme;
  77. proxy_read_timeout 900;
  78. }
  79. }
  80.  
  81. nginx:
  82. image: nginx:1.9
  83. ports:
  84. - 5043:443
  85. links:
  86. - registry:registry
  87. volumes:
  88. - ./nginx:/etc/nginx/conf.d:ro
  89. registry:
  90. image: registry:2
  91. ports:
  92. - 127.0.0.1:5000:5000
  93. environment:
  94. REGISTRY_STORAGE_FILESYSTEM_ROOTDIRECTORY: /data
  95. volumes:
  96. - ./data:/data
  97.  
  98. derek@derek-lubuntu:~/Projects/docker-library$ docker login https://www.opessolutions.com:5043
  99. Username: derek
  100. Password:
  101. Login Succeeded
  102. derek@derek-lubuntu:~/Projects/docker-library$ docker pull www.opessolutions.com:5043/busybox
  103. Using default tag: latest
  104. latest: Pulling from busybox
  105. Digest: sha256:6757d4b17cd75742fc3b1fc1a8d02b45b637f2ac913ee9669f5c2aed0c9b26ba
  106. Status: Downloaded newer image for www.opessolutions.com:5043/busybox:latest
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement