Skip to content

Switch to matrix build #17

Switch to matrix build

Switch to matrix build #17

Workflow file for this run

name: pipeline
on:
push
env:
BASE_TAG: user/xrootd-cmstfc:base
LATEST_TAG: ghcr.io/guyzsarun/xrootd-cmsjson:latest
jobs:
build:
strategy:
matrix:
version: [8, 9]
runs-on: ubuntu-latest
steps:
- name: Check out Git repository
uses: actions/checkout@v2
- uses: docker/setup-buildx-action@v2
- name: Build Docker image
uses: docker/build-push-action@v4
with:
context: .
file: docker/Dockerfile.rpm
tags: ${{ env.BASE_TAG }}
build-args: |
IMAGE_TAG =${{ matrix.version }}
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
# test-json:
# name: Test JSON Conversion
# needs: build
# runs-on: ubuntu-latest
# steps:
# - name: Check out Git repository
# uses: actions/checkout@v2
# - uses: docker/setup-buildx-action@v2
# - name: Build Docker image
# uses: docker/build-push-action@v4
# with:
# context: .
# file: docker/Dockerfile
# tags: ${{ env.BASE_TAG }}
# load: true
# cache-from: type=gha
# cache-to: type=gha,mode=max
# - name: Unit test
# run: |
# docker run --rm ${{ env.BASE_TAG }} python3 -m pytest -v
# test-rpm:
# name: Package RPM
# needs: build
# runs-on: ubuntu-latest
# steps:
# - name: Check out Git repository
# uses: actions/checkout@v2
# - uses: docker/setup-buildx-action@v2
# - name: Build Docker image
# uses: docker/build-push-action@v4
# with:
# context: .
# file: docker/Dockerfile.rpm
# load: true
# cache-from: type=gha
# cache-to: type=gha,mode=max