version: '3.4'

services:
  oc-shared:
    environment: 
      - MONGO_DATABASE=DC_myDC
    image: 'oc-shared:latest'
    ports:
      - 8091:8080
    container_name: oc-shared
    labels:
        - "traefik.enable=true"
        - "traefik.http.routers.shared.entrypoints=web"
        - "traefik.http.routers.shared.rule=PathPrefix(/shared)" 
        - "traefik.http.middlewares.auth.forwardauth.address=http://oc-auth:8080/oc/forward"
        - "traefik.http.routers.shared.tls=false"
        - "traefik.http.routers.shared.middlewares=auth"
    networks: 
      - catalog

networks: 
  catalog:
    external: true