不能用ssl启动Docker的traefik容器
我试图用ssl运行traefik – 在一个自签名证书上。 这是我的docker-compose.yml文件
traefik: image: traefik restart: unless-stopped command: -c /dev/null --web --docker --logLevel=INFO --defaultEntryPoints='https' --entryPoints="Name:https Address::443 TLS:/certs/cert.pem,/certs/key.pem" --entryPoints="Name:http Address::80 Redirect.EntryPoint:https" ports: - '80:80' - '443:443' - '8080:8080' volumes: - /var/run/docker.sock:/var/run/docker.sock - ./certs:/certs/
运行docker-compose up
– 我在日志中得到这个错误:
level=error msg="Error creating TLS config: bad TLS Certificate KeyFile format, expected a path"
之后:
level=fatal msg="Error preparing server: bad TLS Certificate KeyFile format, expected a path
接着:
traefik exited with code 1
我在Mac上运行Docker版本17.06.0
任何线索可能是这里的问题?