Can I use environment variables?
Opened this issue · 0 comments
mcauto commented
docker-compose.yml
version: '3'
services:
nginx:
image: nginx
hostname: ${PROJECT_NAME}-nginx
container_name: ${PROJECT_NAME}-nginx
app:
image: myapp
hostname: ${PROJECT_NAME}-myapp
container_name: ${PROJECT_NAME}-myapp
mysql:
image: mysql:5.7
hostname: ${PROJECT_NAME}-mysql
container_name: ${PROJECT_NAME}-mysql
command: --default-authentication-plugin=mysql_native_password
restart: always
ports:
- ${MYSQL_PORT}:3306
env_file:
- confs/database/mysql/.env
volumes:
- mysql-storage:/var/lib/mysql
.envrc
export PROJECT_NAME=$(echo "${PWD##*/}")
export MYSQL_PORT=3306
Can I use environment variable in this plugin?