Add a stage branch deploy beside production on z00.
Pushing stage runs CI and deploys to stage.transcribe.z00.nu with its own data, Reverb credentials, and Caddy network.
This commit is contained in:
@@ -8,6 +8,7 @@ REPO_OWNER="${REPO_OWNER:-ben}"
|
||||
REPO_NAME="${REPO_NAME:-AndyTranscribe}"
|
||||
REGISTRY_HOST="${REGISTRY_HOST:-gitea.z00.nu}"
|
||||
DEPLOY_PATH="${DEPLOY_PATH:-${HOME}/andyTranscibe}"
|
||||
STAGE_DEPLOY_PATH="${STAGE_DEPLOY_PATH:-${HOME}/andyTranscibe-stage}"
|
||||
CREDENTIALS_FILE="${GITEA_DIR}/.credentials"
|
||||
|
||||
if [[ ! -f "${CREDENTIALS_FILE}" ]]; then
|
||||
@@ -57,6 +58,7 @@ set_secret() {
|
||||
|
||||
set_secret "REGISTRY_TOKEN" "${CI_TOKEN}"
|
||||
set_secret "DEPLOY_PATHS" "${DEPLOY_PATH}"
|
||||
set_secret "STAGE_DEPLOY_PATHS" "${STAGE_DEPLOY_PATH}"
|
||||
|
||||
printf '%s' "${PULL_TOKEN}" | docker login "${REGISTRY_HOST}" -u "${ADMIN_USERNAME}" --password-stdin
|
||||
|
||||
@@ -77,4 +79,6 @@ fi
|
||||
|
||||
echo "Gitea CI secrets configured for ${REGISTRY_HOST}/${REPO_OWNER}/${REPO_NAME}"
|
||||
echo "Deploy path: ${DEPLOY_PATH}"
|
||||
echo "Push to main to build, push the image, and deploy."
|
||||
echo "Stage deploy path: ${STAGE_DEPLOY_PATH}"
|
||||
echo "Push to main to deploy production; push to stage to deploy https://stage.transcribe.z00.nu"
|
||||
echo "First-time stage instance: ./scripts/setup-stage.sh"
|
||||
|
||||
Reference in New Issue
Block a user