22 lines
525 B
YAML
22 lines
525 B
YAML
name: Deploy Canina
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: canina
|
|
steps:
|
|
- name: Setup SSH key
|
|
shell: sh
|
|
env:
|
|
SSH_KEY: ${{ secrets.DEPLOY_KEY }}
|
|
run: |
|
|
mkdir -p ~/.ssh
|
|
echo "$SSH_KEY" > ~/.ssh/id_ed25519
|
|
chmod 600 ~/.ssh/id_ed25519
|
|
ssh-keyscan -p 2234 -H 172.17.0.1 >> ~/.ssh/known_hosts
|
|
- name: Deploy
|
|
shell: sh
|
|
run: ssh -p 2234 devops@172.17.0.1 'bash /opt/services/scripts/depcanina.sh main'
|