Skip to content

Refactor Devcontainer Dockerfile (Root User/Bind Mounts) and Restores GitHub Actions Workflows #29

Refactor Devcontainer Dockerfile (Root User/Bind Mounts) and Restores GitHub Actions Workflows

Refactor Devcontainer Dockerfile (Root User/Bind Mounts) and Restores GitHub Actions Workflows #29

Workflow file for this run

name: 'devcontainer CI'
on:
workflow_dispatch:
pull_request:
paths:
- '.devcontainer/**'
- '.github/workflows/dev-container.yml'
push:
branches:
- main
paths:
- '.devcontainer/**'
- '.github/workflows/dev-container.yml'
jobs:
build_devcontainer:
runs-on: ubuntu-latest
steps:
- name: Checkout from github
uses: actions/checkout@v6
- name: extract the github reference
run: echo "BRANCH=${GITHUB_REF##*/}" >> $GITHUB_ENV
- name: "image name from repo name"
id: docker_image_name
run: echo "docker_image=${{ github.repository }}" | tr '[:upper:]' '[:lower:]' |sed 's/[^0-9,a-z,A-Z,=,_,\/]/-/g' >>${GITHUB_OUTPUT}
- name: setup buildx
uses: docker/setup-buildx-action@v4
- name: Build and run dev container task
uses: devcontainers/ci@v0.3
with:
imageName: devcontainer/${{ steps.docker_image_name.outputs.docker_image }}
configFile: ./.devcontainer/devcontainer.json
push: never