Compare commits

..

12 Commits

2 changed files with 5 additions and 9 deletions

View File

@ -20,10 +20,12 @@ if [ "${HOME_USER-}" ]; then
sudo adduser --disabled-password --gecos "" ${HOME_USER} sudo adduser --disabled-password --gecos "" ${HOME_USER}
sudo echo "$HOME_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd > /dev/null sudo echo "$HOME_USER ALL=(ALL) NOPASSWD:ALL" | sudo tee -a /etc/sudoers.d/nopasswd > /dev/null
fi fi
# Copy environment variables from vscode user to HOME_USER # Copy environment variables from vscode user to HOME_USER
env | grep -v 'HOME_USER' | while read -r line; do env | grep -v 'HOME_USER' | while read -r line; do
sudo su - ${HOME_USER} -c "echo 'export $line' >> ~/.bashrc" sudo su - ${HOME_USER} -c "echo 'export $line' >> ~/.bashrc"
done done
sudo -u $HOME_USER -i sudo -u $HOME_USER -i
# Unfortunately we cannot change $HOME as we cannot move any bind mounts # Unfortunately we cannot change $HOME as we cannot move any bind mounts
# nor can we bind mount $HOME into a new home as that requires a privileged container. # nor can we bind mount $HOME into a new home as that requires a privileged container.
@ -75,14 +77,8 @@ else
echo "File extensions.json not found" echo "File extensions.json not found"
fi fi
# Allow users to have scripts run on container startup to prepare workspace.
# https://github.com/coder/code-server/issues/5177
if [ -d "${ENTRYPOINTD}" ]; then
find "${ENTRYPOINTD}" -type f -executable -print -exec {} \;
fi
if [[ -z "${VSCODE_TUNNEL_NAME}" ]]; then if [[ -z "${VSCODE_TUNNEL_NAME}" ]]; then
exec dumb-init sudo su - ${HOME_USER} -c "code tunnel --accept-server-license-terms $@" sudo su - ${HOME_USER} -c "code tunnel --accept-server-license-terms"
else else
exec dumb-init sudo su - ${HOME_USER} -c "code tunnel --accept-server-license-terms --name ${VSCODE_TUNNEL_NAME} $@" sudo su - ${HOME_USER} -c "code tunnel --accept-server-license-terms --name ${VSCODE_TUNNEL_NAME}"
fi fi

2
version.txt Normal file → Executable file
View File

@ -1 +1 @@
2.0.16 2.0.28