Different env-file but same yml with Docker Compose?

前端 未结 3 1480
谎友^
谎友^ 2021-02-03 23:14

I find it quite common that I have multiple environments (for example test and prod) but the Docker containers that I wish to start are the same in both environments. The only d

3条回答
  •  粉色の甜心
    2021-02-04 00:04

    Nice clear examples, however this did not initially work for me until I updated the base.yml to call the ash shell.

    base.yml

    base:
        image: busybox
        command: ash -c 'echo "${WHO:-Simon} says, \"${SHOUTOUT:-Silence is golden.}\""'
    

提交回复
热议问题