File tree Expand file tree Collapse file tree 2 files changed +39
-1
lines changed
Expand file tree Collapse file tree 2 files changed +39
-1
lines changed Original file line number Diff line number Diff line change 11# https://github.com/devcontainers/images/tree/main/src/cpp
22FROM mcr.microsoft.com/devcontainers/cpp:1-debian-12
33
4- # [Optional] Uncomment this section to install additional packages.
4+ # Install additional packages
55RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
66 && apt-get -y install --no-install-recommends \
77 clang-format \
Original file line number Diff line number Diff line change 1+ name : Build and publish Docker image
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+ paths :
8+ - " .devcontainer/Dockerfile"
9+ pull_request :
10+ branches :
11+ - main
12+ paths :
13+ - " .devcontainer/Dockerfile"
14+
15+ jobs :
16+ build-and-publish :
17+ runs-on : ubuntu-latest
18+
19+ steps :
20+ - name : Set up QEMU
21+ uses : docker/setup-qemu-action@v3
22+
23+ - name : Set up Docker Buildx
24+ uses : docker/setup-buildx-action@v3
25+
26+ - name : Log in to GitHub Container Registry
27+ uses : docker/login-action@v3
28+ with :
29+ registry : ghcr.io
30+ username : ${{ github.actor }}
31+ password : ${{ secrets.GITHUB_TOKEN }}
32+
33+ - name : Build and push Docker image
34+ uses : docker/build-push-action@v6
35+ with :
36+ context : " {{defaultContext}}:.devcontainer"
37+ push : true
38+ tags : ghcr.io/${{ github.repository_owner }}/project-cplusplus:latest
You can’t perform that action at this time.
0 commit comments