Skip to content

Commit

Permalink
Merge pull request #98 from bedroge/autobuild_bootstrap_container
Browse files Browse the repository at this point in the history
Automatically build and publish the container image for bootstrapping Gentoo Prefix
  • Loading branch information
boegel authored Jun 22, 2021
2 parents 7f4e54e + d12afe6 commit 45ec8ee
Show file tree
Hide file tree
Showing 8 changed files with 54 additions and 66 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/build-and-publish-bootstrap-container.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Build and publish EESSI Docker image for bootstrapping Gentoo Prefix
on:
push:
branches:
- main
paths:
- Dockerfile.bootstrap-prefix-centos8
- bootstrap-prefix.sh

pull_request:
branches:
- main
paths:
- Dockerfile.bootstrap-prefix-centos8
- bootstrap-prefix.sh

jobs:
build_and_publish:
name: Build and publish image
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
steps:
- name: Check out the repo
uses: actions/checkout@v2

- name: Set up QEMU
uses: docker/setup-qemu-action@v1

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1

- name: Login to GitHub Container Registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Convert and store repository owner in lowercase
run: |
echo "REPOSITORY_OWNER=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]')" >> $GITHUB_ENV
- name: Build and push to GitHub Packages
uses: docker/build-push-action@v2
with:
tags: ghcr.io/${{ env.REPOSITORY_OWNER }}/bootstrap-prefix:centos8
file: Dockerfile.bootstrap-prefix-centos8
platforms: linux/amd64, linux/arm64, linux/ppc64le
push: ${{ github.event_name != 'pull_request' }}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM docker.io/arm64v8/centos:8.2.2004
FROM centos:8.2.2004

COPY bootstrap-prefix.sh /usr/local/bin/bootstrap-prefix.sh

Expand Down
11 changes: 0 additions & 11 deletions Dockerfile.bootstrap-prefix-centos8-ppc64le

This file was deleted.

11 changes: 0 additions & 11 deletions Dockerfile.bootstrap-prefix-centos8-x86_64

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ prefix_snapshot_version: 20210607
prefix_user_defined_trusted_dirs:
- "/cvmfs/{{ cvmfs_repository }}/host_injections/{{ eessi_version }}/compat/{{ eessi_host_os }}/{{ eessi_host_arch }}/lib"
prefix_singularity_command: "singularity run -B {{ gentoo_prefix_path }}:{{ gentoo_prefix_path }}"
prefix_source: "docker://eessi/bootstrap-prefix:centos8-{{ eessi_host_arch }}"
prefix_source: "docker://ghcr.io/eessi/bootstrap-prefix:centos8"
prefix_source_options: "{{ gentoo_prefix_path }} noninteractive"
prefix_install: >-
SINGULARITYENV_USE_CPU_CORES={{ ansible_processor_vcpus }}
Expand Down
10 changes: 0 additions & 10 deletions docker_build_bootstrap_prefix.sh

This file was deleted.

16 changes: 0 additions & 16 deletions singularity-bootstrap-prefix.arm64v8.def

This file was deleted.

16 changes: 0 additions & 16 deletions singularity-bootstrap-prefix.def

This file was deleted.

0 comments on commit 45ec8ee

Please sign in to comment.