Unable to start 'cdr/code-server' in Docker container: “error EACCES: permission denied, mkdir '/home/coder/.config/code-server'”
See original GitHub issueHere’s my script:
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo usermod -aG docker $USER
Then I disconnect from ssh, connect back, and run this command:
docker run -it --name code-server -p 127.0.0.1:8080:8080 -v "$HOME/.config:/home/coder/.config:rw" -v "$PWD:/home/coder/project:rw" -u "$(id -u):$(id -g)" -e "DOCKER_USER=$USER" codercom/code-server:latest
The error I get is error EACCES: permission denied, mkdir '/home/coder/.config/code-server'
.
This is on a brand new EC2 instance. Any ideas? I’ve been banging my head on this and I don’t know how to debug further. I’ve tried removing the -e
and -u
options from the command but those don’t seem to have any effect, both with and without running docker with sudo but to no avail. Thank you!
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
No results found
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
What worked for me is (with inside docker support with sudo):
cd
into it,mkdir -p home/.config
@brootware please open a GitHub Discussion or a bug report if you’re experiencing issues!