Skip to content

πŸ“š The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.

Fix deploy

Veauville Raphael04b261ca326d
diff --git a/.github/workflows/deploy_to_prod.yml b/.github/workflows/deploy_to_prod.yml
index 7df4084c..8504e1d5 100755
--- a/.github/workflows/deploy_to_prod.yml
+++ b/.github/workflows/deploy_to_prod.yml
@@ -16,9 +16,14 @@ jobs:
- name: Deploy to VPS
run: |
echo "${{ secrets.DEPLOY_SSH_KEY }}" > deploy_key
- cat deploy_key
chmod 600 deploy_key
mkdir -p ~/.ssh
+ if [ -s deploy_key ]; then
+ echo "deploy_key is not empty."
+ else
+ echo "deploy_key is empty. Exiting with status code 42."
+ exit 42
+ fi
ssh-keyscan -t rsa ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
scp -i deploy_key -r frontend/* ${{ secrets.SSH_HOST }}:/home/smaug/sites/alexandrie/frontend
scp -i deploy_key -r dashboard/* ${{ secrets.SSH_HOST }}:/home/smaug/sites/alexandrie/dashboard