Update build process in Containerfile and enhance deploy script with remote URL configuration
This commit is contained in:
parent
0f43bb18cc
commit
90a8bf7e3d
2 changed files with 6 additions and 9 deletions
|
|
@ -4,11 +4,13 @@ set -euo pipefail
|
|||
VPS="${1:-hetzner}"
|
||||
REMOTE_BRANCH="${2:-main}"
|
||||
REMOTE_BASE='/opt/websites/adrian-altner.de'
|
||||
REMOTE_URL='ssh://git@git.altner.cloud/adrian/adrian-altner.de.git'
|
||||
|
||||
# --- 1. Pull latest from repo ---
|
||||
ssh "$VPS" "
|
||||
set -euo pipefail
|
||||
cd '$REMOTE_BASE'
|
||||
git remote set-url origin '$REMOTE_URL'
|
||||
git fetch --prune origin '$REMOTE_BRANCH'
|
||||
git checkout '$REMOTE_BRANCH'
|
||||
git reset --hard 'origin/$REMOTE_BRANCH'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue