Skip to content

ci-storage

ci-storage #1259

Workflow file for this run

name: ci-storage
on:
push:
paths:
- 'storage*/**'
- '.github/workflows/ci-storage.yml'
- '.github/actions/prepare-bareos-app/*'
- '.github/actions/build-bareos-app/*'
- '.github/actions/push-bareos-app/*'
- '.github/actions/test-bareos-app/*'
pull_request:
paths:
- 'storage*/**'
- '.github/workflows/ci-storage.yml'
- '.github/actions/prepare-bareos-app/*'
- '.github/actions/build-bareos-app/*'
- '.github/actions/push-bareos-app/*'
- '.github/actions/test-bareos-app/*'
workflow_dispatch:
schedule:
- cron: '35 5 * * *'
jobs:
prepare:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Prepare build file
uses: ./.github/actions/prepare-bareos-app
with:
bareos_app: storage
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: build-artifact-storage-tmp
path: build
build:
needs: prepare
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: build-artifact-storage-tmp
path: build
- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v3
with:
image: tonistiigi/binfmt:latest
platforms: all
- name: Build images
uses: ./.github/actions/build-bareos-app
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: build-artifact-storage
path: build
test:
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: build-artifact-storage
path: build
- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v3
with:
image: tonistiigi/binfmt:latest
platforms: all
- name: Load and test images
uses: ./.github/actions/test-bareos-app
deploy:
needs: test
if: |
(github.event_name == 'push' || github.event_name == 'schedule') &&
github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: build-artifact-storage
path: build
- name: Load and push images
uses: ./.github/actions/push-bareos-app
with:
docker_pass: ${{ secrets.DOCKER_PASS }}