Skip to content

Update quay.io/sclorg/nginx-122-micro-c9s Docker digest to b25063f (#… #1546

Update quay.io/sclorg/nginx-122-micro-c9s Docker digest to b25063f (#…

Update quay.io/sclorg/nginx-122-micro-c9s Docker digest to b25063f (#… #1546

Workflow file for this run

name: Build and Test Docker Images
on:
pull_request:
branches: [ "main" ]
push:
branches: [ "main" ]
schedule:
- cron: '20 03 * * *' # 3:20am everyday
jobs:
build_and_push_docker_images:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
security-events: write
name: Docker Images
steps:
# SETUP
- name: Check out the repo
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
submodules: recursive
# PATCH
- name: Get patches
run: |
chmod u+x scripts/*
./scripts/login.sh
./scripts/apply-patches.sh
# BUILD
- name: Build Image
id: build-image
uses: redhat-actions/buildah-build@7a95fa7ee0f02d552a32753e7414641a04307056 # v2
with:
image: piped
tags: latest
containerfiles: Dockerfile
context: Piped
# PUSH
- name: Push To GHCR
if: github.event_name != 'pull_request'
id: push-to-ghcr
uses: redhat-actions/push-to-registry@5ed88d269cf581ea9ef6dd6806d01562096bee9c # v2
with:
username: ${{ github.actor }}
password: ${{ github.token }}
image: ${{ steps.build-image.outputs.image }}
tags: ${{ steps.build-image.outputs.tags }}
registry: ghcr.io/${{ github.repository_owner }}
# SCAN
- name: Run Trivy vulnerability scanner
if: github.event_name != 'pull_request'
uses: aquasecurity/trivy-action@master
with:
image-ref: ghcr.io/${{ github.repository_owner }}/${{ steps.build-image.outputs.image }}@${{ steps.push-to-ghcr.outputs.digest }}
format: 'sarif'
output: 'trivy-results.sarif'
- name: Upload Trivy scan results to GitHub Security tab
if: github.event_name != 'pull_request'
uses: github/codeql-action/upload-sarif@9e8d0789d4a0fa9ceb6b1738f7e269594bdd67f0 # v3
with:
sarif_file: 'trivy-results.sarif'
# PRINT
- name: Print image URLs
if: github.event_name != 'pull_request'
run: |
echo "Image pushed to ${{ steps.push-to-ghcr.outputs.registry-paths }}"