File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -879,12 +879,14 @@ RUN echo \
879879
880880# ################################################################################
881881# Load startup artifacts
882- COPY ./bin/connect /bin/
883- COPY ./bin/entrypoint /bin/
882+ COPY ./bin/connect /bin/
883+ COPY ./bin/entrypoint /bin/
884+ COPY ./bin/devcontainer-links /bin/
884885
885886# ################################################################################
886887# Entrypoint & default command
887- ENTRYPOINT /bin/entrypoint
888+ ENTRYPOINT ["/bin/entrypoint" ]
889+ HEALTHCHECK --interval=120s --timeout=30s --start-period=5s --retries=3 CMD [ "true" ]
888890CMD ["/usr/bin/env" , "connect" ]
889891
890892# Ports
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # Change ownership of all items in /workspaces to the current user
4+ user=" $( id -u) "
5+ sudo chown " ${user} " /workspaces/* 2> /dev/null
6+
7+ # Iterate over directories in /workspaces
8+ for dir in /workspaces/* ; do
9+ # Check if it's a directory
10+ if [[ -d " ${dir} " ]]; then
11+ # Extract the directory name
12+ dir_name=$( basename " ${dir} " )
13+
14+ # Check if a symlink already exists in the home directory
15+ if [[ -L " ${HOME} /${dir_name} " ]]; then
16+ # Remove the existing symlink if it exists
17+ rm " ${HOME} /${dir_name} "
18+ elif [[ -e " ${HOME} /${dir_name} " ]]; then
19+ # Skip if it's not a symlink (to avoid destructive actions on actual directories or files)
20+ echo " Skipping ${HOME} /${dir_name} , as it's not a symlink."
21+ continue
22+ fi
23+
24+ # Create a new symbolic link
25+ ln -s " ${dir} " " ${HOME} /${dir_name} "
26+ fi
27+ done
28+
29+ # Allow direnv to set environment variables
30+ direnv allow 2> /dev/null
You can’t perform that action at this time.
0 commit comments