Include the config the container endpoint now depends on
vv_cache_clear() went in without it, so every start and stop fatalled on the line after the docker command had already run — the action succeeded and the page was told it failed.
This commit is contained in:
@@ -82,12 +82,19 @@
|
||||
// |"Could not determine image"|"Unknown action"}
|
||||
//
|
||||
// DEPENDS ON
|
||||
// include/config.php vv_cache_clear()
|
||||
// api/docker_pull_worker.php detached worker for the pull_rebuild path
|
||||
// docker CLI ps, logs, start, stop, inspect
|
||||
// dynamix.docker.manager rebuild_container, when present
|
||||
// ═══════════════════════════════════════════════════════════════════════════════════════════════
|
||||
header('Content-Type: application/json');
|
||||
|
||||
// This file was self-contained until the cache invalidation below needed a shared helper, and the
|
||||
// call went in without the include. The fatal landed *after* docker stop had already run, so the
|
||||
// container went down and the page was told the action failed — the worst shape a bug here can
|
||||
// take, because the operator's next move is to try again on a machine that already did it.
|
||||
require_once dirname(__DIR__) . '/include/config.php';
|
||||
|
||||
define('VV_JOB_DIR', '/tmp/varaverk_dk_jobs');
|
||||
|
||||
$action = trim($_POST['action'] ?? '');
|
||||
|
||||
Reference in New Issue
Block a user