version: '2.0'
services:

# REGISTRY
  registry:
    image: registry:2.6.2
    container_name: registry
    ports:
    - "5000:5000"
    environment:
      REGISTRY_AUTH: htpasswd
      REGISTRY_AUTH_HTPASSWD_REALM: Registry Realm
      REGISTRY_AUTH_HTPASSWD_PATH: /auth/htpasswd
    volumes:
      - ./auth:/auth
      - ./registry-data:/var/lib/registry
      - ./registry-config:/etc/docker/registry
    networks:
      - registry-ui-net

# UI
  ui:
    image: joxit/docker-registry-ui:1.5-static
    container_name: ui_registry
    ports:
      - 8087:80
    environment:
      - REGISTRY_TITLE=DockerRegistry
      - REGISTRY_URL=http://registry:5000
    depends_on:
      - registry
    networks:
      - registry-ui-net

networks:
  registry-ui-net:
