29 lines
No EOL
781 B
YAML
29 lines
No EOL
781 B
YAML
on: [push]
|
|
jobs:
|
|
print-content:
|
|
runs-on: native
|
|
steps:
|
|
- name: Run uname
|
|
run: uname -a
|
|
- name: checkout code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup SSH Key
|
|
run: |
|
|
echo "${{ secrets.SSH_KEY }}" > ssh_key
|
|
chmod 600 ssh_key
|
|
|
|
- name: Build
|
|
run: |
|
|
source /etc/bashrc
|
|
nix shell nixpkgs#bun --command bash -c 'bun i && bun run build'
|
|
|
|
- name: Deploy
|
|
run: |
|
|
source /etc/bashrc
|
|
nix shell nixpkgs#rsync nixpkgs#openssh --command bash -c 'rsync -avz --delete -e "ssh -i ssh_key -o StrictHostKeyChecking=no" dist/* imnyang@10.11.8.101:/var/static/imnya.ng/.'
|
|
|
|
- name: Cleanup
|
|
if: always()
|
|
run: |
|
|
rm -f ssh_key |