Skip to content

Commit 38cd9e3

Browse files
committed
chore: update docker image and CI dependencies
Signed-off-by: Niccolò Fei <[email protected]>
1 parent f5a7b35 commit 38cd9e3

File tree

7 files changed

+48
-30
lines changed

7 files changed

+48
-30
lines changed

.github/workflows/overflow-test.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,16 @@ defaults:
77
# default failure handling for shell scripts in 'run' steps
88
shell: 'bash -Eeuo pipefail -x {0}'
99

10+
permissions: {}
11+
1012
jobs:
1113
overflow_test:
1214
runs-on: ubuntu-latest
1315
name: Overflow Test
1416
steps:
15-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
18+
with:
19+
persist-credentials: false
1620

1721
- name: Generate Test Summary
1822
id: generate-summary

.github/workflows/test.yaml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,16 @@ name: Smoke Test
22

33
on: [push]
44

5+
permissions: {}
6+
57
jobs:
68
smoke_test:
79
runs-on: ubuntu-latest
810
name: Smoke Test
911
steps:
10-
- uses: actions/checkout@v4
12+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
13+
with:
14+
persist-credentials: false
1115

1216
- name: Generate Test Summary
1317
id: generate-summary
@@ -16,8 +20,12 @@ jobs:
1620
artifact_directory: example-artifacts/
1721

1822
- name: If there are alerts, echo them
19-
if: ${{steps.generate-summary.outputs.alerts}}
20-
run: echo "${{steps.generate-summary.outputs.alerts}}"
23+
if: ${{ steps.generate-summary.outputs.alerts }}
24+
env:
25+
ALERTS: ${{ steps.generate-summary.outputs.alerts }}
26+
run: echo "$ALERTS"
2127

2228
- name: Echo the thermometer
23-
run: echo "${{steps.generate-summary.outputs.thermometer}}"
29+
env:
30+
THERMOMETER: ${{ steps.generate-summary.outputs.thermometer }}
31+
run: echo "$THERMOMETER"

.github/workflows/unit-test.yaml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,24 @@ name: Unit Test
22

33
on: [push]
44

5+
permissions: {}
6+
57
jobs:
68
unit_test:
79
runs-on: ubuntu-latest
810
name: Unit test
911
steps:
10-
- uses: actions/checkout@v4
12+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
13+
with:
14+
persist-credentials: false
1115

12-
- name: Set up Python
13-
uses: actions/setup-python@v5
14-
with:
15-
python-version: '3.x'
16+
- name: Set up Python
17+
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c # v6
18+
with:
19+
python-version: '3.x'
1620

17-
- name: Install dependencies
18-
run: python -m pip install --upgrade pip prettytable
21+
- name: Install dependencies
22+
run: python -m pip install --upgrade pip prettytable
1923

20-
- name: Run suite
21-
run: python test_summary.py -v
24+
- name: Run suite
25+
run: python test_summary.py -v

DEVELOPERS_DEVELOPERS_DEVELOPERS.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ Example:
103103
id: generate-summary
104104
uses: cloudnative-pg/ciclops@<FULL_LENGTH_SHA>
105105
with:
106-
artifact_directory: test-artifacts/da
106+
artifact_directory: test-artifacts
107107
```
108108
109109
## How it works

Dockerfile

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
FROM python:3
2-
3-
# WORKDIR /usr/src/app
1+
FROM python:3.14-alpine
42

53
COPY requirements.txt ./
64
RUN pip install --no-cache-dir -r requirements.txt

README.md

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -63,28 +63,22 @@ For example:
6363
6464
6565
steps:
66-
- uses: actions/checkout@v3
66+
- uses: actions/checkout@v5
6767

6868
- name: Create a directory for the artifacts
6969
run: mkdir test-artifacts
7070

7171
- name: Download all artifacts to the directory
72-
uses: actions/download-artifact@v3
72+
uses: actions/download-artifact@v6
7373
with:
7474
path: test-artifacts
75-
76-
- name: Flatten all artifacts onto directory
77-
# The download-artifact action, since we did not give it a name,
78-
# downloads all artifacts and creates a new folder for each.
79-
# In this step we bring all the JSONs to a single folder
80-
run: |
81-
mkdir test-artifacts/data
82-
mv test-artifacts/*/*.json test-artifacts/data
75+
pattern: testartifacts-*
76+
merge-multiple: true
8377

8478
- name: Compute the E2E test summary
8579
uses: cloudnative-pg/ciclops@main
8680
with:
87-
artifact_directory: test-artifacts/data
81+
artifact_directory: test-artifacts
8882
```
8983
9084
## Advanced Usage
@@ -130,7 +124,7 @@ The following snippet shows how to use these features:
130124
id: generate-summary
131125
uses: cloudnative-pg/ciclops@main
132126
with:
133-
artifact_directory: test-artifacts/data
127+
artifact_directory: test-artifacts
134128
135129
- name: If there is an overflow summary, archive it
136130
if: ${{steps.generate-summary.outputs.Overflow}}

renovate.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
3+
"extends": [
4+
"config:recommended",
5+
"docker:pinDigests"
6+
],
7+
"enabledManagers": [
8+
"github-actions"
9+
]
10+
}

0 commit comments

Comments
 (0)