Skip to content

Commit 3d00a9c

Browse files
committed
Merge branch 'main' into Person-content-css
2 parents e4e0672 + 1f422c1 commit 3d00a9c

156 files changed

Lines changed: 10886 additions & 585 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/acceptance.yml

Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
name: Acceptance Code Quality Workflow
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
base-tag:
7+
required: true
8+
type: string
9+
node-version:
10+
required: true
11+
type: string
12+
13+
artifacts-folder:
14+
required: false
15+
type: string
16+
default: frontend/cypress
17+
name:
18+
required: false
19+
type: string
20+
default: Acceptance Tests
21+
spec-folder:
22+
required: false
23+
type: string
24+
default: frontend/cypress/tests
25+
spec-pattern:
26+
required: false
27+
type: string
28+
default: '**/*.cy.{js,jsx,ts,tsx}'
29+
api-url:
30+
required: false
31+
type: string
32+
default: 'localhost:55001/plone'
33+
site-url:
34+
required: false
35+
type: string
36+
default: 'localhost:3000'
37+
test-profile:
38+
required: false
39+
type: string
40+
default: acceptance
41+
42+
env:
43+
CYPRESS_RETRIES: 2
44+
45+
jobs:
46+
acceptance:
47+
name: ${{ inputs.name }}
48+
runs-on: ubuntu-latest
49+
steps:
50+
- uses: actions/checkout@v4
51+
52+
- name: Load images needed for acceptance tests
53+
env:
54+
BASE_TAG: ${{ inputs.base-tag }}
55+
COMPOSE_PROFILES: ${{ inputs.test-profile }}
56+
run: |
57+
make ci-images-load
58+
59+
- name: Use Node.js ${{ inputs.node-version }}
60+
uses: actions/setup-node@v4
61+
with:
62+
node-version: ${{ inputs.node-version }}
63+
64+
- name: Enable corepack
65+
run: npm i -g corepack@latest && corepack enable
66+
67+
- name: Get pnpm store directory
68+
shell: bash
69+
run: |
70+
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
71+
72+
- uses: actions/cache@v4
73+
name: Setup pnpm cache
74+
with:
75+
path: ${{ env.STORE_PATH }}
76+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml', 'package.json') }}
77+
restore-keys: |
78+
${{ runner.os }}-pnpm-store-
79+
80+
- name: Cache Cypress Binary
81+
id: cache-cypress-binary
82+
uses: actions/cache@v4
83+
with:
84+
path: ~/.cache/Cypress
85+
key: Cypress-binary-${{ inputs.node-version }}-${{ hashFiles('frontend/pnpm-lock.yaml', 'frontend/package.json') }}
86+
87+
- name: Install dependencies
88+
shell: bash
89+
run: |
90+
make frontend-install
91+
92+
- name: Install Cypress if not in cache
93+
if: steps.cache-cypress-binary.outputs.cache-hit != 'true'
94+
working-directory: ./frontend/core/packages/volto
95+
shell: bash
96+
run: make cypress-install
97+
98+
- uses: JarvusInnovations/background-action@v1
99+
name: Start Servers
100+
with:
101+
run: |
102+
BASE_TAG=${{ inputs.base-tag }} COMPOSE_PROFILES=${{ inputs.test-profile }} make ci-containers-start &
103+
104+
wait-on: |
105+
http-get://${{ inputs.api-url }}
106+
http://${{ inputs.site-url }}
107+
108+
tail: true
109+
log-output-resume: stderr
110+
wait-for: 10m
111+
log-output: stderr,stdout
112+
log-output-if: failure
113+
114+
- name: Run Tests
115+
shell: bash
116+
env:
117+
CYPRESS_SPEC_PATTERN: ${{ github.workspace }}/${{ inputs.spec-folder }}/${{ inputs.spec-pattern }}
118+
BASE_TAG: ${{ inputs.base-tag }}
119+
COMPOSE_PROFILES: ${{ inputs.test-profile }}
120+
run: |
121+
make ci-test
122+
123+
- uses: actions/upload-artifact@v4
124+
if: failure()
125+
with:
126+
name: cypress-screenshots-acceptance-${{ inputs.name }}
127+
path: ${{ inputs.artifacts-folder }}/screenshots
128+
129+
- uses: actions/upload-artifact@v4
130+
if: failure()
131+
with:
132+
name: cypress-videos-acceptance-${{ inputs.name }}
133+
path: ${{ inputs.artifacts-folder }}/videos
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: Backend Image Release Workflow
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
base-tag:
7+
required: true
8+
type: string
9+
image-name-prefix:
10+
required: true
11+
type: string
12+
image-name-suffix:
13+
required: true
14+
type: string
15+
python-version:
16+
required: true
17+
type: string
18+
kc-version:
19+
required: true
20+
type: string
21+
working-directory:
22+
required: false
23+
type: string
24+
default: backend
25+
26+
jobs:
27+
release-backend:
28+
name: "Backend: Build and publish Container Image"
29+
if: ${{ github.event_name != 'pull_request' }}
30+
uses: plone/meta/.github/workflows/container-image-push.yml@2.x
31+
permissions:
32+
contents: read
33+
packages: write
34+
with:
35+
base-tag: ${{ inputs.base-tag }}
36+
image-name-prefix: ${{ inputs.image-name-prefix }}
37+
image-name-suffix: ${{ inputs.image-name-suffix }}
38+
working-directory: ${{ inputs.working-directory }}
39+
build-args: |
40+
IMAGE_TAG=${{ inputs.base-tag }}
41+
SEED=${{ github.run_id }}
42+
KC_VERSION=${{ inputs.kc-version }}
43+
PYTHON_VERSION=${{ inputs.python-version }}
44+
secrets:
45+
username: ${{ github.actor }}
46+
password: ${{ secrets.GITHUB_TOKEN }}
47+
48+
release-beispiele:
49+
name: "Backend: Build and publish Demo Image"
50+
uses: plone/meta/.github/workflows/container-image-push.yml@2.x
51+
needs:
52+
- release-backend
53+
permissions:
54+
contents: read
55+
packages: write
56+
with:
57+
base-tag: ${{ inputs.base-tag }}
58+
dockerfile: Dockerfile.beispiele
59+
image-name-prefix: ${{ inputs.image-name-prefix }}
60+
image-name-suffix: beispiele
61+
working-directory: ${{ inputs.working-directory }}
62+
build-args: |
63+
IMAGE_TAG=${{ inputs.base-tag }}
64+
SEED=${{ github.run_id }}
65+
KC_VERSION=${{ inputs.kc-version }}
66+
PYTHON_VERSION=${{ inputs.python-version }}
67+
secrets:
68+
username: ${{ github.actor }}
69+
password: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/backend.yml

