From f70766e817abd1d2706f92e7adf4c66eaeeebb5e Mon Sep 17 00:00:00 2001 From: philipp Date: Fri, 15 Mar 2024 09:10:56 +0100 Subject: [PATCH] move to hetzner server --- .gitea/workflows/action.yml | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/.gitea/workflows/action.yml b/.gitea/workflows/action.yml index 07996d0..0b6fce8 100644 --- a/.gitea/workflows/action.yml +++ b/.gitea/workflows/action.yml @@ -80,15 +80,15 @@ jobs: echo "$SSH_PRIVATE_KEY" > ~/.ssh/id_rsa chmod 600 ~/.ssh/id_rsa - scp target/$CARGO_TARGET/release/rot $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/rot-updating + scp target/$CARGO_TARGET/release/rot $SSH_USER@$SSH_HOST:/home/rowing-staging/rot-updating - scp staging-diff.sql $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/ - scp -r static $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/ - scp -r templates $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/ - scp -r svelte $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/ + scp staging-diff.sql $SSH_USER@$SSH_HOST:/home/rowing-staging/ + scp -r static $SSH_USER@$SSH_HOST:/home/rowing-staging/ + scp -r templates $SSH_USER@$SSH_HOST:/home/rowing-staging/ + scp -r svelte $SSH_USER@$SSH_HOST:/home/rowing-staging/ ssh $SSH_USER@$SSH_HOST 'sudo systemctl stop rotstaging' - ssh $SSH_USER@$SSH_HOST 'rm /home/philipp/rowing-staging/db.sqlite && cp /home/philipp/rowing/db.sqlite /home/philipp/rowing-staging/db.sqlite && mkdir -p /home/philipp/rowing-staging/svelte/build && mkdir -p /home/philipp/rowing-staging/data-ergo/thirty && mkdir -p /home/philipp/rowing-staging/data-ergo/dozen && sqlite3 /home/philipp/rowing-staging/db.sqlite < /home/philipp/rowing-staging/staging-diff.sql' - ssh $SSH_USER@$SSH_HOST 'mv /home/philipp/rowing-staging/rot-updating /home/philipp/rowing-staging/rot' + ssh $SSH_USER@$SSH_HOST 'rm /home/rowing-staging/db.sqlite && cp /home/rowing/db.sqlite /home/rowing-staging/db.sqlite && mkdir -p /home/rowing-staging/svelte/build && mkdir -p /home/rowing-staging/data-ergo/thirty && mkdir -p /home/rowing-staging/data-ergo/dozen && sqlite3 /home/rowing-staging/db.sqlite < /home/rowing-staging/staging-diff.sql' + ssh $SSH_USER@$SSH_HOST 'mv /home/rowing-staging/rot-updating /home/rowing-staging/rot' ssh $SSH_USER@$SSH_HOST 'sudo systemctl start rotstaging' env: SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }} @@ -132,13 +132,13 @@ jobs: echo "$SSH_PRIVATE_KEY" > ~/.ssh/id_rsa chmod 600 ~/.ssh/id_rsa - scp target/$CARGO_TARGET/release/rot $SSH_USER@$SSH_HOST:/home/philipp/rowing/rot-updating - scp -r static $SSH_USER@$SSH_HOST:/home/philipp/rowing/ - scp -r templates $SSH_USER@$SSH_HOST:/home/philipp/rowing/ - scp -r svelte $SSH_USER@$SSH_HOST:/home/philipp/rowing/ - ssh $SSH_USER@$SSH_HOST 'mkdir -p /home/philipp/rowing/svelte/build && mkdir -p /home/philipp/rowing/data-ergo/thirty && mkdir -p /home/philipp/rowing/data-ergo/dozen' + scp target/$CARGO_TARGET/release/rot $SSH_USER@$SSH_HOST:/home/rowing/rot-updating + scp -r static $SSH_USER@$SSH_HOST:/home/rowing/ + scp -r templates $SSH_USER@$SSH_HOST:/home/rowing/ + scp -r svelte $SSH_USER@$SSH_HOST:/home/rowing/ + ssh $SSH_USER@$SSH_HOST 'mkdir -p /home/rowing/svelte/build && mkdir -p /home/rowing/data-ergo/thirty && mkdir -p /home/rowing/data-ergo/dozen' ssh $SSH_USER@$SSH_HOST 'sudo systemctl stop rot' - ssh $SSH_USER@$SSH_HOST 'mv /home/philipp/rowing/rot-updating /home/philipp/rowing/rot' + ssh $SSH_USER@$SSH_HOST 'mv /home/rowing/rot-updating /home/rowing/rot' ssh $SSH_USER@$SSH_HOST 'sudo systemctl start rot' env: SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}