Skip to content

Commit 312a4d5

Browse files
committed
doc: Improve docker example to mount in $HOME for easy config access
I'm surprised no one has asked any questions about this.
1 parent a730bec commit 312a4d5

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

doc/install.md

+6
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,13 @@ code-server
174174
# It will also mount your current directory into the container as `/home/coder/project`
175175
# and forward your UID/GID so that all file system operations occur as your user outside
176176
# the container.
177+
#
178+
# Your $HOME/.config is mounted at $HOME/.config within the container to ensure you can
179+
# easily access/modify your code-server config in $HOME/.config/code-server/config.json
180+
# outside the container.
181+
mkdir -p ~/.config
177182
docker run -it -p 127.0.0.1:8080:8080 \
183+
-v "$HOME/.config:/home/coder/.config" \
178184
-v "$PWD:/home/coder/project" \
179185
-u "$(id -u):$(id -g)" \
180186
codercom/code-server:latest

0 commit comments

Comments
 (0)