Lines changed: 1 addition & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,8 @@
1-
name: Backend Workflow
1+
name: Backend Code Quality Workflow
22

33
on:
44
workflow_call:
55
inputs:
6-
base-tag:
7-
required: true
8-
type: string
9-
image-name-prefix:
10-
required: true
11-
type: string
12-
image-name-suffix:
13-
required: true
14-
type: string
156
python-version:
167
required: true
178
type: string
@@ -48,46 +39,3 @@ jobs:
4839
# python-version: ${{ inputs.python-version }}
4940
# plone-version: ${{ inputs.kc-version }}
5041
# working-directory: ${{ inputs.working-directory }}
51-
52-
release:
53-
name: "Backend: Build and publish Container Image"
54-
uses: plone/meta/.github/workflows/container-image-build-push.yml@2.x
55-
needs:
56-
- lint
57-
# - coverage
58-
permissions:
59-
contents: read
60-
packages: write
61-
with:
62-
base-tag: ${{ inputs.base-tag }}
63-
image-name-prefix: ${{ inputs.image-name-prefix }}
64-
image-name-suffix: ${{ inputs.image-name-suffix }}
65-
working-directory: ${{ inputs.working-directory }}
66-
build-args: |
67-
KC_VERSION=${{ inputs.kc-version }}
68-
push: ${{ github.event_name != 'pull_request' }}
69-
secrets:
70-
username: ${{ github.actor }}
71-
password: ${{ secrets.GITHUB_TOKEN }}
72-
73-
release-beispiele:
74-
name: "Backend: Build and publish Beispiele Container Image"
75-
uses: plone/meta/.github/workflows/container-image-build-push.yml@2.x
76-
needs:
77-
- release
78-
permissions:
79-
contents: read
80-
packages: write
81-
with:
82-
base-tag: ${{ inputs.base-tag }}
83-
dockerfile: Dockerfile.beispiele
84-
image-name-prefix: ${{ inputs.image-name-prefix }}
85-
image-name-suffix: beispiele
86-
working-directory: ${{ inputs.working-directory }}
87-
build-args: |
88-
SEED="${{ github.run_id }}${{ github.sha }}"
89-
IMAGE_TAG=${{ inputs.base-tag }}
90-
push: ${{ github.event_name != 'pull_request' }}
91-
secrets:
92-
username: ${{ github.actor }}
93-
password: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/config.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ on:
4343
frontend:
4444
description: "Flag reporting if we should run the frontend jobs"
4545
value: ${{ jobs.config.outputs.frontend }}
46+
deploy:
47+
description: "Flag reporting if we should deploy"
48+
value: ${{ jobs.config.outputs.deploy }}
4649
varnish:
4750
description: "Flag reporting if we should run the varnish jobs"
4851
value: ${{ jobs.config.outputs.varnish }}
@@ -89,6 +92,7 @@ jobs:
8992
devops: ${{ steps.filter.outputs.devops }}
9093
docs: ${{ steps.filter.outputs.docs }}
9194
frontend: ${{ steps.filter.outputs.frontend }}
95+
deploy: ${{ steps.filter.outputs.deploy }}
9296
varnish: ${{ steps.filter.outputs.varnish }}
9397
base-tag: ${{ steps.vars.outputs.base-tag }}
9498
kc-version: ${{ steps.vars.outputs.kc-version }}
@@ -124,10 +128,13 @@ jobs:
124128
acceptance:
125129
- '.github/workflows/backend*'
126130
- '.github/workflows/frontend*'
131+
- '.github/workflows/acceptance*'
132+
- '.github/workflows/image-build*'
127133
- '.github/workflows/config*'
128134
- '.github/workflows/main*'
129135
- 'backend/**'
130136
- 'frontend/**'
137+
- 'docker-compose*.yml'
131138
backend:
132139
- 'backend/**'
133140
- '.github/workflows/backend*'
@@ -144,6 +151,15 @@ jobs:
144151
- 'frontend/**'
145152
- '.github/workflows/frontend*'
146153
- '.github/workflows/config*'
154+
deploy:
155+
- 'backend/**'
156+
- 'frontend/**'
157+
- '.github/workflows/backend*'
158+
- '.github/workflows/frontend*'
159+
- '.github/workflows/config*'
160+
- '.github/workflows/main*'
161+
- 'devops/**'
162+
- 'docker-compose*.yml'
147163
varnish:
148164
- 'devops/varnish/**'
149165
- '.github/workflows/varnish*'
@@ -164,4 +180,5 @@ jobs:
164180
echo "| devops | ${{ steps.filter.outputs.devops }} |" >> $GITHUB_STEP_SUMMARY
165181
echo "| docs | ${{ steps.filter.outputs.docs }} |" >> $GITHUB_STEP_SUMMARY
166182
echo "| frontend | ${{ steps.filter.outputs.frontend }} |" >> $GITHUB_STEP_SUMMARY
183+
echo "| deploy | ${{ steps.filter.outputs.deploy }} |" >> $GITHUB_STEP_SUMMARY
167184
echo "| varnish | ${{ steps.filter.outputs.varnish }} |" >> $GITHUB_STEP_SUMMARY
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Frontend Image Release Workflow
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
base-tag:
7+
required: true
8+
type: string
9+
image-name-prefix:
10+
required: true
11+
type: string
12+
image-name-suffix:
13+
required: true
14+
type: string
15+
default: "frontend"
16+
node-version:
17+
required: true
18+
type: string
19+
volto-version:
20+
required: true
21+
type: string
22+
working-directory:
23+
required: false
24+
type: string
25+
default: "./frontend"
26+
27+
defaults:
28+
run:
29+
working-directory: ./frontend
30+
31+
jobs:
32+
release:
33+
name: "Frontend: Build and publish container image"
34+
if: ${{ github.event_name != 'pull_request' }}
35+
uses: plone/meta/.github/workflows/container-image-push.yml@2.x
36+
permissions:
37+
contents: read
38+
packages: write
39+
with:
40+
base-tag: ${{ inputs.base-tag }}
41+
image-name-prefix: ${{ inputs.image-name-prefix }}
42+
image-name-suffix: ${{ inputs.image-name-suffix }}
43+
working-directory: ${{ inputs.working-directory }}
44+
build-args: |
45+
VOLTO_VERSION=${{ inputs.volto-version }}
46+
secrets:
47+
username: ${{ github.actor }}
48+
password: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)