feat: add fixed enterprise Agent gate

Part 2/4 of verified local 18dfdfd: fail-closed navigation and intent gate, fixed Agent connector, loopback code-channel candidate scripts and tests.
This commit is contained in:
bingshuo 2026-07-26 23:13:12 +08:00
commit 8485822da6
10 changed files with 643 additions and 49 deletions

View file

@ -4,10 +4,10 @@ RUN_MODE = prod
[database]
DB_TYPE = sqlite3
PATH = /var/lib/guanghu/code-channel/candidates/hlcc-v16.0.1/data/hlcc.db
PATH = /var/lib/guanghu-enterprise-code-channel/candidates/hlcc-v16.0.1/data/hlcc.db
[repository]
ROOT = /var/lib/guanghu/code-channel/candidates/hlcc-v16.0.1/data/repositories
ROOT = /var/lib/guanghu-enterprise-code-channel/candidates/hlcc-v16.0.1/data/repositories
[server]
DOMAIN = 127.0.0.1

View file

@ -2,8 +2,9 @@
set -euo pipefail
readonly HLCC_VERSION="16.0.1"
readonly HLCC_ROOT="/var/lib/guanghu/code-channel/candidates/hlcc-v${HLCC_VERSION}"
readonly HLCC_SOURCE_ARCHIVE="/var/lib/guanghu/code-channel/offline-source/hlcc-v${HLCC_VERSION}"
readonly HLCC_STATE_ROOT="/var/lib/guanghu-enterprise-code-channel"
readonly HLCC_ROOT="${HLCC_STATE_ROOT}/candidates/hlcc-v${HLCC_VERSION}"
readonly HLCC_SOURCE_ARCHIVE="${HLCC_STATE_ROOT}/offline-source/hlcc-v${HLCC_VERSION}"
readonly HLCC_RELEASE_KEY="EB114F5E6C0DC2BCDD183550A4B61A2DC5923710"
readonly HLCC_PACKAGE_SOURCE="${1:-}"
readonly HLCC_CONFIG_SOURCE="${2:-}"

View file

@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -euo pipefail
readonly HLCC_ROOT="/var/lib/guanghu/code-channel/candidates/hlcc-v16.0.1"
readonly HLCC_ROOT="/var/lib/guanghu-enterprise-code-channel/candidates/hlcc-v16.0.1"
readonly HLCC_PID_FILE="${HLCC_ROOT}/hlcc.pid"
readonly HLCC_LOG_FILE="${HLCC_ROOT}/logs/hlcc.log"
@ -39,6 +39,6 @@ if ! kill -0 "${candidate_pid}" 2>/dev/null; then
fi
curl --fail --silent --show-error \
"http://127.0.0.1:3340/api/v1/version"
"http://127.0.0.1:3340/api/healthz"
echo
echo "HLCC isolated candidate is running on loopback only."

View file

@ -1,7 +1,7 @@
#!/usr/bin/env bash
set -euo pipefail
readonly HLCC_ROOT="/var/lib/guanghu/code-channel/candidates/hlcc-v16.0.1"
readonly HLCC_ROOT="/var/lib/guanghu-enterprise-code-channel/candidates/hlcc-v16.0.1"
readonly HLCC_PID_FILE="${HLCC_ROOT}/hlcc.pid"
if [[ "$(id -un)" != "guanghu" ]]; then