Let the plugin read partner vars from the same RAM cache bash reads, so PHP and bash cannot disagree about a partner
This commit is contained in:
@@ -103,7 +103,7 @@
|
||||
# Reboot-surviving backup written by conf_cache_save.sh. Consumed and cleared here.
|
||||
#
|
||||
# CONF_RAM_CACHE_DIR
|
||||
# Destination RAM cache (tmpfs, /tmp/.cache/vv/d) that load_config.sh reads
|
||||
# Destination RAM cache (tmpfs, /tmp/varaverk/conf) that load_config.sh reads
|
||||
# partner vars from.
|
||||
#
|
||||
# PARTNERSHIP_ENABLED
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
# ${SCRIPTS_DIR}, so it follows the active storage mode.
|
||||
#
|
||||
# CONF_RAM_CACHE_DIR
|
||||
# Source RAM cache (tmpfs, /tmp/.cache/vv/d) populated by conf_sync.sh.
|
||||
# Source RAM cache (tmpfs, /tmp/varaverk/conf) populated by conf_sync.sh.
|
||||
#
|
||||
# PARTNERSHIP_ENABLED
|
||||
# Checked via require_partnership().
|
||||
|
||||
@@ -5,19 +5,19 @@
|
||||
#
|
||||
# PURPOSE
|
||||
# ─────────────────────────────────────────────────────────────────────────────
|
||||
# Maintains a RAM-resident conf cache at /tmp/.cache/vv/d/.
|
||||
# Maintains a RAM-resident conf cache at /tmp/varaverk/conf/.
|
||||
# Credentials and partner keys live in RAM only — never on disk across hosts.
|
||||
#
|
||||
# On array start (default / --array-start):
|
||||
# 1. Copy own conf to local cache
|
||||
# 2. Pull each available partner's conf from their disk → local cache
|
||||
# 3. Push own conf to each available partner's /tmp/.cache/vv/d/ cache
|
||||
# 3. Push own conf to each available partner's /tmp/varaverk/conf/ cache
|
||||
#
|
||||
# On conf save (--push-only):
|
||||
# Fast path — push updated own conf to all partners' /tmp/.cache/vv/d/ only.
|
||||
# Fast path — push updated own conf to all partners' /tmp/varaverk/conf/ only.
|
||||
# No pulls, no local cache rebuild.
|
||||
#
|
||||
# Cache is /tmp/.cache/vv/d (tmpfs) — cleared every reboot, repopulated by
|
||||
# Cache is /tmp/varaverk/conf (tmpfs) — cleared every reboot, repopulated by
|
||||
# this script on next array start. Scripts source from cache for partner vars;
|
||||
# own vars always come from disk (load_config.sh skips cached copy of own conf).
|
||||
#
|
||||
@@ -45,7 +45,7 @@
|
||||
#
|
||||
# RAM-Only Credentials
|
||||
# Partner credentials and keys never touch disk on the receiving server.
|
||||
# /tmp/.cache/vv/d is tmpfs — cleared every reboot. This is intentional:
|
||||
# /tmp/varaverk/conf is tmpfs — cleared every reboot. This is intentional:
|
||||
# partner conf files are not discoverable on disk between boots.
|
||||
#
|
||||
# Pull Resolves Remote Path
|
||||
@@ -104,7 +104,7 @@
|
||||
# Master toggle for conf syncing (default: true)
|
||||
#
|
||||
# CONF_RAM_CACHE_DIR
|
||||
# tmpfs cache both ends read partner vars from (/tmp/.cache/vv/d). Cleared every
|
||||
# tmpfs cache both ends read partner vars from (/tmp/varaverk/conf). Cleared every
|
||||
# reboot, which is why conf_cache_save.sh / conf_cache_restore.sh exist.
|
||||
#
|
||||
# SSH_KEY
|
||||
@@ -245,7 +245,7 @@ for host_var in $(compgen -v | grep -E '^HOST[0-9]+$' | sort); do
|
||||
fi
|
||||
fi
|
||||
|
||||
# ── Push: send own conf to partner's /tmp/.cache/vv/d/ cache ───────────
|
||||
# ── Push: send own conf to partner's /tmp/varaverk/conf/ cache ───────────
|
||||
if [[ "$PULL_ONLY" == true ]]; then
|
||||
continue
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user