fix: verify code queue deploy commit
This commit is contained in:
@@ -321,6 +321,8 @@ function readConfig(): RuntimeConfig {
|
||||
port: envNumber("PORT", 4222),
|
||||
dataDir,
|
||||
instanceId: envString("CODE_QUEUE_INSTANCE_ID", mainProviderId),
|
||||
deployCommit: envString("CODE_QUEUE_DEPLOY_COMMIT", "unknown"),
|
||||
deployRequestedCommit: envString("CODE_QUEUE_DEPLOY_REQUESTED_COMMIT", ""),
|
||||
schedulerEnabled: envBool("CODE_QUEUE_SCHEDULER_ENABLED", true),
|
||||
startupOaBackfillEnabled: envBool("CODE_QUEUE_STARTUP_OA_BACKFILL_ENABLED", false),
|
||||
outputArchiveDir: envString("CODE_QUEUE_OUTPUT_ARCHIVE_DIR", resolve(dataDir, "output-archive")),
|
||||
@@ -3818,6 +3820,10 @@ async function route(req: Request): Promise<Response> {
|
||||
ok: true,
|
||||
service: "code-queue",
|
||||
instanceId: config.instanceId,
|
||||
deploy: {
|
||||
commit: config.deployCommit,
|
||||
requestedCommit: config.deployRequestedCommit,
|
||||
},
|
||||
databaseReady,
|
||||
serviceReady,
|
||||
startedAt: serviceStartedAt,
|
||||
@@ -3827,6 +3833,10 @@ async function route(req: Request): Promise<Response> {
|
||||
ok: false,
|
||||
service: "code-queue",
|
||||
instanceId: config.instanceId,
|
||||
deploy: {
|
||||
commit: config.deployCommit,
|
||||
requestedCommit: config.deployRequestedCommit,
|
||||
},
|
||||
status: "starting",
|
||||
databaseReady,
|
||||
databaseLastError,
|
||||
@@ -3836,6 +3846,10 @@ async function route(req: Request): Promise<Response> {
|
||||
ok: true,
|
||||
service: "code-queue",
|
||||
instanceId: config.instanceId,
|
||||
deploy: {
|
||||
commit: config.deployCommit,
|
||||
requestedCommit: config.deployRequestedCommit,
|
||||
},
|
||||
schedulerEnabled: config.schedulerEnabled,
|
||||
queue: queueSummary(false, state.tasks),
|
||||
egressProxy: await providerGatewayEgressProxyStatus(),
|
||||
|
||||
@@ -33,6 +33,8 @@ export interface RuntimeConfig {
|
||||
port: number;
|
||||
dataDir: string;
|
||||
instanceId: string;
|
||||
deployCommit: string;
|
||||
deployRequestedCommit: string;
|
||||
schedulerEnabled: boolean;
|
||||
startupOaBackfillEnabled: boolean;
|
||||
outputArchiveDir: string;
|
||||
|
||||
Reference in New Issue
Block a user