Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
733ec9e
use published dev container
anthony-nhs Feb 13, 2026
704eedb
use new image
anthony-nhs Feb 13, 2026
08472c0
use old image
anthony-nhs Feb 13, 2026
54d444a
fix it
anthony-nhs Feb 13, 2026
577d8e7
fix user
anthony-nhs Feb 13, 2026
556712a
debug
anthony-nhs Feb 13, 2026
415a828
use new tag
anthony-nhs Feb 13, 2026
97767c6
try different user
anthony-nhs Feb 13, 2026
a8d306b
new one
anthony-nhs Feb 14, 2026
2e2d456
new user
anthony-nhs Feb 14, 2026
c6a3dc9
add asdf install
anthony-nhs Feb 14, 2026
967dab7
debug
anthony-nhs Feb 14, 2026
ec7e2a9
more debug
anthony-nhs Feb 14, 2026
9c8a2a0
set home
anthony-nhs Feb 14, 2026
3219587
new image
anthony-nhs Feb 14, 2026
d570e15
set ASDF_DATA_DIR
anthony-nhs Feb 14, 2026
273b9f7
use container step
anthony-nhs Feb 15, 2026
d0191e7
use container step
anthony-nhs Feb 15, 2026
de720fc
fix image
anthony-nhs Feb 15, 2026
0864610
really fix image
anthony-nhs Feb 15, 2026
8001f53
really really fix image
anthony-nhs Feb 15, 2026
cb42b46
really really really fix image
anthony-nhs Feb 15, 2026
826ee6c
use image that can write to /work
anthony-nhs Feb 15, 2026
2e61b9b
use new image
anthony-nhs Feb 15, 2026
183175a
more debug
anthony-nhs Feb 15, 2026
1e98d6e
new image
anthony-nhs Feb 15, 2026
a06cf2e
dont change user
anthony-nhs Feb 15, 2026
c75e255
set user 1001
anthony-nhs Feb 15, 2026
3f50c13
use newer image
anthony-nhs Feb 15, 2026
979b094
fix path
anthony-nhs Feb 15, 2026
2478485
new image
anthony-nhs Feb 15, 2026
989120c
use new image again
anthony-nhs Feb 16, 2026
348b59b
use new action
anthony-nhs Feb 16, 2026
ca04c89
new action
anthony-nhs Feb 16, 2026
829ca63
newer action
anthony-nhs Feb 16, 2026
01a3b54
newer action
anthony-nhs Feb 16, 2026
611eda5
newer action
anthony-nhs Feb 16, 2026
e05bb47
debug
anthony-nhs Feb 16, 2026
2a6bacd
debug
anthony-nhs Feb 16, 2026
0758c79
new one
anthony-nhs Feb 16, 2026
2d060fb
new one
anthony-nhs Feb 16, 2026
8b12d9e
new onea
anthony-nhs Feb 16, 2026
fb03db0
new one
anthony-nhs Feb 16, 2026
70e2b44
new one
anthony-nhs Feb 16, 2026
8d7634d
fix it
anthony-nhs Feb 17, 2026
d6528df
use new tag
anthony-nhs Feb 17, 2026
38f40a3
use correct commit
anthony-nhs Feb 17, 2026
0c8410e
fix name
anthony-nhs Feb 17, 2026
d81961d
dont use full image
anthony-nhs Feb 17, 2026
875e759
new image
anthony-nhs Feb 17, 2026
2a2d5ac
fix secret scan
anthony-nhs Feb 17, 2026
31a1a17
test failure
anthony-nhs Feb 17, 2026
4688236
it will all work
anthony-nhs Feb 17, 2026
87b7112
testing vars
anthony-nhs Feb 17, 2026
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
59 changes: 10 additions & 49 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,53 +1,14 @@
FROM mcr.microsoft.com/devcontainers/base:ubuntu

# provide DOCKER_GID via build args if you need to force group id to match host
ARG DOCKER_GID
ARG IMAGE_NAME=node_24_python_3_14
ARG IMAGE_VERSION=latest
FROM ghcr.io/nhsdigital/eps-devcontainers/${IMAGE_NAME}:${IMAGE_VERSION}

USER root
# specify DOCKER_GID to force container docker group id to match host
RUN if [ -n "${DOCKER_GID}" ]; then \
if ! getent group docker; then \
groupadd -g ${DOCKER_GID} docker; \
else \
groupmod -g ${DOCKER_GID} docker; \
fi && \
usermod -aG docker vscode; \
if ! getent group docker; then \
groupadd -g ${DOCKER_GID} docker; \
else \
groupmod -g ${DOCKER_GID} docker; \
fi && \
usermod -aG docker vscode; \
fi

# Anticipate and resolve potential permission issues with apt
RUN mkdir -p /tmp && chmod 1777 /tmp

RUN apt-get update \
&& export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y dist-upgrade \
&& apt-get -y install --no-install-recommends htop vim curl git build-essential \
libffi-dev libssl-dev libxml2-dev libxslt1-dev libjpeg8-dev libbz2-dev \
zlib1g-dev unixodbc unixodbc-dev libsecret-1-0 libsecret-1-dev libsqlite3-dev \
jq apt-transport-https ca-certificates gnupg-agent \
software-properties-common bash-completion python3-pip make libbz2-dev \
libreadline-dev libsqlite3-dev wget llvm libncurses5-dev libncursesw5-dev \
xz-utils tk-dev liblzma-dev netcat-traditional libyaml-dev

