mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-09 18:03:21 +00:00
[ACS-12108] Introduce signed commits into ADF workflows (#12040)
This commit is contained in:
@@ -8,13 +8,22 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.event.registry_package.package_type == 'npm' && github.event.registry_package.name == 'adf-core'
|
if: github.event.registry_package.package_type == 'npm' && github.event.registry_package.name == 'adf-core'
|
||||||
steps:
|
steps:
|
||||||
|
- name: Generate app token
|
||||||
|
id: app-token
|
||||||
|
uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1 # v3.2.0
|
||||||
|
with:
|
||||||
|
client-id: ${{ vars.GH_APP_ENGINEERING_CONTRIB_CLIENT_ID }}
|
||||||
|
private-key: ${{ secrets.GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY }}
|
||||||
|
owner: ${{ github.repository_owner }}
|
||||||
|
repositories: alfresco-apps
|
||||||
|
permission-contents: write
|
||||||
- name: Dispatch event to monorepo
|
- name: Dispatch event to monorepo
|
||||||
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
|
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
|
||||||
env:
|
env:
|
||||||
PACKAGE_NAME: ${{ github.event.registry_package.name }}
|
PACKAGE_NAME: ${{ github.event.registry_package.name }}
|
||||||
PACKAGE_VERSION: ${{ github.event.registry_package.package_version.name }}
|
PACKAGE_VERSION: ${{ github.event.registry_package.package_version.name }}
|
||||||
with:
|
with:
|
||||||
github-token: ${{ secrets.PAT_WRITE_PKG }}
|
github-token: ${{ steps.app-token.outputs.token }}
|
||||||
retries: 3
|
retries: 3
|
||||||
script: |
|
script: |
|
||||||
const payload = {
|
const payload = {
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
workflow_call:
|
workflow_call:
|
||||||
secrets:
|
secrets:
|
||||||
BOT_GITHUB_TOKEN:
|
GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY:
|
||||||
required: true
|
required: true
|
||||||
CROWDIN_TRANSLATIONS_TOKEN:
|
CROWDIN_TRANSLATIONS_TOKEN:
|
||||||
required: true
|
required: true
|
||||||
@@ -15,11 +15,19 @@ jobs:
|
|||||||
pull-from-crowdin:
|
pull-from-crowdin:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
|
- name: Generate app token
|
||||||
|
id: app-token
|
||||||
|
uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1 # v3.2.0
|
||||||
|
with:
|
||||||
|
client-id: ${{ vars.GH_APP_ENGINEERING_CONTRIB_CLIENT_ID }}
|
||||||
|
private-key: ${{ secrets.GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY }}
|
||||||
|
permission-contents: write
|
||||||
|
permission-pull-requests: write
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
||||||
with:
|
with:
|
||||||
ref: develop
|
ref: develop
|
||||||
token: ${{ secrets.BOT_GITHUB_TOKEN }}
|
token: ${{ steps.app-token.outputs.token }}
|
||||||
- name: Pull translations from Crowdin
|
- name: Pull translations from Crowdin
|
||||||
uses: crowdin/github-action@52aa776766211d83d975df51f3b9c53c2f8ba35f # v2.16.3
|
uses: crowdin/github-action@52aa776766211d83d975df51f3b9c53c2f8ba35f # v2.16.3
|
||||||
with:
|
with:
|
||||||
@@ -34,5 +42,5 @@ jobs:
|
|||||||
github_user_email: ${{ vars.HXPS_GIT_EMAIL }}
|
github_user_email: ${{ vars.HXPS_GIT_EMAIL }}
|
||||||
gpg_private_key: ${{ secrets.HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY }}
|
gpg_private_key: ${{ secrets.HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY }}
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.BOT_GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
|
||||||
CROWDIN_TOKEN: ${{ secrets.CROWDIN_TRANSLATIONS_TOKEN }}
|
CROWDIN_TOKEN: ${{ secrets.CROWDIN_TRANSLATIONS_TOKEN }}
|
||||||
|
|||||||
@@ -159,7 +159,7 @@ jobs:
|
|||||||
name: Run Crowdin pull pipeline for up-to-date sync
|
name: Run Crowdin pull pipeline for up-to-date sync
|
||||||
uses: ./.github/workflows/pull-from-crowdin.yml
|
uses: ./.github/workflows/pull-from-crowdin.yml
|
||||||
secrets:
|
secrets:
|
||||||
BOT_GITHUB_TOKEN: ${{ secrets.BOT_GITHUB_TOKEN }}
|
GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY: ${{ secrets.GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY }}
|
||||||
CROWDIN_TRANSLATIONS_TOKEN: ${{ secrets.CROWDIN_TRANSLATIONS_TOKEN }}
|
CROWDIN_TRANSLATIONS_TOKEN: ${{ secrets.CROWDIN_TRANSLATIONS_TOKEN }}
|
||||||
HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY: ${{ secrets.HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY }}
|
HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY: ${{ secrets.HXPS_GIT_COMMIT_SIGNING_PRIVATE_KEY }}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user