diff --git a/Dockerfile b/Dockerfile index c4ed208..9dc1383 100644 --- a/Dockerfile +++ b/Dockerfile @@ -26,6 +26,8 @@ RUN --mount=type=cache,target=/var/cache/apt \ echo 'exec /opt/venv/bin/python3.10 "$@"' > /usr/bin/python &&\ # Activate the venv in every terminal echo "source /opt/venv/bin/activate" >> /home/rstudio/.bashrc &&\ + # Print the MOTD/help text in every shell + echo "cat /etc/motd" >> /home/rstudio/.bashrc &&\ # Configure RStudio Server to run without auth echo "auth-none=1" >> /etc/rstudio/rserver.conf &&\ echo "USER=rstudio" >> /etc/environment &&\ @@ -47,6 +49,9 @@ COPY --chown=rstudio:rstudio --from=ghcr.io/opensafely-core/python:v2 /opt/venv # hadolint ignore=DL3022 COPY --chown=rstudio:rstudio --from=ghcr.io/opensafely-core/r:latest /renv/lib/R-4.0/x86_64-pc-linux-gnu/ /usr/local/lib/R/site-library +# copy in the MOTD file containing the required help text +COPY motd /etc/motd + # Required for installing opensafely cli ENV PATH="/home/rstudio/.local/bin:${PATH}" diff --git a/motd b/motd new file mode 100644 index 0000000..5f219ac --- /dev/null +++ b/motd @@ -0,0 +1,10 @@ +This is an OpenSAFELY Codespace + +All 'opensafely' commands (e.g 'opensafely run', 'opensafely exec') are availble +in this terminal. + +The latest version of ehrQL has been installed, and the Python and R libraries installed +here are the same as those available in the corresponding OpenSAFELY actions. + +Additional help is available in the #opensafely-users Slack channel and at +https://docs.opensafely.org/getting-started/how-to/use-github-codespaces-in-your-project/