fix: use SSH deploy key to push to lunarfront-charts
Some checks failed
Build & Release / build (push) Has been cancelled

This commit is contained in:
Ryan Moon
2026-04-03 15:28:19 -05:00
parent 3f356b0b48
commit fccddfd7f3

View File

@@ -81,14 +81,18 @@ jobs:
- name: Update charts - name: Update charts
run: | run: |
git clone https://lunarfront-bot:${{ secrets.BOT_TOKEN }}@$GIT_REMOTE/ryan/lunarfront-charts.git /tmp/charts mkdir -p ~/.ssh
echo "${{ secrets.CHARTS_DEPLOY_KEY }}" > ~/.ssh/charts_deploy_key
chmod 600 ~/.ssh/charts_deploy_key
echo "StrictHostKeyChecking no" >> ~/.ssh/config
GIT_SSH_COMMAND="ssh -i ~/.ssh/charts_deploy_key" git clone ssh://git@git-ssh.lunarfront.tech/ryan/lunarfront-charts.git /tmp/charts
cd /tmp/charts cd /tmp/charts
sed -i "s|image: registry.digitalocean.com/lunarfront/manager:.*|image: registry.digitalocean.com/lunarfront/manager:${{ steps.version.outputs.version }}|" manager/deployment.yaml sed -i "s|image: registry.digitalocean.com/lunarfront/manager:.*|image: registry.digitalocean.com/lunarfront/manager:${{ steps.version.outputs.version }}|" manager/deployment.yaml
git config user.name "lunarfront-bot" git config user.name "lunarfront-bot"
git config user.email "bot@lunarfront.tech" git config user.email "bot@lunarfront.tech"
git add manager/deployment.yaml git add manager/deployment.yaml
git commit -m "chore: update manager image to v${{ steps.version.outputs.version }}" git commit -m "chore: update manager image to v${{ steps.version.outputs.version }}"
git push origin main GIT_SSH_COMMAND="ssh -i ~/.ssh/charts_deploy_key" git push origin main
- name: Logout - name: Logout
if: always() if: always()