Skip to content

Commit 193fe86

Browse files
Merge branch 'main' into dependabot/github_actions/dot-github/actions/get-ecr-scan-result/aws-actions/configure-aws-credentials-5.1.0
2 parents 1034e81 + 1858f14 commit 193fe86

File tree

9 files changed

+86
-5
lines changed

9 files changed

+86
-5
lines changed

.github/actions/build-node-python/action.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,13 @@ inputs:
5959
description: "run node bundle"
6060
default: "false"
6161
required: false
62+
trivy_enable:
63+
description: "Enable trivy scans on lock files"
64+
default: "false" # Enable this by default?
65+
required: false
66+
trivy_severity:
67+
description: "Severity level for trivy"
68+
required: false
6269
chromatic_enable:
6370
description: "Enable Chromatic tests"
6471
required: false
@@ -287,6 +294,35 @@ runs:
287294
UV_SYSTEM_PYTHON: 1 # In case uv pip is used, install into the system python environment https://docs.astral.sh/uv/guides/integration/github/#using-uv-pip
288295
UV_HTTP_TIMEOUT: 300 # https://docs.astral.sh/uv/reference/environment/#uv_http_timeout
289296

297+
# Trivy
298+
- name: Run Trivy vulnerability scanner on uv.lock
299+
if: inputs.trivy_enable == 'true' && inputs.enable_python == 'true'
300+
uses: aquasecurity/[email protected]
301+
with:
302+
scan-type: "fs"
303+
scan-ref: "uv.lock"
304+
exit-code: "1"
305+
format: "table"
306+
scanners: "vuln"
307+
severity: ${{ inputs.trivy_severity || 'CRITICAL' }}
308+
ignore-unfixed: false
309+
# The cache update takes quite long, so let's try to disable it for now: https://github.com/aquasecurity/trivy-action#cache
310+
cache: "false"
311+
continue-on-error: false
312+
- name: Run Trivy vulnerability scanner on yarn.lock
313+
if: inputs.trivy_enable == 'true' && inputs.enable_node == 'true'
314+
uses: aquasecurity/[email protected]
315+
with:
316+
scan-type: "fs"
317+
scan-ref: "yarn.lock"
318+
exit-code: "1"
319+
format: "table"
320+
scanners: "vuln"
321+
severity: ${{ inputs.trivy_severity || 'CRITICAL' }}
322+
ignore-unfixed: false
323+
# The cache update takes quite long, so let's try to disable it for now: https://github.com/aquasecurity/trivy-action#cache
324+
cache: "false"
325+
continue-on-error: false
290326
# Node
291327
- name: Save yarn cache
292328
uses: actions/cache/save@v4

.github/actions/build-push-helm-chart/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ runs:
5454
run: |
5555
cd $CURRENT_DIRECTORY
5656
helm dependency update
57-
helm cm-push . chartmuseum
57+
helm cm-push -f . chartmuseum
5858
env:
5959
CURRENT_DIRECTORY: ${{ inputs.current_directory }}
6060
shell: bash

.github/actions/build-push-image/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ runs:
3434
using: "composite"
3535
steps:
3636
- name: Configure AWS Credentials
37-
uses: aws-actions/configure-aws-credentials@v4.2.1
37+
uses: aws-actions/configure-aws-credentials@v5.1.0
3838
with:
3939
role-to-assume: ${{ inputs.aws_role }}
4040
aws-region: ${{ inputs.aws_region }}

.github/actions/retag-image/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ runs:
2323
using: "composite"
2424
steps:
2525
- name: Configure AWS Credentials
26-
uses: aws-actions/configure-aws-credentials@v4.2.1
26+
uses: aws-actions/configure-aws-credentials@v5.1.0
2727
with:
2828
role-to-assume: ${{ inputs.aws_role }}
2929
aws-region: ${{ inputs.aws_region }}

.github/workflows/build-docker-artifacts.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,10 @@ jobs:
215215
# Required for build secrets to work: https://docs.docker.com/build/ci/github-actions/secrets/#secret-mounts
216216
- name: Set up QEMU
217217
uses: docker/setup-qemu-action@v3
218+
with:
219+
# Disable caching of binfmt image
220+
cache-image: false
221+
218222
- name: Set up Docker Buildx
219223
uses: docker/setup-buildx-action@v3
220224

@@ -447,7 +451,8 @@ jobs:
447451
name: Push images to push targets
448452
needs: [retag-images, get-flavors]
449453
# if? When should we do this? Always? Only for certain branches? If so, how should we define that, in the config.json?
450-
if: ${{ fromJson(needs.get-flavors.outputs.result).skip_push != true && fromJson(needs.get-flavors.outputs.result).push_to != '' }}
454+
# We need the always() && !cancelled() && !failure() because the test-images may have been skipped (which is fine), but this transitvely propagates through retag-images to here. See https://github.com/actions/runner/issues/491#issuecomment-1507495166
455+
if: ${{ always() && !cancelled() && !failure() && fromJson(needs.get-flavors.outputs.result).skip_push != true && fromJson(needs.get-flavors.outputs.result).push_to != '' }}
451456
uses: datavisyn/github-workflows/.github/workflows/build-docker-artifacts-trigger-push.yml@main
452457
secrets: inherit
453458
with:

.github/workflows/build-node-python.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,15 @@ on:
7474
required: false
7575
description: Unique id per workflow run. Must be set to unique value if dispatched multiple times for a single workflow.
7676
default: ""
77+
trivy_enable:
78+
description: "Enable trivy scans on lock files"
79+
default: false # Enable this by default?
80+
type: boolean
81+
required: false
82+
trivy_severity:
83+
description: "Severity for the trivy scans"
84+
type: string
85+
required: false
7786
chromatic_enable:
7887
description: 'Enable Chromatic tests'
7988
required: false
@@ -151,6 +160,8 @@ jobs:
151160
enable_python: false
152161
# We probably won't need Rust on Node builds...
153162
# enable_rust: ${{ inputs.rust_enable }}
163+
trivy_enable: ${{ inputs.trivy_enable }}
164+
trivy_severity: ${{ inputs.trivy_severity }}
154165
run_parallel: ${{ inputs.run_parallel }}
155166
node_version: ${{ vars.NODE_VERSION || inputs.node_version }}
156167
npm_registry: ${{ vars.NPM_REGISTRY }}
@@ -191,6 +202,8 @@ jobs:
191202
with:
192203
enable_node: false
193204
enable_python: true
205+
trivy_enable: ${{ inputs.trivy_enable }}
206+
trivy_severity: ${{ inputs.trivy_severity }}
194207
enable_rust: ${{ inputs.rust_enable }}
195208
run_parallel: ${{ inputs.run_parallel }}
196209
node_version: ${{ vars.NODE_VERSION || inputs.node_version }}
@@ -282,6 +295,8 @@ jobs:
282295
- name: Build node and python
283296
uses: ./tmp/github-workflows/.github/actions/build-node-python
284297
with:
298+
trivy_enable: ${{ inputs.trivy_enable }}
299+
trivy_severity: ${{ inputs.trivy_severity }}
285300
enable_rust: ${{ inputs.rust_enable }}
286301
run_parallel: ${{ inputs.run_parallel }}
287302
node_version: ${{ vars.NODE_VERSION || inputs.node_version }}
@@ -425,6 +440,8 @@ jobs:
425440
- name: Build node and python
426441
uses: ./tmp/github-workflows/.github/actions/build-node-python
427442
with:
443+
trivy_enable: ${{ inputs.trivy_enable }}
444+
trivy_severity: ${{ inputs.trivy_severity }}
428445
enable_rust: ${{ inputs.rust_enable }}
429446
run_parallel: ${{ inputs.run_parallel }}
430447
node_version: ${{ vars.NODE_VERSION || inputs.node_version }}

.github/workflows/build-node.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,15 @@ on:
77
type: string
88
required: false
99
default: ${{ github.ref || github.head_ref }}
10+
trivy_enable:
11+
description: "Enable trivy scans on lock files"
12+
default: false # Enable this by default?
13+
type: boolean
14+
required: false
15+
trivy_severity:
16+
description: "Severity for the trivy scans"
17+
type: string
18+
required: false
1019
chromatic_enable:
1120
description: 'Enable Chromatic tests'
1221
required: false
@@ -69,6 +78,8 @@ jobs:
6978
with:
7079
enable_node: true
7180
enable_python: false
81+
trivy_enable: ${{ inputs.trivy_enable }}
82+
trivy_severity: ${{ inputs.trivy_severity }}
7283
node_version: ${{ vars.NODE_VERSION || inputs.node_version }}
7384
npm_registry: ${{ vars.NPM_REGISTRY }}
7485
github_ro_token: ${{ github.event.repository.private == true && secrets.DATAVISYN_BOT_REPO_TOKEN || github.token }}

.github/workflows/build-python.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,15 @@ on:
77
type: string
88
required: false
99
default: ${{ github.ref || github.head_ref }}
10+
trivy_enable:
11+
description: "Enable trivy scans on lock files"
12+
default: false # Enable this by default?
13+
type: boolean
14+
required: false
15+
trivy_severity:
16+
description: "Severity for the trivy scans"
17+
type: string
18+
required: false
1019
runs_on:
1120
type: string
1221
required: false
@@ -56,6 +65,8 @@ jobs:
5665
with:
5766
enable_node: false
5867
enable_python: true
68+
trivy_enable: ${{ inputs.trivy_enable }}
69+
trivy_severity: ${{ inputs.trivy_severity }}
5970
github_ro_token: ${{ github.event.repository.private == true && secrets.DATAVISYN_BOT_REPO_TOKEN || github.token }}
6071
python_version: ${{ vars.PYTHON_VERSION || inputs.python_version }}
6172
enable_python_cache: ${{ inputs.runs_on != 'self-hosted' }}

.github/workflows/release-source.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,8 @@ jobs:
9090
- name: Check for pyproject.toml
9191
id: check-pyproject-toml
9292
run: |
93-
if [ -f "pyproject.toml" ]; then
93+
# Check if pyproject.toml exists and contains a version field
94+
if [ -f "pyproject.toml" ] && grep -q "^version\s*=" "pyproject.toml"; then
9495
echo "has_pyproject_toml=true" >> "$GITHUB_OUTPUT"
9596
else
9697
echo "has_pyproject_toml=false" >> "$GITHUB_OUTPUT"

0 commit comments

Comments
 (0)