USER vscode

# Install ASDF
RUN git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.11.3 && \
echo '. $HOME/.asdf/asdf.sh' >> ~/.bashrc && \
echo '. $HOME/.asdf/completions/asdf.bash' >> ~/.bashrc

ENV PATH="$PATH:/home/vscode/.asdf/bin/:/workspaces/eps-prescription-tracker-ui/node_modules/.bin:/workspaces/eps-common-workflows/.venv/bin"

# Install ASDF plugins#
RUN asdf plugin add nodejs https://github.com/asdf-vm/asdf-nodejs.git && \
asdf plugin add actionlint && \
asdf plugin add shellcheck https://github.com/luizm/asdf-shellcheck.git && \
asdf plugin add poetry https://github.com/asdf-community/asdf-poetry.git && \
asdf plugin add python

WORKDIR /workspaces/eps-common-workflows

ADD .tool-versions /workspaces/eps-common-workflows/.tool-versions
ADD .tool-versions /home/vscode/.tool-versions

RUN asdf install python && \
asdf install && \
asdf reshim nodejs
25 changes: 10 additions & 15 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/ubuntu
{
"name": "Ubuntu",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"name": "eps-common-workflows",
"build": {
"dockerfile": "Dockerfile",
"context": "..",
"args": {
"DOCKER_GID": "${env:DOCKER_GID:}"
}
"DOCKER_GID": "${env:DOCKER_GID:}",
"IMAGE_NAME": "node_24_python_3_14",
"IMAGE_VERSION": "pr-18-fce01b4",
"USER_UID": "${localEnv:USER_ID:}",
"USER_GID": "${localEnv:GROUP_ID:}"
},
"updateRemoteUserUID": false
},
"postAttachCommand": "git-secrets --register-aws; git-secrets --add-provider -- cat /usr/share/secrets-scanner/nhsd-rules-deny.txt",
"mounts": [
"source=${env:HOME}${env:USERPROFILE}/.aws,target=/home/vscode/.aws,type=bind",
"source=${env:HOME}${env:USERPROFILE}/.ssh,target=/home/vscode/.ssh,type=bind",
Expand All @@ -20,15 +23,7 @@
"remoteEnv": {
"LOCAL_WORKSPACE_FOLDER": "${localWorkspaceFolder}"
},
"postAttachCommand": "docker build -f /workspaces/eps-common-workflows/dockerfiles/nhsd-git-secrets.dockerfile -t git-secrets . && pre-commit install --install-hooks -f",
"features": {
"ghcr.io/devcontainers/features/github-cli:1": {},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {
"version": "latest",
"moby": "true",
"installDockerBuildx": "true"
}
},
"features": {},
"customizations": {
"vscode": {
"extensions": [
Expand Down
22 changes: 15 additions & 7 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@ jobs:
AUTOMERGE_PEM: ${{ secrets.AUTOMERGE_PEM }}
pr_title_format_check:
uses: ./.github/workflows/pr_title_check.yml
get_asdf_version:
get_config_values:
runs-on: ubuntu-22.04
outputs:
asdf_version: ${{ steps.asdf-version.outputs.version }}
tag_format: ${{ steps.load-config.outputs.TAG_FORMAT }}
devcontainer_version: ${{ steps.load-config.outputs.DEVCONTAINER_VERSION }}
devcontainer_image: ${{ steps.load-config.outputs.DEVCONTAINER_IMAGE }}
steps:
- name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
Expand All @@ -32,20 +34,26 @@ jobs:
id: load-config
run: |
TAG_FORMAT=$(yq '.TAG_FORMAT' .github/config/settings.yml)
echo "TAG_FORMAT=$TAG_FORMAT" >> "$GITHUB_OUTPUT"
DEVCONTAINER_IMAGE=$(jq -r '.build.args.IMAGE_NAME' .devcontainer/devcontainer.json)
DEVCONTAINER_VERSION=$(jq -r '.build.args.IMAGE_VERSION' .devcontainer/devcontainer.json)
{
echo "TAG_FORMAT=$TAG_FORMAT"
echo "DEVCONTAINER_IMAGE=$DEVCONTAINER_IMAGE"
echo "DEVCONTAINER_VERSION=$DEVCONTAINER_VERSION"
} >> "$GITHUB_OUTPUT"
quality_checks:
uses: ./.github/workflows/quality-checks.yml
needs: [get_asdf_version]
needs: [get_config_values]
with:
asdfVersion: ${{ needs.get_asdf_version.outputs.asdf_version }}
runtime_docker_image: "${{ needs.get_config_values.outputs.devcontainer_image }}:githubactions-${{ needs.get_config_values.outputs.devcontainer_version }}"
secrets:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
tag_release:
needs: [quality_checks, get_asdf_version]
needs: [quality_checks, get_config_values]
uses: ./.github/workflows/tag-release.yml
with:
dry_run: true
asdfVersion: ${{ needs.get_asdf_version.outputs.asdf_version }}
asdfVersion: ${{ needs.get_config_values.outputs.asdf_version }}
branch_name: ${{ github.event.pull_request.head.ref }}
tag_format: ${{ needs.get_asdf_version.outputs.tag_format }}
tag_format: ${{ needs.get_config_values.outputs.tag_format }}
secrets: inherit
Loading