Skip to content

#70 image가 배포되면 helm chart로 pr 날리도록 변경 #86

#70 image가 배포되면 helm chart로 pr 날리도록 변경

#70 image가 배포되면 helm chart로 pr 날리도록 변경 #86

Workflow file for this run

name: Build
on:
push:
branches:
- '*'
jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
cd:
needs: [build]
runs-on: ubuntu-latest
steps:
- name: Checkout the source repository
uses: actions/checkout@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Checkout the target repository
uses: actions/checkout@v2
with:
repository: ssu-commerce/helm-charts
token: ${{ secrets.HELM_TOKEN }}
path: helm-charts
- name: Update YAML file
run: |
yq eval '.book.image.tag = "2024.06.76"' -i helm-charts/chart/ssu-commerce/values.yaml
- name: Commit changes
run: |
cd helm-charts
git config --local user.name "chohanjoo"
git config --local user.email "[email protected]"
git checkout -b update-image-tag-2024.06.76
git add chart/ssu-commerce/values.yaml
git commit -m 'Update image tag to 2024.06.76'
git push origin update-image-tag-2024.06.76
- name: Create Pull Request
uses: peter-evans/create-pull-request@v5
with:
token: ${{ secrets.HELM_TOKEN }}
commit-message: Update image tag to 2024.06.76
branch: update-image-tag-2024.06.76
base: main
title: Update image tag to 2024.06.76
body: This PR updates the image tag to 2024.06.76.
# - name: Push helm repo
# run: |
# git config --global user.email "[email protected]"
# git config --global user.name "chohanjoo"
#
# git add values.yaml;
# git commit --message "Update book-server image tag to ${{ steps.current-time.outputs.formattedTime }}.${{github.run_number}}";
# git config -l | grep 'http\..*\.extraheader' | cut -d= -f1 | xargs -L1 git config --unset-all
# git push