fix(examples): copy /etc/skel on init in docker template (#12913)

Fixes #10209
This commit is contained in:
Mathias Fredriksson 2024-04-09 14:54:17 +03:00 committed by GitHub
parent 28754a79e5
commit 0178bfe134
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 6 additions and 0 deletions

View File

@ -28,6 +28,12 @@ resource "coder_agent" "main" {
startup_script = <<-EOT
set -e
# Prepare user home with default files on first start.
if [ ! -f ~/.init_done ]; then
cp -rT /etc/skel ~
touch ~/.init_done
fi
# install and start code-server
curl -fsSL https://code-server.dev/install.sh | sh -s -- --method=standalone --prefix=/tmp/code-server --version 4.19.1
/tmp/code-server/bin/code-server --auth none --port 13337 >/tmp/code-server.log 2>&1 &