Use first+last initial for ZSE (#4) #16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate and Update ConfigMap | |
on: [push] | |
jobs: | |
push: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Go ${{ matrix.go-version }} | |
uses: actions/setup-go@v4 | |
with: | |
go-version: '1.21.x' | |
- name: Build Generator | |
run: go build -o bin/generator ./generator/generator.go | |
- name: Generate ConfigMap | |
run: ./bin/generator | |
# Checkout the Target Repository | |
- name: Checkout GitOps Repository | |
uses: actions/checkout@v4 | |
with: | |
repository: 'VATUSA/gitops' | |
path: gitops # Choose a suitable directory name | |
token: ${{ secrets.G_TOKEN }} | |
# Update the ConfigMap (Adapt paths as needed) | |
- name: Update ConfigMap | |
run: | | |
cp manifest/configmap.yaml gitops/current/discord-bot-v3/configmap.yaml | |
# Commit and Push to the Target Repository | |
- name: Commit and Push Changes | |
run: | | |
cd gitops # Move into the checked out repository | |
git config --global user.email "[email protected]" | |
git config --global user.name "VATUSA6" | |
git add current/discord-bot-v3/configmap.yaml | |
git commit -m "Update configmap.yaml from generator" | |
git push origin main |