-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #517 from dynamic-entropy/github_actions_workflow
github actions workflow for rucio release images
- Loading branch information
Showing
1 changed file
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Rucio Release Image CI | ||
|
||
on: | ||
push: | ||
tags: | ||
- "release-*.cms*" | ||
|
||
jobs: | ||
buildx: | ||
runs-on: ubuntu-latest | ||
name: Build and Push CMS Rucio Release Images | ||
strategy: | ||
matrix: | ||
image: [rucio-probes, rucio-daemons, rucio-server, rucio-ui] | ||
fail-fast: False | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Get git tag name | ||
id: gittag | ||
run: echo "tag=${GITHUB_REF#refs/tags/}" >> "$GITHUB_ENV" | ||
|
||
- name: Get rucio version | ||
id: rucioversion | ||
run: echo "rucio_version=$( echo ${{ env.tag }} | grep -Eo '[0-9]*\.?[0-9]+\.[0-9]+')" >> "$GITHUB_ENV" | ||
|
||
- name: Login to CERN Harbour | ||
uses: redhat-actions/podman-login@v1 | ||
with: | ||
registry: registry.cern.ch | ||
username: ${{ secrets.HARBOR_USERNAME }} | ||
password: ${{ secrets.HARBOR_TOKEN }} | ||
|
||
- name: Build the Docker Image | ||
run: | | ||
buildah build --build-arg RUCIO_VERSION=${{ env.rucio_version }} --file docker/${{ matrix.image }}/Dockerfile --tag registry.cern.ch/${{ vars.HARBOR_REPOSITORY }}/${{ matrix.image }}:${{ env.tag }} . | ||
- name: Push the Docker Image | ||
run: | | ||
buildah push registry.cern.ch/${{ vars.HARBOR_REPOSITORY }}/${{ matrix.image }}:${{ env.tag }} |