You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It appears that Dockage is not able to see or read .env files correctly. Here's my setup:
dockage compose.yaml
services:
dockge:
container_name: dockage
image: louislam/dockge:1
restart: unless-stopped
ports:
# Host Port : Container Port
- 5001:5001
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./data:/app/data
# If you want to use private registries, you need to share the auth file with Dockge:
# - /root/.docker/:/root/.docker
# Stacks Directory
# ⚠� READ IT CAREFULLY. If you did it wrong, your data could end up writing into a WRONG PATH.
# ⚠� 1. FULL path only. No relative path (MUST)
# ⚠� 2. Left Stacks Path === Right Stacks Path (MUST)
- ./opt/stacks:/opt/stacks
environment:
# Tell Dockge where is your stacks directory
- DOCKGE_STACKS_DIR=/home/user/services/dockage/opt/stacks
Snippet from a container using an .env
services:
web:
container_name: test
env_file:
- /home/user/services/web/.env
Yes, I want my .env file located in a specific directory. I've tried multiple ways of formatting it for Dockage to see, but every time I've gone to do docker compose up the container complains it can't see the file, even though I can open it, read it, and edit it.
👟 Reproduction steps
See above
👀 Expected behavior
It should work lol
😓 Actual Behavior
It don't work lol
Dockge Version
1.5.0
💻 Operating System and Arch
Ubuntu 20.04
🌐 Browser
Firefox
🐋 Docker Version
No response
🟩 NodeJS Version
No response
📝 Relevant log output
env file /home/user/services/web/.env not found: stat /home/user/services/web/.env: no such file or directory
The text was updated successfully, but these errors were encountered:
To my understanding, this is a user configuration error. Re-read the comments pertaining to the stacks directory.
You must not use a relative path. You have used a relative path.
Both sides of the volume mount string need to be identical.
The environment variable DOCKGE_STACKS_DIR needs to be the same path defined above.
So, minus the comments, your volumes & environment should look like this:
As to why dockge is this particular, my best guess is that it's related to it playing nice with native compose and being able to freely switch between using dockge and the terminal without either spinning up your containers as a new stack.
🛡️ Security Policy
Description
It appears that Dockage is not able to see or read
.env
files correctly. Here's my setup:dockage
compose.yaml
Snippet from a container using an
.env
Yes, I want my
.env
file located in a specific directory. I've tried multiple ways of formatting it for Dockage to see, but every time I've gone to dodocker compose up
the container complains it can't see the file, even though I can open it, read it, and edit it.👟 Reproduction steps
See above
👀 Expected behavior
It should work lol
😓 Actual Behavior
It don't work lol
Dockge Version
1.5.0
💻 Operating System and Arch
Ubuntu 20.04
🌐 Browser
Firefox
🐋 Docker Version
No response
🟩 NodeJS Version
No response
📝 Relevant log output
The text was updated successfully, but these errors were encountered: