Skip to content

Commit 496bb8a

Browse files
authored
try new workflow (#127)
* try new workflow * remove circle Signed-off-by: vsoch <[email protected]>
1 parent 5958d14 commit 496bb8a

File tree

4 files changed

+75
-178
lines changed

4 files changed

+75
-178
lines changed

.circleci/config.yml

Lines changed: 0 additions & 176 deletions
This file was deleted.
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: Build & Deploy Docker Containers
2+
on:
3+
# Build on push to any branch
4+
push: []
5+
6+
jobs:
7+
deploy-images:
8+
runs-on: ubuntu-latest
9+
strategy:
10+
fail-fast: false
11+
# Just build primary Dockerfile, tag, arm and amd64 for now
12+
matrix:
13+
dockerfile: [[Dockerfile, linux/amd64, '']]
14+
15+
name: Build ${{ matrix.dockerfile[0] }}
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v3
19+
20+
- name: Set Container Tag
21+
run: |
22+
branch=$(echo ${GITHUB_REF##*/})
23+
printf "Branch is ${branch}\n"
24+
tagged="quay.io/singularity/docker2singularity:${branch}${{ matrix.dockerfile[2] }}"
25+
if [[ "${branch}" == "master" ]]; then
26+
container="quay.io/singularity/docker2singularity:latest${{ matrix.dockerfile[2] }}"
27+
else
28+
container=${tagged}
29+
fi
30+
echo "container=${container}" >> $GITHUB_ENV
31+
echo "branch=${branch}" >> $GITHUB_ENV
32+
echo "tagged=${tagged}" >> $GITHUB_ENV
33+
34+
- name: Log in to Quay Container Registry
35+
if: github.event_name == 'push'
36+
uses: docker/login-action@v2
37+
with:
38+
registry: quay.io
39+
username: ${{ secrets.DOCKER_USER }}
40+
password: ${{ secrets.DOCKER_PASS }}
41+
42+
- name: Set up QEMU
43+
uses: docker/setup-qemu-action@v2
44+
45+
- name: Set up Docker Buildx
46+
uses: docker/setup-buildx-action@v2
47+
48+
- name: Inspect Container Names
49+
run: |
50+
printf "Tagged: ${tagged}\n"
51+
printf "Container: ${container}\n"
52+
53+
- name: Build
54+
uses: docker/build-push-action@v3
55+
if: github.event_name != 'push'
56+
with:
57+
file: ${{matrix.dockerfile[0]}}
58+
platforms: ${{ matrix.dockerfile[1] }}
59+
push: false
60+
tags: |
61+
${{ env.container }}
62+
${{ env.tagged }}
63+
64+
- name: Build & Deploy
65+
uses: docker/build-push-action@v3
66+
if: github.event_name == 'push'
67+
with:
68+
file: ${{matrix.dockerfile[0]}}
69+
platforms: ${{ matrix.dockerfile[1] }}
70+
push: true
71+
tags: |
72+
${{ env.container }}
73+
${{ env.tagged }}

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ RUN apk update && \
3131
RUN apk add --no-cache bash git openssh gcc squashfs-tools sudo libtool gawk ca-certificates libseccomp libseccomp-dev
3232
RUN apk add --no-cache linux-headers build-base openssl-dev util-linux util-linux-dev python rsync cryptsetup glib-dev
3333

34-
ENV SINGULARITY_VERSION 3.10.4
34+
ENV SINGULARITY_VERSION 3.10.5
3535
RUN mkdir -p /usr/local/var/singularity/mnt && \
3636
mkdir -p $GOPATH/src/github.com/sylabs && \
3737
cd $GOPATH/src/github.com/sylabs && \

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.10.3
1+
3.10.5

0 commit comments

Comments
 (0)