A free and open source instant messaging and VoIP chat app built for friends, groups, and communities.
ci: publish releases with the Fluxer CI app instead of the Actions token (#1695)
Hampus10ae4bfe1e68
diff --git a/.github/workflows/_build-image.yaml b/.github/workflows/_build-image.yamlindex a3a4b2da1..19acb8b37 100644--- a/.github/workflows/_build-image.yaml+++ b/.github/workflows/_build-image.yaml@@ -65,10 +65,19 @@ jobs:uses: dtolnay/rust-toolchain@e97e2d8cc328f1b50210efc529dca0028893a2d9with:toolchain: "1.93.0"+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: read- name: set variablesid: varsenv:- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}FLUXER_BUILD_VERSION: ${{ inputs['build-version'] }}run: >-cargo run --locked --quiet --manifest-path tools/ci/Cargo.toml -- resolve-calver@@ -151,9 +160,18 @@ jobs:"${IMAGE}:${VERSION}-arm64"docker buildx imagetools inspect "${IMAGE}:${VERSION}"+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: write- name: Publish GitHub releaseenv:- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}SOURCE_SHA: ${{ github.sha }}VERSION: ${{ needs.meta.outputs.build_version }}RELEASE_BASELINE_SHA: ${{ vars.RELEASE_BASELINE_SHA }}diff --git a/.github/workflows/build-admin.yaml b/.github/workflows/build-admin.yamlindex 30d8b9872..4be6cce30 100644--- a/.github/workflows/build-admin.yaml+++ b/.github/workflows/build-admin.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-admindockerfile: fluxer_admin/Dockerfilediff --git a/.github/workflows/build-api.yaml b/.github/workflows/build-api.yamlindex 195504d84..159518c45 100644--- a/.github/workflows/build-api.yaml+++ b/.github/workflows/build-api.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-apidockerfile: fluxer_api/Dockerfilediff --git a/.github/workflows/build-app-proxy-self-hosted.yaml b/.github/workflows/build-app-proxy-self-hosted.yamlindex 37596e4b1..30b395130 100644--- a/.github/workflows/build-app-proxy-self-hosted.yaml+++ b/.github/workflows/build-app-proxy-self-hosted.yaml@@ -29,6 +29,7 @@ jobs:build:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-app-proxy-self-hosteddockerfile: fluxer_app_proxy/Dockerfilediff --git a/.github/workflows/build-app-proxy.yaml b/.github/workflows/build-app-proxy.yamlindex daf111736..158a75f2d 100644--- a/.github/workflows/build-app-proxy.yaml+++ b/.github/workflows/build-app-proxy.yaml@@ -187,9 +187,18 @@ jobs:"${IMAGE}:${VERSION}-arm64"docker buildx imagetools inspect "${IMAGE}:${VERSION}"+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: write- name: Publish GitHub releaseenv:- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}SOURCE_SHA: ${{ github.sha }}VERSION: ${{ needs.meta.outputs.build_version }}RELEASE_BASELINE_SHA: ${{ vars.RELEASE_BASELINE_SHA }}diff --git a/.github/workflows/build-desktop.yaml b/.github/workflows/build-desktop.yamlindex 6e749da4a..d86ce7798 100644--- a/.github/workflows/build-desktop.yaml+++ b/.github/workflows/build-desktop.yaml@@ -67,10 +67,19 @@ jobs:with:toolchain: "1.93.0"+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: read- name: Set metadataid: metaenv:- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}FLUXER_BUILD_VERSION: ${{ inputs.build_version }}run: >-cargo run --locked --quiet --manifest-path tools/ci/Cargo.toml -- build-desktop@@ -581,9 +590,18 @@ jobs:uses: dtolnay/rust-toolchain@e97e2d8cc328f1b50210efc529dca0028893a2d9with:toolchain: "1.93.0"+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: write- name: Publish GitHub desktop releaseenv:- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}CHANNEL: ${{ needs.meta.outputs.build_channel }}VERSION: ${{ needs.meta.outputs.version }}SOURCE_SHA: ${{ needs.meta.outputs.source_sha }}diff --git a/.github/workflows/build-docs.yaml b/.github/workflows/build-docs.yamlindex a880480f3..19a9255e4 100644--- a/.github/workflows/build-docs.yaml+++ b/.github/workflows/build-docs.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-docsdockerfile: fluxer_docs/Dockerfilediff --git a/.github/workflows/build-gateway.yaml b/.github/workflows/build-gateway.yamlindex 698dd4a95..d9485b483 100644--- a/.github/workflows/build-gateway.yaml+++ b/.github/workflows/build-gateway.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-gatewaydockerfile: fluxer_gateway/Dockerfilediff --git a/.github/workflows/build-gifs.yaml b/.github/workflows/build-gifs.yamlindex abffb51e0..5fb6a8854 100644--- a/.github/workflows/build-gifs.yaml+++ b/.github/workflows/build-gifs.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-gifsdockerfile: fluxer_gifs/Dockerfilediff --git a/.github/workflows/build-media-proxy.yaml b/.github/workflows/build-media-proxy.yamlindex b5aada8a6..8c595e679 100644--- a/.github/workflows/build-media-proxy.yaml+++ b/.github/workflows/build-media-proxy.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-media-proxydockerfile: fluxer_media_proxy/Dockerfilediff --git a/.github/workflows/build-messages.yaml b/.github/workflows/build-messages.yamlindex d70265669..2aef5b554 100644--- a/.github/workflows/build-messages.yaml+++ b/.github/workflows/build-messages.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-messagesdockerfile: fluxer_messages/Dockerfilediff --git a/.github/workflows/build-snowflakes.yaml b/.github/workflows/build-snowflakes.yamlindex 2cd601e7a..e5db27e4a 100644--- a/.github/workflows/build-snowflakes.yaml+++ b/.github/workflows/build-snowflakes.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-snowflakesdockerfile: fluxer_snowflakes/Dockerfilediff --git a/.github/workflows/build-static.yaml b/.github/workflows/build-static.yamlindex ed9c997ab..60c5f841d 100644--- a/.github/workflows/build-static.yaml+++ b/.github/workflows/build-static.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-staticdockerfile: fluxer_static/Dockerfilediff --git a/.github/workflows/build-unfurl.yaml b/.github/workflows/build-unfurl.yamlindex 67a473e3b..4633786ee 100644--- a/.github/workflows/build-unfurl.yaml+++ b/.github/workflows/build-unfurl.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-unfurldockerfile: fluxer_unfurl/Dockerfilediff --git a/.github/workflows/build-users.yaml b/.github/workflows/build-users.yamlindex 33861b7bd..b36140d36 100644--- a/.github/workflows/build-users.yaml+++ b/.github/workflows/build-users.yaml@@ -29,6 +29,7 @@ jobs:image:needs: approveuses: ./.github/workflows/_build-image.yaml+ secrets: inheritwith:image: fluxer-usersdockerfile: fluxer_users/Dockerfilediff --git a/.github/workflows/dispatch-private-marketing-build.yaml b/.github/workflows/dispatch-private-marketing-build.yamlindex 0d543da38..b386a33b3 100644--- a/.github/workflows/dispatch-private-marketing-build.yaml+++ b/.github/workflows/dispatch-private-marketing-build.yaml@@ -40,11 +40,20 @@ jobs:build_version: ${{ steps.inputs.outputs.build_version }}correlation_id: ${{ steps.inputs.outputs.correlation_id }}steps:+ - name: Create token+ id: create-token+ uses: actions/create-github-app-token@bcd2ba49218906704ab6c1aa796996da409d3eb1+ with:+ client-id: ${{ vars.FLUXER_CI_APP_ID }}+ private-key: ${{ secrets.FLUXER_CI_APP_KEY }}+ owner: fluxerapp+ repositories: fluxer+ permission-contents: read- name: Resolve trusted build inputsid: inputsenv:EVENT_AFTER: ${{ github.event.after }}- GH_TOKEN: ${{ github.token }}+ GH_TOKEN: ${{ steps.create-token.outputs.token }}PARENT_SHA: ${{ github.sha }}PUBLIC_REPOSITORY: ${{ github.repository }}RUN_ID: ${{ github.run_id }}