File tree Expand file tree Collapse file tree 4 files changed +59
-36
lines changed Expand file tree Collapse file tree 4 files changed +59
-36
lines changed Original file line number Diff line number Diff line change @@ -67,7 +67,8 @@ RUN /opt/install_dpcpp.sh
67
67
COPY install_libbacktrace.sh /opt/install_libbacktrace.sh
68
68
RUN /opt/install_libbacktrace.sh
69
69
70
- # Add a new (non-root) 'user'
71
- ENV USER user
70
+ # Add a new (non-root) 'test_user' and switch to it
71
+ ENV USER test_user
72
72
ENV USERPASS pass
73
73
RUN useradd -m "${USER}" -g sudo -p "$(mkpasswd ${USERPASS})"
74
+ USER test_user
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ # Runs linter for Docker files
2
+ name : Trivy
3
+
4
+ on :
5
+ workflow_dispatch :
6
+ push :
7
+ pull_request :
8
+ paths :
9
+ - ' .github/docker/*Dockerfile'
10
+ - ' .github/workflows/trivy.yml'
11
+
12
+ concurrency :
13
+ group : ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
14
+ cancel-in-progress : true
15
+
16
+ permissions :
17
+ contents : read
18
+
19
+ jobs :
20
+ linux :
21
+ name : Trivy
22
+ runs-on : ubuntu-latest
23
+ permissions :
24
+ security-events : write
25
+
26
+ steps :
27
+ - name : Clone repo
28
+ uses : actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
29
+
30
+ - name : Run Trivy
31
+ uses : aquasecurity/trivy-action@84384bd6e777ef152729993b8145ea352e9dd3ef # v0.17.0
32
+ with :
33
+ scan-type : ' config'
34
+ hide-progress : false
35
+ format : ' sarif'
36
+ output : ' trivy-results.sarif'
37
+ exit-code : 1 # Fail if issue found
38
+ # file with suppressions: .trivyignore (in root dir)
39
+
40
+ - name : Print report and trivyignore file
41
+ run : |
42
+ echo "### Trivy ignore content:"
43
+ cat .trivyignore
44
+ echo "### Trivy report:"
45
+ cat trivy-results.sarif
46
+
47
+ - name : Upload results
48
+ uses : github/codeql-action/upload-sarif@e8893c57a1f3a2b659b6b55564fdfdbbd2982911 # v3.24.0
49
+ with :
50
+ sarif_file : ' trivy-results.sarif'
Original file line number Diff line number Diff line change
1
+ # Docs: https://aquasecurity.github.io/trivy/latest/docs/configuration/filtering/#trivyignore
2
+
3
+ # In docker files:
4
+ # HEALTHCHECK is not required for development, nor in CI (failed docker = failed CI).
5
+ # We're not hosting any application with usage of the dockers.
6
+ AVD-DS-0026
You can’t perform that action at this time.
0 commit comments