File tree Expand file tree Collapse file tree 3 files changed +68
-3
lines changed
Expand file tree Collapse file tree 3 files changed +68
-3
lines changed Original file line number Diff line number Diff line change 1+ name : Upload Docker images
2+
3+ permissions :
4+ packages : write
5+
6+ on :
7+ push :
8+ branches :
9+ - ' master'
10+
11+ jobs :
12+ docker :
13+ runs-on : ubuntu-latest
14+ steps :
15+ - name : Checkout
16+ uses : actions/checkout@v2
17+
18+ - name : Set up QEMU
19+ uses : docker/setup-qemu-action@v1
20+ with :
21+ platforms : arm64
22+
23+ - name : Set up Docker Buildx
24+ uses : docker/setup-buildx-action@v1
25+
26+ - name : Login to Github Docker Registry
27+ uses : docker/login-action@v1
28+ with :
29+ registry : ghcr.io
30+ username : ${{ github.actor }}
31+ password : ${{ secrets.GITHUB_TOKEN }}
32+
33+ - name : Set variables
34+ id : vars
35+ run : echo "::set-output name=date_tag::$(date +%y%m%d-%H%M)"
36+
37+ - name : Docker Buildx Create
38+ run : docker buildx create --use
39+
40+ - name : Build and push build-su2
41+ uses : docker/build-push-action@v2
42+ with :
43+ context : build
44+ push : true
45+ tags : ghcr.io/${{ github.repository_owner }}/su2code/build-su2:${{ steps.vars.outputs.date_tag }}
46+ platforms : linux/amd64,linux/arm64
47+
48+ - name : Build and push test-su2
49+ uses : docker/build-push-action@v2
50+ with :
51+ context : test
52+ push : true
53+ build-args : |
54+ BASE_IMAGE=ghcr.io/${{ github.repository_owner }}/su2code/build-su2:${{ steps.vars.outputs.date_tag }}
55+ tags : ghcr.io/${{ github.repository_owner }}/su2code/test-su2:${{ steps.vars.outputs.date_tag }}
56+ platforms : linux/amd64,linux/arm64
Original file line number Diff line number Diff line change 1- FROM ubuntu:18.04
1+ FROM ubuntu:20.04
2+
3+ LABEL org.opencontainers.image.source https://github.com/su2code/Docker-Builds
4+
25ENV LANG C.UTF-8
3- RUN apt-get update && apt-get install -y \
6+ RUN ln -fs /usr/share/zoneinfo/UTC /etc/localtime
7+ RUN DEBIAN_FRONTEND=noninteractive apt update && apt install -y \
8+ apt-utils \
49 python3 \
510 pkg-config \
611 python3-pip \
Original file line number Diff line number Diff line change 1- FROM su2code/build-su2:latest
1+ ARG BASE_IMAGE=su2code/build-su2:latest
2+
3+ FROM $BASE_IMAGE
4+
5+ LABEL org.opencontainers.image.source https://github.com/su2code/Docker-Builds
26
37# Copies your code file from your action repository to the filesystem path `/` of the container
48COPY runTests.sh /runTests.sh
You can’t perform that action at this time.
0 commit comments