Skip to content

Merge pull request #115 from rasools/OMICSINT_H24 #6

Merge pull request #115 from rasools/OMICSINT_H24

Merge pull request #115 from rasools/OMICSINT_H24 #6

name: Build and Push Docker Image for Session Gems
on:
push:
paths:
- 'session_gems/**'
branches:
- OMICSINT_H24
jobs:
build:
runs-on: ubuntu-latest
if: github.repository == 'NBISweden/workshop_omics_integration'
steps:
# Checkout the repository
- name: Checkout repository
uses: actions/checkout@v3
# Set up Docker Buildx for multi-platform builds
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
# Log in to Docker Hub using the secrets
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
# Log in to GitHub Container Registry (GHCR)
- name: Log in to GHCR
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# Build and push the Docker image for both amd64 and arm64
- name: Build and Push Docker Image for Session Gems
uses: docker/build-push-action@v4
with:
context: ./session_gems
file: session_gems/Dockerfile
platforms: linux/amd64
push: true
no-cache: true
tags: docker.io/rasoolsnbis/omicsint_h24:session_gems_amd
# Build and push the Docker image to GitHub Container Registry (GHCR)
- name: Build and Push Docker Image to GHCR
uses: docker/build-push-action@v4
with:
context: ./session_gems
file: session_gems/Dockerfile
platforms: linux/amd64
push: true
no-cache: true
tags: ghcr.io/nbisweden/omicsint_h24:session_gems_amd
- name: Inspect Docker Image
run: docker buildx imagetools inspect docker.io/rasoolsnbis/omicsint_h24:session_gems_amd