-
-
Notifications
You must be signed in to change notification settings - Fork 51
Description
Describe the feature
Supporting for template synchronization for multiple GitHub organization. If you work with private repository within an Enterprise Organization, the token of a GitHub app are bound to one organization only.
Currently, the template synchronization GitHub action uses only one github_token. If the scripts could use multiple github_token or if you could specify a source and destination github token that are being used later on, you could have template synchronization most likely across multiple GitHub organization under an enterprise umbrella. The teams would be required to somehow "share" the credentials and figure out a least privilege approach but the synchronization could be possible I guess.
Within the action it could look like this:
`
- uses: actions/create-github-app-token@v1
id: app-token-org-destination
with:
app-id: ${{ secrets.ORG_DESTINATION_APP_ID }}
private-key: ${{ secrets.ORG_DESTINATION_PRIVATE_KEY }}
- uses: actions/create-github-app-token@v1
id: app-token-org-source
with:
app-id: ${{ secrets.ORG_SOURCE_APP_ID }}
private-key: ${{ secrets.ORG_SOURCE_PRIVATE_KEY }}
- name: actions-template-sync
uses: AndreasAugustin/actions-template-sync@v2
with:
source_github_token: ${{ steps.app-token-org-source.outputs.token }}
source_repo_path: Uniper-Streaming-Integration-Platform/confluent-cloud-terraform-template
destination_github_token: ${{ steps.app-token-org-destination.outputs.token }}
upstream_branch: main`
`
The push function would most like need to use the token of the destination as far as I could figure out.
Use Case
Support template synchronization across multiple GitHub organization with private repositories
Proposed Solution
No response
Acknowledgements
- I may be able to implement this feature request
Metadata
Metadata
Assignees
Labels
Projects
Status