Push master.conf to all partners immediately on raw-editor save

vv_push_master_conf() in config.php: finds all remote HOST* entries,
resolves Tailscale IPs, SCPs master.conf to each.
rawconf.php calls it after a successful write when file=master.conf.
Scheduler save button shows sync status: "✓ Saved · synced to HOST2"
or "✓ Saved · push failed: HOST2" on error.

Also fix path bug in partnership_transfer.sh — was SCPing to
appdata root instead of Configurations/.
This commit is contained in:
Gmer4Lfe
2026-05-30 14:21:02 -04:00
parent 26f3778786
commit da0c303f22
4 changed files with 59 additions and 7 deletions
+3 -1
View File
@@ -22,7 +22,9 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
echo json_encode(['ok' => false, 'error' => 'Not allowed']);
exit;
}
echo json_encode(['ok' => vv_write_conf_raw($file, $content)]);
$written = vv_write_conf_raw($file, $content);
$push = ($written && $file === 'master.conf') ? vv_push_master_conf() : [];
echo json_encode(['ok' => $written, 'push' => $push]);
exit;
}