Run Renovate validation on isolated containers and retain trusted human CI [skip ci]
This commit is contained in:
parent
ef8eba462b
commit
7f72dc8c5d
1 changed files with 16 additions and 7 deletions
|
|
@ -12,7 +12,8 @@ permissions:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
validate:
|
validate:
|
||||||
runs-on: docker
|
runs-on: ${{ (github.actor == 'renovate-bot' || github.event.pull_request.user.login == 'renovate-bot' || startsWith(github.ref, 'refs/heads/renovate/') || startsWith(github.head_ref,
|
||||||
|
'renovate/')) && 'renovate' || 'docker' }}
|
||||||
# Superseded validation runs can be cancelled freely.
|
# Superseded validation runs can be cancelled freely.
|
||||||
concurrency:
|
concurrency:
|
||||||
group: 'photos-validate-${{ github.ref }}'
|
group: 'photos-validate-${{ github.ref }}'
|
||||||
|
|
@ -21,6 +22,8 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
|
- uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
|
||||||
|
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
- name: Setup Node
|
- name: Setup Node
|
||||||
uses: https://github.com/actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
|
uses: https://github.com/actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
|
||||||
with:
|
with:
|
||||||
|
|
@ -45,12 +48,14 @@ jobs:
|
||||||
- name: End-to-end smoke test
|
- name: End-to-end smoke test
|
||||||
run: npm run test:e2e
|
run: npm run test:e2e
|
||||||
|
|
||||||
if: ${{ github.actor != 'renovate-bot' && !startsWith(github.ref, 'refs/heads/renovate/') && !startsWith(github.head_ref, 'renovate/') }}
|
if: ${{ contains(fromJSON('["andras","ruby336688","renovate-bot"]'), github.actor) && (!github.event.pull_request || contains(fromJSON('["andras","ruby336688","renovate-bot"]'),
|
||||||
|
github.event.pull_request.user.login)) }}
|
||||||
deploy:
|
deploy:
|
||||||
runs-on: docker
|
runs-on: ${{ (github.actor == 'renovate-bot' || github.event.pull_request.user.login == 'renovate-bot' || startsWith(github.ref, 'refs/heads/renovate/') || startsWith(github.head_ref,
|
||||||
|
'renovate/')) && 'renovate' || 'docker' }}
|
||||||
needs: validate
|
needs: validate
|
||||||
if: ${{ github.actor != 'renovate-bot' && !startsWith(github.ref, 'refs/heads/renovate/') && !startsWith(github.head_ref, 'renovate/') && (github.event_name ==
|
if: ${{ contains(fromJSON('["andras","ruby336688","renovate-bot"]'), github.actor) && (!github.event.pull_request || contains(fromJSON('["andras","ruby336688","renovate-bot"]'),
|
||||||
'push' && github.ref == 'refs/heads/main') }}
|
github.event.pull_request.user.login)) && (github.event_name == 'push' && github.ref == 'refs/heads/main') }}
|
||||||
# Never cancel an in-flight deploy: rsync --delete must finish or the live
|
# Never cancel an in-flight deploy: rsync --delete must finish or the live
|
||||||
# site can be left half-deleted. Newer deploys queue behind this one.
|
# site can be left half-deleted. Newer deploys queue behind this one.
|
||||||
concurrency:
|
concurrency:
|
||||||
|
|
@ -60,6 +65,8 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
|
- uses: https://github.com/actions/checkout@11d5960a326750d5838078e36cf38b85af677262
|
||||||
|
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
- name: Setup Node
|
- name: Setup Node
|
||||||
uses: https://github.com/actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
|
uses: https://github.com/actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
|
||||||
with:
|
with:
|
||||||
|
|
@ -83,7 +90,9 @@ jobs:
|
||||||
deploy-pages:
|
deploy-pages:
|
||||||
name: Deploy static site artifacts
|
name: Deploy static site artifacts
|
||||||
needs: deploy
|
needs: deploy
|
||||||
if: ${{ github.actor != 'renovate-bot' && !startsWith(github.ref, 'refs/heads/renovate/') && !startsWith(github.head_ref, 'renovate/') && ((true)) }}
|
if: ${{ contains(fromJSON('["andras","ruby336688","renovate-bot"]'), github.actor) && (!github.event.pull_request || contains(fromJSON('["andras","ruby336688","renovate-bot"]'),
|
||||||
|
github.event.pull_request.user.login)) && (!(github.actor == 'renovate-bot' || github.event.pull_request.user.login == 'renovate-bot' || startsWith(github.ref,
|
||||||
|
'refs/heads/renovate/') || startsWith(github.head_ref, 'renovate/'))) && ((true)) }}
|
||||||
runs-on: pages
|
runs-on: pages
|
||||||
container:
|
container:
|
||||||
image: node:22-bookworm@sha256:63538dfe497cc29dfafdda25ada09b46db68a3f4cc205abf1f5d6bf0913f3384
|
image: node:22-bookworm@sha256:63538dfe497cc29dfafdda25ada09b46db68a3f4cc205abf1f5d6bf0913f3384
|
||||||
|
|
@ -99,7 +108,7 @@ jobs:
|
||||||
name: pages-deploy-0
|
name: pages-deploy-0
|
||||||
path: dist
|
path: dist
|
||||||
- name: Copy build to host pages mount
|
- name: Copy build to host pages mount
|
||||||
uses: https://git.schmelczer.dev/andras/ci-actions/deploy-pages@18419c79a58572be1bb3759b334f43306be44a29
|
uses: https://git.schmelczer.dev/andras/ci-actions/deploy-pages@c80f2f0701d7618f1f0b2bb52ebd332ea34b6e28
|
||||||
with:
|
with:
|
||||||
source: dist
|
source: dist
|
||||||
target: photos
|
target: photos
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue