-
Notifications
You must be signed in to change notification settings - Fork 1
56 lines (49 loc) · 1.59 KB
/
build-docker-image.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: Build Docker image
on:
# Nightly build - pull base image
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
# Or when code has been pushed
push:
branches:
- '**'
jobs:
build-docker:
name: Build Docker image
runs-on: ubuntu-latest
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.IMAGE_NAME }}
- name: Build Docker image
# You may pin to the exact commit or the version.
uses: docker/build-push-action@v5
with:
# context: .
sbom: true
push: false
tags: atreyu/inkycal.server:latest
# - name: Container Scan
# id: scan
# # You may pin to the exact commit or the version.
# # uses: crazy-max/ghaction-container-scan@3e9c23f89cd6b0bda949ffe14f28a3ce282323b7
# uses: crazy-max/[email protected]
# with:
# # Container image to scan (eg. alpine:3.7)
# image: atreyu/inkycal.server:latest
# # Dockerfile required to generate a sarif report
# dockerfile: ./Dockerfile
# # Defines threshold for severity
# severity_threshold: CRITICAL
# # Create GitHub annotations in your workflow for vulnerabilities discovered
# annotations: true # optional, default is false
# - name: Upload SARIF file
# if: ${{ steps.scan.outputs.sarif != '' }}
# uses: github/codeql-action/upload-sarif@v3
# with:
# sarif_file: ${{ steps.scan.outputs.sarif }}