0

I have moved all my Docker containers to named volumes.

My Traefik Container needs two files to be mounted directly.

The current working config looks like:

volumes:
- /etc/localtime:/etc/localtime:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
- /Container/traefik/data/configurations:/configurations
- /Container/traefik/data/traefik.yml:/traefik.yml:ro
- /Container/traefik/data/acme.json:/acme.json

When I try to use my Named Traefik Volume, the container starts but I get an "can't mount traefik.yml is a directory error"

volumes:
  - /etc/localtime:/etc/localtime:ro
  - /var/run/docker.sock:/var/run/docker.sock:ro
  - Traefik:/configurations
  - type: bind
    source: ./traefik.yml
    target: /traefik.yml
    read_only: true
  - type: bind
    source: ./acme.json
    target: /acme.json
    read_only: false

volumes:
  Traefik:
    external: true

I'm stuck not sure if this isn't possible or that I'm not getting the config right?!

Drallas
  • 1
  • 1

0 Answers0