-
Notifications
You must be signed in to change notification settings - Fork 417
99 lines (99 loc) · 3.01 KB
/
release-snapshot.yaml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
#
# On cron schedule or on demand: Release snapshot (amd64 and arm64)
#
# This workflow ensures that the main branch is ready for release and that all
# build configuration files are valid. Also scans tracee container images for
# vulnerabilities, and publishes to DockerHub as aquasec/tracee:dev and
# aquasec/tracee:dev-full.
#
name: Release Snapshot
on:
workflow_dispatch: {}
schedule:
# Daily at 05:00
- cron: "0 5 * * *"
jobs:
release-snapshot:
name: Release Snapshot X64 (Default)
runs-on:
[
"github-self-hosted_ami-0f4881c8d69684001_${{ github.event.number }}-${{ github.run_id }}",
]
permissions:
contents: read
packages: write
id-token: write
steps:
- name: Install Cosign
uses: sigstore/cosign-installer@main
with:
cosign-release: 'v2.0.2'
- name: Checkout Code
uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
- name: AWS Environment
run: |
dmidecode
- name: Login to docker.io registry
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build
run: |
make -f builder/Makefile.release SNAPSHOT=1
- name: Scan Docker Image for Vulnerabilities
uses: aquasecurity/trivy-action@master
with:
image-ref: "tracee:latest"
severity: "CRITICAL"
exit-code: "1"
- name: Publish to docker.io registry
run: |
docker image tag tracee:latest aquasec/tracee:dev
docker image tag tracee:latest aquasec/tracee:x86_64-dev
docker image push aquasec/tracee:dev
docker image push aquasec/tracee:x86_64-dev
release-snapshot-arm64:
name: Release Snapshot ARM64
runs-on:
[
"github-self-hosted_ami-03217ce7c37572c4d_${{ github.event.number }}-${{ github.run_id }}",
]
permissions:
contents: read
packages: write
id-token: write
steps:
- name: Install Cosign
uses: sigstore/cosign-installer@main
with:
cosign-release: 'v2.0.2'
- name: Checkout Code
uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
- name: AWS Environment
run: |
dmidecode
- name: Login to docker.io registry
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build
run: |
make -f builder/Makefile.release SNAPSHOT=1
- name: Scan Docker Image for Vulnerabilities
uses: aquasecurity/trivy-action@master
with:
image-ref: "tracee:latest"
severity: "CRITICAL"
exit-code: "1"
- name: Publish to docker.io registry
run: |
docker image tag tracee:latest aquasec/tracee:aarch64-dev
docker image push aquasec/tracee:aarch64-dev