Merge remote-tracking branch 'upstream/release_24.0' into release_24.0 #39
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
name: Build AnVIL Image | |
on: push | |
jobs: | |
test: | |
name: Build image | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set branch name | |
id: branch | |
run: echo "name=$(BRANCH_NAME=${GITHUB_REF##*/}; echo ${BRANCH_NAME/release_/}-auto)" >> $GITHUB_OUTPUT | |
- name: Get Galaxy version from branch name | |
id: version | |
run: echo "number=$(BRANCH_NAME=${GITHUB_REF##*/}; echo ${BRANCH_NAME/release_/})" >> $GITHUB_OUTPUT | |
- name: Login to Docker Hub | |
uses: actions-hub/docker/login@master | |
env: | |
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Login to quay.io | |
uses: actions-hub/docker/login@master | |
env: | |
DOCKER_USERNAME: ${{ secrets.QUAY_USERNAME }} | |
DOCKER_PASSWORD: ${{ secrets.QUAY_PASSWORD }} | |
DOCKER_REGISTRY_URL: quay.io | |
- run: docker build . --build-arg GIT_COMMIT=$(git rev-parse HEAD) --build-arg BUILD_DATE=$(date -u +'%Y-%m-%dT%H:%M:%SZ') --build-arg IMAGE_TAG=${{ steps.version.outputs.number }} -t galaxy/galaxy-anvil:${{ steps.branch.outputs.name }} -f .k8s_ci.Dockerfile | |
- name: Push to Docker Hub with branch name | |
uses: actions-hub/docker@master | |
with: | |
args: push galaxy/galaxy-anvil:${{ steps.branch.outputs.name }} | |
- run: docker tag galaxy/galaxy-anvil:${{ steps.branch.outputs.name }} quay.io/galaxyproject/galaxy-anvil:${{ steps.branch.outputs.name }} | |
- name: Push to quay.io with branch name | |
uses: actions-hub/docker@master | |
with: | |
args: push quay.io/galaxyproject/galaxy-anvil:${{ steps.branch.outputs.name }} |