我有一个包含RabbitMQ,PostgresSQL和Vault的docker-compose文件要运行,对于这个Vault容器,我有一些配置和一个.sh文件来应用这些配置,但是当我运行compose文件时,出现错误消息保管箱容器: “ /usr/local/bin/docker-entrypoint.sh:exec:第104行:/vault/config/config.sh:找不到”
我正在使用Windows 10 PRO 我已经尝试过:
似乎没有任何作用...
我的docker文件:
version: "3"
services:
postgres:
container_name: postgres
image: postgres:9.6
ports:
- "5433:5432"
environment:
POSTGRES_USER: <my_user>
POSTGRES_PASSWORD: <my_pass>
POSTGRES_DB: <my_db>
healthcheck:
test: ["CMD-SHELL", "pg_isready -U <my_db>"]
interval: 2s
timeout: 3s
retries: 30
rabbit:
container_name: rabbit
image: rabbitmq:3-management
ports:
- "5673:5672"
- "15673:15672"
healthcheck:
test: ["CMD", "rabbitmqctl", "node_health_check"]
interval: 2s
timeout: 3s
retries: 30
vault:
container_name: vault
image: vault
ports:
- "8201:8200"
volumes:
- ./vault/:/vault/config
environment:
VAULT_ADDR: http://0.0.0.0:8200
VAULT_DEV_ROOT_TOKEN_ID: root
SKIP_SETCAP: 1
links:
- postgres
- rabbit
command: ["/vault/config/config.sh"]
healthcheck:
test: ["CMD", "vault", "status"]
interval: 2s
timeout: 3s
retries: 30
在Linux上运行正常,问题在Windows上 如果有人需要更多内容(文件,上下文,代码等)注释,我将其添加。