Compare commits

..

13 Commits

Author SHA1 Message Date
680b0f46e5 normalize secrets and print key fingerprint
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 5s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:36:58 +03:00
6bc46e73c5 use base64-encoded SSH key
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 7s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:33:26 +03:00
cacbd7620a ci test 9
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 7s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:30:58 +03:00
581c5bdb62 add ssh debug to deploy
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 5s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:22:49 +03:00
a80330622e harden ssh key handling in deploy
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 5s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:21:28 +03:00
3e8f611cd3 ci test 8
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 8s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:20:05 +03:00
c420534639 run workflow on ubuntu-latest runner image
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 1m21s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:16:12 +03:00
68b862fe6f ci test 7
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 3m53s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:12:00 +03:00
55ad4fa4ed ci test 6
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 2s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:07:12 +03:00
e3590b8a93 ci test 5
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 1s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-06 00:03:51 +03:00
47fad37675 ci test 4
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 1s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:53:12 +03:00
b1db95bd2e ci test 3
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 1s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:50:36 +03:00
e46554e5dd ci test 2
Some checks failed
Deploy to my-vpn / deploy (push) Failing after 1s
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-05 23:48:50 +03:00
4 changed files with 27 additions and 9 deletions

View File

@@ -7,18 +7,24 @@ on:
jobs: jobs:
deploy: deploy:
runs-on: [linux, x64, server-2] runs-on: ubuntu-latest
steps: steps:
- name: Deploy via SSH - name: Deploy via SSH
env: env:
VPN_HOST: ${{ secrets.VPN_HOST }} VPN_HOST: ${{ secrets.VPN_HOST }}
VPN_USER: ${{ secrets.VPN_USER }} VPN_USER: ${{ secrets.VPN_USER }}
VPN_SSH_KEY: ${{ secrets.TEST_KEY }} VPN_SSH_KEY_B64: ${{ secrets.TEST_KEY_B64 }}
run: | run: |
set -euo pipefail
mkdir -p ~/.ssh mkdir -p ~/.ssh
chmod 700 ~/.ssh chmod 700 ~/.ssh
echo "$VPN_SSH_KEY" > ~/.ssh/id_ci_runner printf '%s' "$VPN_SSH_KEY_B64" | base64 -d > ~/.ssh/id_ci_runner
chmod 600 ~/.ssh/id_ci_runner chmod 600 ~/.ssh/id_ci_runner
ssh-keyscan -H "$VPN_HOST" >> ~/.ssh/known_hosts VPN_USER="$(printf '%s' "$VPN_USER" | tr -d '\r\n')"
VPN_HOST="$(printf '%s' "$VPN_HOST" | tr -d '\r\n')"
echo "using user=${VPN_USER} host=${VPN_HOST}"
ssh-keyscan -H "$VPN_HOST" >> ~/.ssh/known_hosts || true
ssh-keygen -lf ~/.ssh/id_ci_runner
ssh -vvv -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i ~/.ssh/id_ci_runner "${VPN_USER}@${VPN_HOST}" "echo ok"
ssh -i ~/.ssh/id_ci_runner "$VPN_USER@$VPN_HOST" "cd /srv/ip-ua && git fetch --all && git reset --hard origin/main && bash deploy/my-vpn/deploy.sh" ssh -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i ~/.ssh/id_ci_runner "${VPN_USER}@${VPN_HOST}" "cd /srv/ip-ua && git fetch --all && git reset --hard origin/main && bash deploy/my-vpn/deploy.sh"

View File

@@ -3,3 +3,19 @@
ok ok
# ci test # ci test
# ci test 2
# ci test 3
# ci test 4
# ci test 5
# ci test 6
# ci test 7
# ci test 8
# ci test 9

View File

@@ -1,3 +0,0 @@
for push
for push
for push

View File

@@ -1 +0,0 @@
h