switch deplyment
This commit is contained in:
parent
19afa34c13
commit
ccd9aad51f
@ -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/k004373/rowing-staging/rot-updating
|
||||
scp target/$CARGO_TARGET/release/rot $SSH_USER@$SSH_HOST:/home/philipp/rowing-staging/rot-updating
|
||||
|
||||
scp staging-diff.sql $SSH_USER@$SSH_HOST:/home/k004373/rowing-staging/
|
||||
scp -r static $SSH_USER@$SSH_HOST:/home/k004373/rowing-staging/
|
||||
scp -r templates $SSH_USER@$SSH_HOST:/home/k004373/rowing-staging/
|
||||
scp -r svelte $SSH_USER@$SSH_HOST:/home/k004373/rowing-staging/
|
||||
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/
|
||||
ssh $SSH_USER@$SSH_HOST 'sudo systemctl stop rotstaging'
|
||||
ssh $SSH_USER@$SSH_HOST 'rm /home/k004373/rowing-staging/db.sqlite && cp /home/k004373/rowing/db.sqlite /home/k004373/rowing-staging/db.sqlite && mkdir -p /home/k004373/rowing-staging/svelte/build && mkdir -p /home/k004373/rowing-staging/data-ergo/thirty && mkdir -p /home/k004373/rowing-staging/data-ergo/dozen && sqlite3 /home/k004373/rowing-staging/db.sqlite < /home/k004373/rowing-staging/staging-diff.sql'
|
||||
ssh $SSH_USER@$SSH_HOST 'mv /home/k004373/rowing-staging/rot-updating /home/k004373/rowing-staging/rot'
|
||||
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 '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/k004373/rowing/rot-updating
|
||||
scp -r static $SSH_USER@$SSH_HOST:/home/k004373/rowing/
|
||||
scp -r templates $SSH_USER@$SSH_HOST:/home/k004373/rowing/
|
||||
scp -r svelte $SSH_USER@$SSH_HOST:/home/k004373/rowing/
|
||||
ssh $SSH_USER@$SSH_HOST 'mkdir -p /home/k004373/rowing/svelte/build && mkdir -p /home/k004373/rowing/data-ergo/thirty && mkdir -p /home/k004373/rowing/data-ergo/dozen'
|
||||
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'
|
||||
ssh $SSH_USER@$SSH_HOST 'sudo systemctl stop rot'
|
||||
ssh $SSH_USER@$SSH_HOST 'mv /home/k004373/rowing/rot-updating /home/k004373/rowing/rot'
|
||||
ssh $SSH_USER@$SSH_HOST 'mv /home/philipp/rowing/rot-updating /home/philipp/rowing/rot'
|
||||
ssh $SSH_USER@$SSH_HOST 'sudo systemctl start rot'
|
||||
env:
|
||||
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
|
||||
|
@ -4,7 +4,7 @@ Description=Rot
|
||||
[Service]
|
||||
User=root
|
||||
Group=root
|
||||
WorkingDirectory=/home/k004373/rowing
|
||||
WorkingDirectory=/home/philipp/rowing
|
||||
Environment="ROCKET_ENV=prod"
|
||||
Environment="ROCKET_ADDRESS=127.0.0.1"
|
||||
Environment="ROCKET_PORT=8001"
|
||||
|
@ -4,12 +4,12 @@ Description=Rot Staging
|
||||
[Service]
|
||||
User=root
|
||||
Group=root
|
||||
WorkingDirectory=/home/k004373/rowing-staging
|
||||
WorkingDirectory=/home/philipp/rowing-staging
|
||||
Environment="ROCKET_ENV=prod"
|
||||
Environment="ROCKET_ADDRESS=127.0.0.1"
|
||||
Environment="ROCKET_PORT=7999"
|
||||
Environment="ROCKET_LOG=info"
|
||||
ExecStart=/home/k004373/rowing-staging/rot
|
||||
ExecStart=/home/philipp/rowing-staging/rot
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
Loading…
Reference in New Issue
Block a user