python - Docker-compose 没有读取环境变量 COMPOSE_FILE
问题描述
我在 Docker 中使用 django cookiecutter 配置,我无法让 docker-compose 读取 $COMPOSE_FILE 环境变量。
我做了这个
export COMPOSE_FILE=local.yml
这是我运行 docker-compose up 或 build 时的结果:
Can't find a suitable configuration file in this directory or any
parent. Are you in the right directory?
Supported filenames: docker-compose.yml, docker-compose.yaml
解决方案
推荐阅读
- swift - Swift DateFormatter 不会根据预设的 Dateformat 转换日期
- python - 保存文件需要什么安卓权限?
- java - 如何将 rxjava2 Zip 函数(从 Single/Observable)的数量概括为 n 个可选参数而不丢失其类型?
- java - 包含布局的视图绑定不起作用
- python - 如何使用 Selenium Python 在 https://www.tempinbox.xyz/mailbox/username@domain.name 中单击验证消息和按钮
- javascript - CKEditor Angular如何在位置插入文本但保持格式
- javascript - 在 Canvas 上看不到任何东西。它就像白色背景
- javascript - 在 React 中显示来自其他页面的数据
- javascript - 如何将 JSON 转换为单独的项目名称
- hadoop - 在 HDFS 中上传期间可以读取数据吗?