Skip to content

Delete fails and HTTP 401 on every other request #104

@matutter

Description

@matutter

I'm running into an issue where DELETE is failing dispite what appears to be a correct registry config. It also looks like every request is tried without basic-auth resulting in an HTTP 401 from the registry but browsing works otherwise.

everything_is_401_delete_fails

docker-compose.yml for registry on server

I'm using Ansible to deploy this so these are jinja2 templates.

version: '3'
services:
  registry:
    image: "{{ image }}"
    ports:
    - "5000:5000"
    volumes:
      - "{{ volume_root }}/auth:/auth"
      - "{{ volume_root }}/certs:/certs"
      - "{{ volume_root }}/config.yml:/etc/docker/registry/config.yml"
      - "{{ registry_storage }}:/var/docker"
    restart: always

docker-compose for docker-registry-ui on laptop

version: "3"
services:
  browser:
    image: joxit/docker-registry-ui
    ports:
    - "8004:80"
    environment:
    - REGISTRY_TITLE=Lumarch Docker Registry
    - REGISTRY_URL="{{ registry_http_url }}" # This is "https://domain:5000"
    - DELETE_IMAGES=true

config.yml

I can login and push/pull from this registry just fine. Again, the docker-registry-ui mostly works, I can browse my images and when I disable all auth on the registry deleting tags does work.

version: 0.1
log:
  fields:
    service: registry
storage:
  delete:
    enabled: true
  cache:
    blobdescriptor: inmemory
  filesystem:
    rootdirectory: /var/docker
auth:
  htpasswd:
    realm: Registry Realm
    path: /auth/htpasswd
http:
  addr: :5000
  host:  "{{ registry_http_url }}" # This is "https://domain:5000"
  tls:
    certificate: /certs/domain.crt
    key: /certs/domain.key
  headers:
    X-Content-Type-Options: [nosniff]
    Access-Control-Allow-Origin: ["http://localhost:8004"]
    Access-Control-Allow-Methods: ['HEAD', 'GET', 'OPTIONS', 'DELETE']
    Access-Control-Expose-Headers: ['Docker-Content-Digest']
    Access-Control-Allow-Credentials: [true]
    Access-Control-Allow-Headers: ['Accept', 'Authorization', 'Content-Type', 'Access-Control-Allow-Headers', 'X-Requested-With']
    Access-Control-Max-Age: [1728000]
health:
  storagedriver:
    enabled: true
    interval: 10s
    threshold: 3

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions