Skip to content

Commit

Permalink
pipeline: Adding PR generation to helm
Browse files Browse the repository at this point in the history
Signed-off-by: Roy Golan <[email protected]>
  • Loading branch information
rgolangh committed Nov 30, 2023
1 parent 5aab27d commit 62eacc2
Showing 1 changed file with 17 additions and 5 deletions.
22 changes: 17 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,14 +57,12 @@ jobs:

generate-manifests:
runs-on: ubuntu-latest
env:
GH_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v3
- name: dir
run: cd ${{ env.workflow_id }} ; ls -la
- name: setup kn-workflow
run: curl -L https://github.com/rgolangh/kie-tools/releases/download/0.0.0-fix-kn-workflow/kn-workflow -o kn-workflow && chmod +x kn-workflow
- name: sanity
run: pwd; ls -la
- name: kn-workflow
run: cd ${{ env.workflow_id }} && ../kn-workflow gen-manifest
- name: Download yq
Expand All @@ -78,4 +76,18 @@ jobs:
with:
name: serverless-workflow-${{ env.workflow_id }}
path: ${{ env.workflow_id }}/manifests

- name: Send PRs to helm repo
run: |
gh repo clone rgolangh/serverless-workflows-helm
cd serverless-workflows-helm
git switch -c ${{ github.ref_name }}
cp ../${{ env.workflow_id }}/manifests/* charts/workflows/charts/${{ env.workflow_id }}/templates
git add -A
git commit -m "Automated PR from ${{ env.workflow_id }} pipeline"
git push origin HEAD
gh pr create --title "Automatic manifests generation from ${{ github.ref_name }}" \
--label "automated pr" \
--body "
## Type of change
- [X] Updating manifests
"

0 comments on commit 62eacc2

Please sign in to comment.