mirror of
https://github.com/jhd3197/ServerKit.git
synced 2026-10-23 19:49:14 +09:00
57 lines
2.8 KiB
Bash
57 lines
2.8 KiB
Bash
# ServerKit staging target profile — TEMPLATE (safe to commit).
|
|
#
|
|
# Copy this to deploy/targets/<name>.env and fill it in for a real box:
|
|
#
|
|
# cp deploy/targets/example.env deploy/targets/testbox.env
|
|
# $EDITOR deploy/targets/testbox.env
|
|
# bash scripts/stage.sh push testbox && \
|
|
# bash scripts/stage.sh deploy testbox && \
|
|
# bash scripts/stage.sh verify testbox
|
|
#
|
|
# Real profiles are GIT-IGNORED (deploy/targets/*.env except this template), so
|
|
# hosts, keys and paths never enter the repo or a chat transcript. There are NO
|
|
# credentials here on purpose: STAGE_HOST is an alias from your ~/.ssh/config,
|
|
# and key auth comes from there. The staging scripts NEVER prompt — a missing
|
|
# value below is a hard error naming the key, not a question.
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# STAGE_HOST (required) — an alias defined in your ~/.ssh/config.
|
|
# ---------------------------------------------------------------------------
|
|
# Define the box ONCE in ~/.ssh/config so no host/user/key ever lives here:
|
|
#
|
|
# Host testbox
|
|
# HostName 203.0.113.10
|
|
# User root
|
|
# IdentityFile ~/.ssh/testbox_ed25519
|
|
#
|
|
# Then set the alias — `ssh testbox` must work non-interactively (key auth, host
|
|
# key already trusted). An agent driving through an SSH channel uses the same
|
|
# alias, so credentials stay out of the conversation.
|
|
STAGE_HOST=testbox
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# STAGE_DIR (required) — where the PARALLEL staging instance lives on the box.
|
|
# ---------------------------------------------------------------------------
|
|
# Must NOT be the live install dir (/opt/serverkit) in the default parallel
|
|
# mode — bootstrap hard-errors on that unless STAGE_MODE=replace. The uploaded
|
|
# payload lands in "<STAGE_DIR>.src".
|
|
STAGE_DIR=/opt/serverkit-staging
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# STAGE_PORT (required) — the loopback port the staging backend binds.
|
|
# ---------------------------------------------------------------------------
|
|
# Something other than the live panel's 5000. Staging binds 127.0.0.1 only
|
|
# (verification runs on-box); nothing half-tested is exposed unless you pass
|
|
# --expose to `push`.
|
|
STAGE_PORT=5100
|
|
|
|
# ---------------------------------------------------------------------------
|
|
# STAGE_MODE (optional, default: parallel)
|
|
# ---------------------------------------------------------------------------
|
|
# parallel — own dir, own venv, own .env/keys/SQLite, own systemd unit
|
|
# (serverkit-staging), loopback-bound. The live panel is never
|
|
# touched. This is the default and the safe choice.
|
|
# replace — DANGER: deploy directly over STAGE_DIR even if it is the live
|
|
# install. Only for dedicated scratch boxes / throwaway VMs.
|
|
STAGE_MODE=parallel
|