[Errno 13] Permission denied occurs only when restarting Portainer Stack
Quick Information
- Operating System: Docker on Proxmox
- Install Type: Docker
- Crafty Version: v4
What Happened?
I am running Crafty Controller via a Portainer Stack. I have found that restarting the individual container works perfectly, but stopping and starting the Stack (which recreates the container) results in a permission error on the /crafty directory.
Expected result
The container starts normally.
Steps to reproduce
- Start the Crafty Controller stack in Portainer with a clean install (or make sure the config folder is empty).
- Stop the individual Container (via Containers view).
- Start the individual Container.
- Result: Application starts successfully.
- Stop the Stack (via Stacks view).
- Start the Stack.
-
Result: Application fails to start.
Wrapper | 🚀 Launching crafty with [-d -i] Unable to write to /crafty - Error: [Errno 13] Permission denied: '/crafty/tempfile.txt' Unable to write to /crafty directory!
-
Please note that one you stop the stack, it will not start again unless you wipe the `config` folder. You can stop/restart the containers, but if you delete the container, and try and start the stack again, it will fail.
Screenshots
Priority/Severity
- High (anything that impacts the normal user flow or blocks app usage)
- Medium (anything that negatively affects the user experience)
- Low (anything else e.g., typos, missing icons/translations, layout/formatting issues, etc.)
My docker-compose.yml
services:
crafty:
image: registry.gitlab.com/crafty-controller/crafty-4:latest
container_name: crafty
restart: unless-stopped
environment:
- TZ=America/New_York
ports:
- "8443:8443" # Crafty web UI (HTTPS)
- "8123:8123" # Dynmap (optional)
- "19132:19132/udp" # Bedrock (optional)
- "19133:19133/udp" # Bedrock (optional)
- "19134:19134/udp" # Bedrock (optional)
- "25500-25600:25500-25600" # MC server ports
volumes:
- /mnt/for-crafty/backups:/crafty/backups
- /mnt/for-crafty/logs:/crafty/logs
- /mnt/for-crafty/servers:/crafty/servers
- /mnt/for-crafty/config:/crafty/app/config
- /mnt/for-crafty/import:/crafty/import
Edited by Adam S. Kirschner