chore: improve local deploy helper feedback
This commit is contained in:
@@ -23,6 +23,13 @@ fi
|
||||
echo "Updating local branch from origin/develop..."
|
||||
git pull --ff-only origin develop
|
||||
|
||||
echo "Checking remote env file..."
|
||||
$SSH_CMD "$DEPLOY_HOST" "test -f '$DEPLOY_PATH/$REMOTE_ENV_FILE'" || {
|
||||
echo "Missing remote env file: $DEPLOY_PATH/$REMOTE_ENV_FILE" >&2
|
||||
echo "Create or restore the server env file before deploying." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
echo "Syncing repository to ${DEPLOY_HOST}:${DEPLOY_PATH} ..."
|
||||
rsync -az --delete \
|
||||
--filter 'P .env.test' \
|
||||
@@ -44,4 +51,7 @@ $SSH_CMD "$DEPLOY_HOST" \
|
||||
|
||||
echo "Verifying health endpoint..."
|
||||
curl --fail --silent --show-error --max-time 10 "$HEALTH_URL" >/dev/null
|
||||
commit_sha="$(git rev-parse --short HEAD)"
|
||||
echo "Test deployment healthy: $HEALTH_URL"
|
||||
echo "Deployed commit: $commit_sha"
|
||||
echo "Branch: $current_branch"
|
||||
|
||||
Reference in New Issue
Block a user