Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Helm Chart CD: create PR instead of trying to push to protected branch #5311

Merged
merged 1 commit into from
Jun 25, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions .github/workflows/cd-helm-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,23 @@ jobs:
env:
TERM: xterm-256color

- name: Publish
- name: Create Pull Request branch
run: |
git checkout -b gh-pages-pull-request

# Note that will fail if branch already exists.
- name: Push Git Branch
uses: ad-m/github-push-action@v0.6.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages
branch: gh-pages-pull-request

# Note that will silently fail if PR already exists.
- name: Create Pull Request
uses: repo-sync/pull-request@v2
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
source_branch: gh-pages-pull-request
destination_branch: gh-pages
pr_title: "Helm Chart: Update Helm repository"
pr_body: "Automatically created from Helm CD workflow."