Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
FROM mcr.microsoft.com/devcontainers/php:8.3

# The php base image sets WORKDIR to /var/www/html, which devcontainer_on_create.sh
# later deletes and replaces with a symlink to the mounted docroot. The devcontainer
# CLI starts its persistent setup shell ("shellServer") in WORKDIR with no -w flag, so
# that deletion orphans the shell's cwd and the subsequent dotfiles `git clone` fails
# with "Unable to read current working directory" (issue #45). Anchor WORKDIR to a
# stable directory that the lifecycle scripts never delete.
WORKDIR /home/vscode

# Change default umask and add user to web group so we can share write permission on web files
# Configure pam_umask to set umask to 002 (works regardless of /etc/login.defs content)
RUN sed -i 's/pam_umask\.so/pam_umask.so umask=002/' /etc/pam.d/common-session \
Expand Down
3 changes: 0 additions & 3 deletions local/etc/uceap.d/devcontainer_on_create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,6 @@ function devcontainer_on_create() {
if [ -x .devcontainer/onCreate.sh ]; then
.devcontainer/onCreate.sh
fi

# Leave the shellServer with a valid cwd for any subsequent step (see issue #45)
cd "$WORKSPACE_FOLDER"
}

_devcontainer_on_create_desc='runs when the devcontainer is created'
Expand Down
3 changes: 0 additions & 3 deletions local/etc/uceap.d/devcontainer_post_create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,6 @@ function devcontainer_post_create() {
if [ -x .devcontainer/postCreate.sh ]; then
.devcontainer/postCreate.sh
fi

# Leave the shellServer with a valid cwd for any subsequent step (see issue #45)
cd "$WORKSPACE_FOLDER"
}

_devcontainer_post_create_desc='runs after the devcontainer is created'
Expand Down
Loading