@askexenow/exe-os 0.9.347 → 0.9.348
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/deploy/compose/cloudflared/config.yml.example +9 -6
- package/deploy/compose/docker-compose.yml +16 -9
- package/deploy/compose/sso-edge/default.conf.template +26 -0
- package/deploy/stack-manifests/v0.9.json +1 -1
- package/dist/{active-agent-CMY7WTJL.js → active-agent-PX6KAEEQ.js} +4 -3
- package/dist/{active-agent-US4KO4LV.js → active-agent-QVLZKWR2.js} +4 -3
- package/dist/{agentic-ontology-3Y37SQYR.js → agentic-ontology-6MEXY5L7.js} +1 -1
- package/dist/{backfill-metadata-GK66TYQE.js → backfill-metadata-MCFBGWKX.js} +6 -5
- package/dist/{backup-verify-72XBKKHL.js → backup-verify-RGB3KKD4.js} +2 -1
- package/dist/{behaviors-G7TR6LBM.js → behaviors-6GI6VND2.js} +7 -6
- package/dist/bin/agentic-ontology-backfill.js +7 -6
- package/dist/bin/agentic-reflection-backfill.js +8 -7
- package/dist/bin/agentic-semantic-label.js +7 -6
- package/dist/bin/backfill-conversations.js +6 -5
- package/dist/bin/backfill-responses.js +6 -5
- package/dist/bin/backfill-vectors.js +7 -6
- package/dist/bin/bulk-sync-postgres.js +11 -10
- package/dist/bin/cc-doctor.js +5 -4
- package/dist/bin/cleanup-stale-review-tasks.js +14 -13
- package/dist/bin/cli.js +16 -16
- package/dist/bin/deferred-daemon-restart.js +105 -91
- package/dist/bin/exe-agent-config.js +4 -3
- package/dist/bin/exe-agent.js +6 -5
- package/dist/bin/exe-assign.js +7 -6
- package/dist/bin/exe-boot.js +29 -28
- package/dist/bin/exe-call.js +6 -5
- package/dist/bin/exe-cloud.js +26 -15
- package/dist/bin/exe-config-dump.js +4 -3
- package/dist/bin/exe-dispatch.js +14 -13
- package/dist/bin/exe-doctor.js +5 -4
- package/dist/bin/exe-export-behaviors.js +9 -8
- package/dist/bin/exe-forget.js +8 -7
- package/dist/bin/exe-gateway.js +8 -7
- package/dist/bin/exe-healthcheck.js +5 -4
- package/dist/bin/exe-heartbeat.js +16 -15
- package/dist/bin/exe-kill.js +18 -17
- package/dist/bin/exe-launch-agent.js +24 -23
- package/dist/bin/exe-memory-reads.js +6 -5
- package/dist/bin/exe-new-employee.js +10 -9
- package/dist/bin/exe-os-mcp-proxy.js +4 -3
- package/dist/bin/exe-pending-messages.js +15 -14
- package/dist/bin/exe-pending-notifications.js +14 -13
- package/dist/bin/exe-pending-reviews.js +14 -13
- package/dist/bin/exe-rename.js +6 -5
- package/dist/bin/exe-review.js +17 -16
- package/dist/bin/exe-search.js +7 -6
- package/dist/bin/exe-session-cleanup.js +18 -17
- package/dist/bin/exe-settings.js +12 -11
- package/dist/bin/exe-start-codex.js +97 -15
- package/dist/bin/exe-start-opencode.js +10 -9
- package/dist/bin/exe-status.js +15 -14
- package/dist/bin/exe-support.js +3 -3
- package/dist/bin/exe-team.js +4 -3
- package/dist/bin/git-sweep.js +15 -14
- package/dist/bin/graph-backfill.js +7 -6
- package/dist/bin/graph-export.js +7 -6
- package/dist/bin/import-history.js +10 -9
- package/dist/bin/install.js +71 -70
- package/dist/bin/intercom-check.js +4 -4
- package/dist/bin/mcp-sessions.js +2 -2
- package/dist/bin/orchestration-metrics.js +5 -4
- package/dist/bin/postgres-agentic-reflection-backfill.js +2 -2
- package/dist/bin/postgres-agentic-semantic-backfill.js +1 -1
- package/dist/bin/pre-publish.js +1 -1
- package/dist/bin/reconcile-backlog.js +2 -2
- package/dist/bin/registry-proxy.js +1 -1
- package/dist/bin/scan-tasks.js +14 -13
- package/dist/bin/setup.js +1 -1
- package/dist/bin/shard-migrate.js +6 -5
- package/dist/bin/stack-update.js +7 -6
- package/dist/bin/vps-health-gate.js +1 -1
- package/dist/{boot-generation-KG43UYL4.js → boot-generation-FB2J53IG.js} +4 -3
- package/dist/{boot-review-sections-56BRURLM.js → boot-review-sections-QF5MZGJI.js} +13 -12
- package/dist/{capability-cards-4MN3IVJO.js → capability-cards-YADEM2KN.js} +3 -2
- package/dist/{capacity-monitor-4NJTN5QQ.js → capacity-monitor-CG2IGONS.js} +15 -14
- package/dist/{catchup-brief-AMBXLHXU.js → catchup-brief-QFVNMTU5.js} +18 -17
- package/dist/{chunk-PYNWGP72.js → chunk-23O6LHII.js} +1 -1
- package/dist/{chunk-VDJUATQJ.js → chunk-27REQ7KR.js} +1 -1
- package/dist/{chunk-G4HOMQY7.js → chunk-2AD2GAPC.js} +1 -1
- package/dist/{chunk-QZA5NG6Z.js → chunk-2WJYLXPF.js} +1 -1
- package/dist/{chunk-G6IANQKD.js → chunk-43RTUMUT.js} +1 -1
- package/dist/{chunk-WOKPKILI.js → chunk-5C46Y4AK.js} +1 -1
- package/dist/{chunk-IMHERTUL.js → chunk-5KCC26FB.js} +2 -2
- package/dist/{chunk-XRX7F7XW.js → chunk-5RPCWLXE.js} +1 -1
- package/dist/{chunk-DZJL775P.js → chunk-6GSYN262.js} +1 -1
- package/dist/{chunk-UMK7TNCF.js → chunk-6JQTSKDR.js} +157 -65
- package/dist/{chunk-2BOEUPL6.js → chunk-6QRS3IZF.js} +1 -1
- package/dist/{chunk-M722B4DA.js → chunk-6WFXNQDJ.js} +1 -1
- package/dist/{chunk-LUQ57SRM.js → chunk-7QRMFYOV.js} +23 -9
- package/dist/{chunk-I3XN3G3H.js → chunk-7WQ3WHPW.js} +113 -113
- package/dist/{chunk-3EMAJBBN.js → chunk-A3YHWWE6.js} +1 -1
- package/dist/{chunk-JLYQD2XF.js → chunk-A42356G7.js} +1 -1
- package/dist/{chunk-EYWB6526.js → chunk-A43SIGAO.js} +3 -3
- package/dist/{chunk-Z7DWUHDP.js → chunk-AFY4V4N3.js} +1 -1
- package/dist/{chunk-MT6YGWJ6.js → chunk-AMC2OPYP.js} +1 -1
- package/dist/{chunk-SUG5P42S.js → chunk-AQ24P2O7.js} +4 -4
- package/dist/{chunk-T7ZLJZAO.js → chunk-AUILJKSM.js} +2 -2
- package/dist/{chunk-PRUZNNEF.js → chunk-AXNUMBLO.js} +3 -3
- package/dist/{chunk-PEVOVM3W.js → chunk-BOQUXG7N.js} +3 -3
- package/dist/{chunk-ILLBFFY6.js → chunk-BUUGFQHL.js} +2 -2
- package/dist/{chunk-VMTKHDFM.js → chunk-CCOKYSJA.js} +3 -3
- package/dist/{chunk-YSTIPPZK.js → chunk-DAODOSH4.js} +1 -1
- package/dist/{chunk-LJGHAZYU.js → chunk-DJYJDK53.js} +7 -7
- package/dist/{chunk-K3ZHVW26.js → chunk-DXMTJJP3.js} +4 -4
- package/dist/{chunk-IRMJHC23.js → chunk-E3BNUQHW.js} +2 -2
- package/dist/{chunk-CNIAEIWV.js → chunk-EFHGK6JP.js} +1 -1
- package/dist/{chunk-FM4ZI5ZP.js → chunk-FE6WBI2M.js} +5 -1
- package/dist/{chunk-DBDMZTU5.js → chunk-FENYNW52.js} +1 -1
- package/dist/{chunk-FJPZ7KHN.js → chunk-FFCPSPNK.js} +1 -1
- package/dist/{chunk-FAH7JUNS.js → chunk-FPK753IZ.js} +10 -10
- package/dist/{chunk-F6NABQJ4.js → chunk-GA655CUD.js} +2 -2
- package/dist/{chunk-BRVDGE7N.js → chunk-GJ6KIHOM.js} +4 -4
- package/dist/{chunk-2ESYTX6F.js → chunk-GKNWKQFY.js} +1 -1
- package/dist/{chunk-3HGAAWNZ.js → chunk-GLOWJP5H.js} +2 -2
- package/dist/{chunk-DNN27P35.js → chunk-H3TA23PH.js} +4 -4
- package/dist/{chunk-TQSAPNFW.js → chunk-H5QNVWU4.js} +18 -10
- package/dist/{chunk-PO64LWTM.js → chunk-HL24OHHS.js} +9 -9
- package/dist/{chunk-FDOURKUO.js → chunk-HYZE3MNS.js} +1 -1
- package/dist/{chunk-3T4BRBSH.js → chunk-JORPYG4O.js} +1 -1
- package/dist/{chunk-2LZMDOC6.js → chunk-JW5XS35A.js} +5 -5
- package/dist/{chunk-3LQMUO5D.js → chunk-KIMAQNSM.js} +3 -3
- package/dist/{chunk-AHR3F7HW.js → chunk-KZUU6MNF.js} +1 -1
- package/dist/{chunk-VALVWYAK.js → chunk-L36RX54F.js} +5 -5
- package/dist/{chunk-UO56K55W.js → chunk-M7PBRIRH.js} +1 -1
- package/dist/{chunk-4VLRGKNY.js → chunk-MGMXYI7Y.js} +2 -2
- package/dist/{chunk-MESFJRIT.js → chunk-MH5HWMVH.js} +1 -1
- package/dist/{chunk-ZK53K7OR.js → chunk-MMOONM6D.js} +1 -1
- package/dist/{chunk-CQN4IKRB.js → chunk-MMXIE6HV.js} +1 -1
- package/dist/{chunk-VA3ZUIWG.js → chunk-MOZY4IQO.js} +1 -1
- package/dist/{chunk-VTMSGELG.js → chunk-MVZLF27P.js} +2 -2
- package/dist/{chunk-H44V3Y6D.js → chunk-NY6DU5RB.js} +1 -1
- package/dist/{chunk-F4ZW76IX.js → chunk-O522M4YZ.js} +1 -1
- package/dist/{chunk-7667KFAG.js → chunk-OBWIVRD6.js} +1 -1
- package/dist/{chunk-VDKDW5IA.js → chunk-PAXAF2UY.js} +29 -9
- package/dist/{chunk-QFGUAJ6T.js → chunk-PBLDPW4U.js} +2 -2
- package/dist/{chunk-D74XYSA3.js → chunk-QCQT5RXR.js} +5 -1
- package/dist/{chunk-ZY2ABBVR.js → chunk-QNKR7WEL.js} +20 -6
- package/dist/{chunk-XOVHWGPV.js → chunk-RBRGSOK5.js} +1 -1
- package/dist/{chunk-Y7637VDZ.js → chunk-RFRUDXOI.js} +2 -2
- package/dist/{chunk-7AD4GSRT.js → chunk-SLH2743O.js} +3 -3
- package/dist/{chunk-OE6D2IJI.js → chunk-SMQ642D3.js} +4 -4
- package/dist/{chunk-4K2PLZKF.js → chunk-SQ4WACH4.js} +1 -1
- package/dist/{chunk-HWK5GKE6.js → chunk-TF5E6O5Q.js} +1 -1
- package/dist/{chunk-KWRO4RMT.js → chunk-TLWYOMSS.js} +3 -3
- package/dist/{chunk-XDVLCS64.js → chunk-UAKGNQWE.js} +1 -1
- package/dist/{chunk-JYFBQH5O.js → chunk-UTQWVRU6.js} +5 -5
- package/dist/{chunk-FBSAXAXQ.js → chunk-WL3IQJKN.js} +3 -3
- package/dist/{chunk-BMTUSSHV.js → chunk-WUMWXU6B.js} +1 -1
- package/dist/{chunk-W7HKGDJO.js → chunk-WWT3E7DO.js} +3 -3
- package/dist/{chunk-YJK4JZ35.js → chunk-WZJ3VYRJ.js} +3 -3
- package/dist/{chunk-QIALRZZG.js → chunk-X6VEQ7MC.js} +1 -1
- package/dist/{chunk-W666YWFU.js → chunk-Y3JXLIZV.js} +3 -3
- package/dist/{chunk-M3NSYVE3.js → chunk-YAIFZXOM.js} +5 -5
- package/dist/{chunk-ZYNQXN73.js → chunk-YM6GJM2F.js} +4 -4
- package/dist/chunk-YMUZWC33.js +8 -0
- package/dist/{chunk-7DAJHBFH.js → chunk-YTPCJLEL.js} +1 -1
- package/dist/{chunk-53VXPGZ2.js → chunk-Z52QQB4Z.js} +2 -2
- package/dist/{chunk-EWWCMMES.js → chunk-ZXSFUR77.js} +16 -16
- package/dist/{cleanup-graph-garbage-5HKGGUS3.js → cleanup-graph-garbage-XTSBQXD6.js} +8 -7
- package/dist/{cloud-sync-shutdown-2JAEIAW6.js → cloud-sync-shutdown-A2QB74YM.js} +3 -2
- package/dist/{co-activation-SYSIFY66.js → co-activation-S2FVGMQP.js} +3 -2
- package/dist/{co-occurrence-QZFT5ORJ.js → co-occurrence-VQB6U5ME.js} +6 -5
- package/dist/{conversation-entity-extractor-YC3A2ODD.js → conversation-entity-extractor-YF3ZLTEJ.js} +3 -3
- package/dist/{crdt-sync-W45AKWCU.js → crdt-sync-2SGCDWC3.js} +1 -1
- package/dist/{crm-webhook-ZAGDYWB3.js → crm-webhook-P64SXEHD.js} +2 -2
- package/dist/{cto-delegation-gate-PLSICYEK.js → cto-delegation-gate-6KLGT2LB.js} +13 -12
- package/dist/{daemon-orchestration-QX3FS4L2.js → daemon-orchestration-JQGKEWPD.js} +18 -17
- package/dist/{doc-graph-extractor-NK6CP4LE.js → doc-graph-extractor-DCJMATVZ.js} +6 -5
- package/dist/{documents-FGXV6BDL.js → documents-7EPH3VPE.js} +7 -6
- package/dist/{dreaming-YIESEME7.js → dreaming-O4P2W5E5.js} +17 -16
- package/dist/{exe-drift-TLY7MCXW.js → exe-drift-ED7FBS2C.js} +4 -3
- package/dist/{exe-export-32J4WPS6.js → exe-export-YJI4USGZ.js} +9 -8
- package/dist/{exe-import-MDEWE325.js → exe-import-SUTAYKUW.js} +9 -8
- package/dist/{exe-key-NW42YUA3.js → exe-key-CRSDAOZD.js} +69 -68
- package/dist/{exe-snapshot-NNEEAGYI.js → exe-snapshot-KB4YYDCA.js} +18 -17
- package/dist/{fast-db-init-O7AECNTB.js → fast-db-init-3K2PV6GJ.js} +1 -1
- package/dist/{founder-context-3WDZ6LIS.js → founder-context-JHHFM4GF.js} +2 -2
- package/dist/gateway/index.js +9 -8
- package/dist/{git-main-guard-UZP3KXYI.js → git-main-guard-TGK3RQY3.js} +1 -1
- package/dist/{git-staleness-GEJ7U4MW.js → git-staleness-YPHGWE3B.js} +3 -2
- package/dist/{global-procedures-HY3BJXY4.js → global-procedures-PEWDBSPJ.js} +5 -4
- package/dist/{graph-auto-extract-DBAIFNDK.js → graph-auto-extract-7OJYYV4G.js} +6 -5
- package/dist/{graph-rag-LWKKHY72.js → graph-rag-YFITUAVO.js} +3 -3
- package/dist/{hook-prefetch-KNHZNI4L.js → hook-prefetch-O6ZCZCTX.js} +14 -13
- package/dist/hooks/bug-report-worker.js +16 -15
- package/dist/hooks/codex-stop-task-finalizer.js +17 -16
- package/dist/hooks/commit-complete.js +16 -15
- package/dist/hooks/error-recall.js +8 -7
- package/dist/hooks/exe-heartbeat-hook.js +4 -3
- package/dist/hooks/ingest.js +7 -6
- package/dist/hooks/instructions-loaded.js +5 -4
- package/dist/hooks/manifest.json +19 -19
- package/dist/hooks/notification.js +5 -4
- package/dist/hooks/post-compact.js +15 -14
- package/dist/hooks/post-tool-combined.js +9 -9
- package/dist/hooks/pre-compact.js +16 -15
- package/dist/hooks/pre-tool-use.js +36 -38
- package/dist/hooks/prompt-submit.js +28 -27
- package/dist/hooks/session-end.js +20 -19
- package/dist/hooks/session-start.js +13 -13
- package/dist/hooks/stop.js +19 -18
- package/dist/hooks/subagent-stop.js +17 -16
- package/dist/hooks/summary-worker.js +20 -19
- package/dist/index.js +23 -22
- package/dist/{installer-R2S64Q6T.js → installer-3ONNP5JV.js} +6 -5
- package/dist/{installer-AWALPCAX.js → installer-CY5PN7TN.js} +6 -5
- package/dist/{installer-SQF5I6YS.js → installer-N4QXGINR.js} +6 -5
- package/dist/{intercom-queue-SJL4G3J5.js → intercom-queue-A52WQOCD.js} +13 -12
- package/dist/lib/agent-config.js +1 -1
- package/dist/lib/cloud-sync.js +11 -10
- package/dist/lib/consolidation.js +8 -7
- package/dist/lib/database.js +5 -2
- package/dist/lib/db-backup.js +2 -1
- package/dist/lib/db-checkpoint-worker.js +9 -0
- package/dist/lib/db-read-worker-client.js +21 -8
- package/dist/lib/db-read-worker.js +15 -0
- package/dist/lib/db-write-worker-client.js +4 -1
- package/dist/lib/db-write-worker.js +21 -6
- package/dist/lib/db.js +5 -2
- package/dist/lib/device-registry.js +1 -1
- package/dist/lib/employee-templates.js +6 -5
- package/dist/lib/employees.js +3 -2
- package/dist/lib/exe-daemon.js +211 -71
- package/dist/lib/hybrid-search.js +7 -6
- package/dist/lib/identity.js +3 -2
- package/dist/lib/license.js +2 -2
- package/dist/lib/messaging.js +14 -13
- package/dist/lib/registry-proxy.js +1 -1
- package/dist/lib/reminders.js +4 -3
- package/dist/lib/schedules.js +7 -6
- package/dist/lib/session-registry.js +5 -4
- package/dist/lib/skill-learning.js +8 -7
- package/dist/lib/store.js +6 -5
- package/dist/lib/task-router.js +4 -3
- package/dist/lib/tasks.js +15 -14
- package/dist/lib/tmux-routing.js +13 -12
- package/dist/lib/token-spend.js +4 -3
- package/dist/{license-gate-ZYZQGPKW.js → license-gate-ZRORTAQ2.js} +3 -3
- package/dist/{license-sync-GU3L66JR.js → license-sync-CQHBDUQE.js} +2 -2
- package/dist/mcp/register-tools.js +68 -67
- package/dist/mcp/server.js +69 -68
- package/dist/mcp/tools/complete-reminder.js +5 -4
- package/dist/mcp/tools/create-reminder.js +5 -4
- package/dist/mcp/tools/create-task.js +17 -16
- package/dist/mcp/tools/deactivate-behavior.js +9 -8
- package/dist/mcp/tools/list-reminders.js +5 -4
- package/dist/mcp/tools/list-tasks.js +17 -16
- package/dist/mcp/tools/send-message.js +16 -15
- package/dist/mcp/tools/update-task.js +16 -15
- package/dist/{mcp-http-config-BV2GO7P4.js → mcp-http-config-2A6HKQP5.js} +4 -3
- package/dist/{mcp-session-identity-3QQPOGNI.js → mcp-session-identity-OPRX32H5.js} +13 -12
- package/dist/{memory-cards-NISTO4EP.js → memory-cards-GFO2CSPV.js} +6 -5
- package/dist/{memory-graph-extractor-CO3R5K7L.js → memory-graph-extractor-2Z72HN5P.js} +7 -6
- package/dist/{memory-poisoning-defense-QZCG3BMC.js → memory-poisoning-defense-WZJ52KXT.js} +3 -2
- package/dist/{memory-pressure-watchdog-VWQM3GXR.js → memory-pressure-watchdog-IG7VRFIX.js} +14 -13
- package/dist/{memory-reflection-G32OQ3X3.js → memory-reflection-LTRHDGUL.js} +3 -2
- package/dist/{notification-ledger-C3J4HFMM.js → notification-ledger-KSCPGLQG.js} +14 -13
- package/dist/{notifications-JIARMDZ5.js → notifications-YKHZPCXU.js} +13 -12
- package/dist/{orchestration-events-AL7AWHBX.js → orchestration-events-HAFDPTLV.js} +4 -3
- package/dist/{orchestrator-LWVALDUO.js → orchestrator-4MZEQULR.js} +15 -14
- package/dist/{pipeline-router-HK5BI3LQ.js → pipeline-router-RSRJPZNI.js} +4 -3
- package/dist/{plan-limits-4LMRHOUW.js → plan-limits-5QYYPIPT.js} +6 -5
- package/dist/{platform-procedures-G44IYUM2.js → platform-procedures-DZ6YABEK.js} +1 -1
- package/dist/{projection-worker-Z5U6UWCE.js → projection-worker-SKAMSZJF.js} +2 -2
- package/dist/{prospective-memory-UDQWFP5Y.js → prospective-memory-V7LFCPU4.js} +3 -2
- package/dist/{reranker-FX4QOK2G.js → reranker-HXMJ7SKW.js} +1 -1
- package/dist/{retrieval-health-2LIKKDMW.js → retrieval-health-4NCBHUUS.js} +1 -1
- package/dist/{review-polling-B2EP4KGE.js → review-polling-KQUALBEU.js} +14 -13
- package/dist/runtime/index.js +17 -16
- package/dist/{session-events-HVYX42HD.js → session-events-3KL735DZ.js} +14 -13
- package/dist/{session-kill-telemetry-BHKUHSK2.js → session-kill-telemetry-KVRGLYVI.js} +14 -13
- package/dist/{session-scope-TXCBVOSN.js → session-scope-LBG6DT5O.js} +13 -12
- package/dist/{setup-wizard-QMKBAK6B.js → setup-wizard-UL3AKI6E.js} +1 -1
- package/dist/{skill-refinement-G6BPD6QK.js → skill-refinement-6HPISXQC.js} +4 -3
- package/dist/{stack-update-CBP5S5BG.js → stack-update-WBDTJJEF.js} +7 -3
- package/dist/{steward-gate-CGP6U7KC.js → steward-gate-CWPD4HEK.js} +4 -3
- package/dist/{support-inbox-3ATAP7KN.js → support-inbox-HRIHHKPU.js} +3 -3
- package/dist/{task-enforcement-YINAK3T6.js → task-enforcement-OAOL7XFL.js} +14 -13
- package/dist/{task-scope-5OSP2MUP.js → task-scope-PSVAE3EM.js} +13 -12
- package/dist/{tasks-crud-PTN36B5F.js → tasks-crud-TLELWWUL.js} +13 -12
- package/dist/{tasks-notify-QCJXVZCJ.js → tasks-notify-7Q2XTDZ7.js} +14 -13
- package/dist/{tasks-review-ZY3S65OV.js → tasks-review-S6QB5KGS.js} +13 -12
- package/dist/{telemetry-upload-Z47OEELW.js → telemetry-upload-LTL5SW24.js} +8 -7
- package/dist/{token-budget-B3OKOYDA.js → token-budget-SK32GKFZ.js} +4 -3
- package/dist/{tool-telemetry-KIHAHUPT.js → tool-telemetry-QJGJAHOC.js} +1 -1
- package/dist/tui/App.js +22 -21
- package/dist/{tui-data-YIFXHE2D.js → tui-data-3JSV56ME.js} +13 -12
- package/dist/{update-support-IZUWVU2U.js → update-support-LMPGWJVG.js} +10 -9
- package/dist/{work-state-heartbeat-WIURKX3N.js → work-state-heartbeat-MQQOCU54.js} +1 -1
- package/dist/{worker-gate-NZRA426F.js → worker-gate-P2O64XMH.js} +1 -1
- package/dist/{workflow-engine-LAB6TGBZ.js → workflow-engine-BLLQKA3O.js} +2 -2
- package/dist/{worktree-TBUUZJHY.js → worktree-FJZXHDCJ.js} +5 -4
- package/dist/{worktree-sweep-LXDNIZPM.js → worktree-sweep-SW4AG6JR.js} +6 -5
- package/package.json +1 -1
- package/release-notes.json +26 -37
- /package/dist/{chunk-QPNXYGWG.js → chunk-AQ6ECPUP.js} +0 -0
- /package/dist/{chunk-UVPLZ6AK.js → chunk-BTP7BORU.js} +0 -0
- /package/dist/{chunk-4P7NUL4D.js → chunk-DRHXISWL.js} +0 -0
- /package/dist/{chunk-G4JZ22KK.js → chunk-E42D2E5F.js} +0 -0
- /package/dist/{chunk-MA22RV3T.js → chunk-FXZRJT3H.js} +0 -0
- /package/dist/{chunk-D4UCBR4O.js → chunk-GFIWADEH.js} +0 -0
- /package/dist/{chunk-VBHLE3TR.js → chunk-GPZQZTJB.js} +0 -0
- /package/dist/{chunk-FFUEDKYK.js → chunk-H4JKOLXU.js} +0 -0
- /package/dist/{chunk-OG2RT4IY.js → chunk-HTJKAAHD.js} +0 -0
- /package/dist/{chunk-MDK7E653.js → chunk-PIUDQ7P2.js} +0 -0
- /package/dist/{chunk-CYI2YR56.js → chunk-QUOMJKVF.js} +0 -0
- /package/dist/{chunk-SJLZ53ZR.js → chunk-XF2D4CDA.js} +0 -0
- /package/dist/{core-memory-FOW4BCPN.js → core-memory-Z7LPR3RX.js} +0 -0
- /package/dist/{oauth-server-OR4RAQYM.js → oauth-server-FSKABATB.js} +0 -0
- /package/dist/{project-boot-WP54EOAG.js → project-boot-FVSC4VQC.js} +0 -0
- /package/dist/{wiki-acl-4DQQCP4V.js → wiki-acl-CW2UALTJ.js} +0 -0
|
@@ -8,24 +8,24 @@ import {
|
|
|
8
8
|
isAtCapacity,
|
|
9
9
|
isWithinRelaunchCooldown,
|
|
10
10
|
pollCapacityDead
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
11
|
+
} from "./chunk-YAIFZXOM.js";
|
|
12
|
+
import "./chunk-Y3JXLIZV.js";
|
|
13
|
+
import "./chunk-ZXSFUR77.js";
|
|
14
|
+
import "./chunk-RBRGSOK5.js";
|
|
15
|
+
import "./chunk-OBWIVRD6.js";
|
|
16
|
+
import "./chunk-A42356G7.js";
|
|
17
17
|
import "./chunk-E23LNUWJ.js";
|
|
18
18
|
import "./chunk-4JERP7NT.js";
|
|
19
19
|
import "./chunk-EIKATSE4.js";
|
|
20
|
-
import "./chunk-
|
|
20
|
+
import "./chunk-HYZE3MNS.js";
|
|
21
21
|
import "./chunk-AD2VCHSS.js";
|
|
22
22
|
import "./chunk-WOYADZF5.js";
|
|
23
23
|
import "./chunk-SKGMF2SO.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-AMC2OPYP.js";
|
|
25
25
|
import "./chunk-AJIXH5JF.js";
|
|
26
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-A3YHWWE6.js";
|
|
27
27
|
import "./chunk-AM7S2TY6.js";
|
|
28
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-RFRUDXOI.js";
|
|
29
29
|
import "./chunk-OSKWCKUC.js";
|
|
30
30
|
import "./chunk-KI5PFRG6.js";
|
|
31
31
|
import "./chunk-CVYC6DUW.js";
|
|
@@ -39,16 +39,17 @@ import "./chunk-NLEW62VC.js";
|
|
|
39
39
|
import "./chunk-HYZV25LY.js";
|
|
40
40
|
import "./chunk-GJV3WDWM.js";
|
|
41
41
|
import "./chunk-MP2AFCGL.js";
|
|
42
|
-
import "./chunk-
|
|
42
|
+
import "./chunk-QNKR7WEL.js";
|
|
43
43
|
import "./chunk-2I23RPSI.js";
|
|
44
|
-
import "./chunk-
|
|
44
|
+
import "./chunk-FE6WBI2M.js";
|
|
45
45
|
import "./chunk-OMXJMOBD.js";
|
|
46
46
|
import "./chunk-7HLWBYH7.js";
|
|
47
47
|
import "./chunk-BBMTVAE3.js";
|
|
48
|
+
import "./chunk-YMUZWC33.js";
|
|
48
49
|
import "./chunk-FXU7JOXK.js";
|
|
49
50
|
import "./chunk-WNBZJSQT.js";
|
|
50
|
-
import "./chunk-
|
|
51
|
-
import "./chunk-
|
|
51
|
+
import "./chunk-MMOONM6D.js";
|
|
52
|
+
import "./chunk-XF2D4CDA.js";
|
|
52
53
|
import "./chunk-BCZF3AGJ.js";
|
|
53
54
|
import "./chunk-HSGBZSCA.js";
|
|
54
55
|
import "./chunk-MLKGABMK.js";
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
import {
|
|
2
2
|
lightweightSearch
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-HL24OHHS.js";
|
|
4
4
|
import "./chunk-AB4PAQYK.js";
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
import "./chunk-H5QNVWU4.js";
|
|
6
|
+
import "./chunk-H4JKOLXU.js";
|
|
7
7
|
import "./chunk-CHCA3ZM2.js";
|
|
8
8
|
import "./chunk-OTVEIJUQ.js";
|
|
9
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-GPZQZTJB.js";
|
|
10
10
|
import "./chunk-5MOYSU5A.js";
|
|
11
11
|
import "./chunk-4QCFFW2H.js";
|
|
12
12
|
import "./chunk-76CJBM36.js";
|
|
13
13
|
import {
|
|
14
14
|
sessionScopeFilter,
|
|
15
15
|
strictSessionScopeFilter
|
|
16
|
-
} from "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
16
|
+
} from "./chunk-ZXSFUR77.js";
|
|
17
|
+
import "./chunk-RBRGSOK5.js";
|
|
18
|
+
import "./chunk-OBWIVRD6.js";
|
|
19
|
+
import "./chunk-A42356G7.js";
|
|
20
20
|
import "./chunk-E23LNUWJ.js";
|
|
21
21
|
import "./chunk-4JERP7NT.js";
|
|
22
22
|
import "./chunk-EIKATSE4.js";
|
|
23
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-HYZE3MNS.js";
|
|
24
24
|
import "./chunk-AD2VCHSS.js";
|
|
25
25
|
import "./chunk-WOYADZF5.js";
|
|
26
26
|
import "./chunk-SKGMF2SO.js";
|
|
27
|
-
import "./chunk-
|
|
27
|
+
import "./chunk-AMC2OPYP.js";
|
|
28
28
|
import "./chunk-AJIXH5JF.js";
|
|
29
|
-
import "./chunk-
|
|
29
|
+
import "./chunk-A3YHWWE6.js";
|
|
30
30
|
import "./chunk-AM7S2TY6.js";
|
|
31
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-RFRUDXOI.js";
|
|
32
32
|
import "./chunk-OSKWCKUC.js";
|
|
33
33
|
import "./chunk-KI5PFRG6.js";
|
|
34
34
|
import "./chunk-CVYC6DUW.js";
|
|
@@ -44,17 +44,18 @@ import "./chunk-GJV3WDWM.js";
|
|
|
44
44
|
import "./chunk-MP2AFCGL.js";
|
|
45
45
|
import {
|
|
46
46
|
getClient
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-QNKR7WEL.js";
|
|
48
48
|
import "./chunk-2I23RPSI.js";
|
|
49
|
-
import "./chunk-
|
|
49
|
+
import "./chunk-FE6WBI2M.js";
|
|
50
50
|
import "./chunk-OMXJMOBD.js";
|
|
51
51
|
import "./chunk-7HLWBYH7.js";
|
|
52
52
|
import "./chunk-BBMTVAE3.js";
|
|
53
|
+
import "./chunk-YMUZWC33.js";
|
|
53
54
|
import "./chunk-FXU7JOXK.js";
|
|
54
55
|
import "./chunk-QWVXN224.js";
|
|
55
56
|
import "./chunk-WNBZJSQT.js";
|
|
56
|
-
import "./chunk-
|
|
57
|
-
import "./chunk-
|
|
57
|
+
import "./chunk-MMOONM6D.js";
|
|
58
|
+
import "./chunk-XF2D4CDA.js";
|
|
58
59
|
import "./chunk-BCZF3AGJ.js";
|
|
59
60
|
import "./chunk-HSGBZSCA.js";
|
|
60
61
|
import "./chunk-MLKGABMK.js";
|
|
@@ -163,7 +164,7 @@ ${msgLines}`);
|
|
|
163
164
|
} catch {
|
|
164
165
|
}
|
|
165
166
|
try {
|
|
166
|
-
const { getPendingProspective, markSurfaced } = await import("./prospective-memory-
|
|
167
|
+
const { getPendingProspective, markSurfaced } = await import("./prospective-memory-V7LFCPU4.js");
|
|
167
168
|
const due = await getPendingProspective(agentId, { projectName, limit: 5 });
|
|
168
169
|
if (due.length > 0) {
|
|
169
170
|
const now = Date.now();
|
|
@@ -119,7 +119,7 @@ function releaseBackfillLock() {
|
|
|
119
119
|
}
|
|
120
120
|
async function getTaskAwareCapacity() {
|
|
121
121
|
const { getClient } = await import("./lib/database.js");
|
|
122
|
-
const { sessionScopeFilter } = await import("./task-scope-
|
|
122
|
+
const { sessionScopeFilter } = await import("./task-scope-PSVAE3EM.js");
|
|
123
123
|
const client = getClient();
|
|
124
124
|
const scope = sessionScopeFilter();
|
|
125
125
|
const result = await client.execute({
|
|
@@ -263,7 +263,7 @@ async function runRegistryProxy(options = registryProxyOptionsFromEnv()) {
|
|
|
263
263
|
await new Promise((resolve) => server.listen(options.port, options.host, resolve));
|
|
264
264
|
console.log(`exe-registry-proxy listening on ${options.host ?? "0.0.0.0"}:${options.port}`);
|
|
265
265
|
console.log(`proxying /v2/${options.allowedNamespace ?? "askexe"}/* -> ${options.upstream ?? "https://ghcr.io"}`);
|
|
266
|
-
const { licenseSyncConfigFromEnv, startLicenseSyncScheduler } = await import("./license-sync-
|
|
266
|
+
const { licenseSyncConfigFromEnv, startLicenseSyncScheduler } = await import("./license-sync-CQHBDUQE.js");
|
|
267
267
|
const syncConfig = licenseSyncConfigFromEnv();
|
|
268
268
|
if (syncConfig) {
|
|
269
269
|
startLicenseSyncScheduler(syncConfig);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
loadLicense
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-MMOONM6D.js";
|
|
4
4
|
|
|
5
5
|
// src/lib/stack-update.ts
|
|
6
6
|
import { execFileSync, spawnSync } from "child_process";
|
|
@@ -299,6 +299,8 @@ async function rollbackStackUpdate(options) {
|
|
|
299
299
|
} catch {
|
|
300
300
|
}
|
|
301
301
|
const backupComposeFile = lockData?.backupComposeFile;
|
|
302
|
+
const backupComposeOverrideFile = lockData?.backupComposeOverrideFile;
|
|
303
|
+
const composeOverrideFile = composeOverrideFileFor(options.composeFile);
|
|
302
304
|
if (!options.serviceName) {
|
|
303
305
|
try {
|
|
304
306
|
if (existsSync(options.composeFile)) {
|
|
@@ -307,27 +309,41 @@ async function rollbackStackUpdate(options) {
|
|
|
307
309
|
} catch {
|
|
308
310
|
}
|
|
309
311
|
if (backupComposeFile && existsSync(backupComposeFile)) {
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
);
|
|
312
|
+
copyFileSync(backupComposeFile, options.composeFile);
|
|
313
|
+
console.log(`[stack-update] Restored docker-compose.yml from ${backupComposeFile}`);
|
|
313
314
|
} else {
|
|
314
315
|
console.log("[stack-update] No backed-up docker-compose.yml in lock \u2014 rolling back image tags via .env on the current compose.");
|
|
315
316
|
}
|
|
317
|
+
try {
|
|
318
|
+
if (backupComposeOverrideFile && existsSync(backupComposeOverrideFile)) {
|
|
319
|
+
copyFileSync(backupComposeOverrideFile, composeOverrideFile);
|
|
320
|
+
console.log(`[stack-update] Restored docker-compose.override.yml from ${backupComposeOverrideFile}`);
|
|
321
|
+
} else if (lockData?.hadComposeOverrideFile === false && existsSync(composeOverrideFile)) {
|
|
322
|
+
rmSync(composeOverrideFile, { force: true });
|
|
323
|
+
console.log("[stack-update] Removed docker-compose.override.yml because it was absent from the pre-update snapshot.");
|
|
324
|
+
}
|
|
325
|
+
} catch (overrideErr) {
|
|
326
|
+
const reason = overrideErr instanceof Error ? overrideErr.message : String(overrideErr);
|
|
327
|
+
console.warn(`[stack-update] Could not restore docker-compose.override.yml (${reason}); continuing rollback.`);
|
|
328
|
+
}
|
|
316
329
|
}
|
|
317
330
|
const scopedServiceNames = options.serviceName ? Object.entries(lockData?.services ?? {}).filter(([name, service]) => name === options.serviceName || (service.composeService ?? name) === options.serviceName).map(([name]) => name) : [];
|
|
318
331
|
const rollbackEnvRaw = readFileSync(rollbackEnv, "utf8");
|
|
319
332
|
if (scopedServiceNames.length > 0 && lockData?.services) {
|
|
320
333
|
const rollbackEnvMap = parseEnv(rollbackEnvRaw);
|
|
334
|
+
const scopedEnvKeys = scopedServiceNames.map((serviceName) => lockData.services[serviceName].env).filter((key) => Boolean(key));
|
|
335
|
+
const mutatedEnvKeys = lockData.mutatedEnvKeys ?? [];
|
|
336
|
+
const restoreEnvKeys = [.../* @__PURE__ */ new Set([...scopedEnvKeys, ...mutatedEnvKeys])];
|
|
321
337
|
const scopedUpdates = Object.fromEntries(
|
|
322
|
-
|
|
338
|
+
restoreEnvKeys.map((key) => [key, rollbackEnvMap.get(key) ?? ""])
|
|
323
339
|
);
|
|
324
|
-
console.log(`[stack-update] Restoring env keys for service ${scopedServiceNames.join(", ")} from ${rollbackEnv}`);
|
|
340
|
+
console.log(`[stack-update] Restoring env keys for service ${scopedServiceNames.join(", ")} from ${rollbackEnv}: ${restoreEnvKeys.join(", ")}`);
|
|
325
341
|
writeSecretFile(options.envFile, patchEnv(readFileSync(options.envFile, "utf8"), scopedUpdates));
|
|
326
342
|
} else {
|
|
327
343
|
console.log(`[stack-update] Restoring env from ${rollbackEnv}`);
|
|
328
344
|
writeSecretFile(options.envFile, rollbackEnvRaw);
|
|
329
345
|
}
|
|
330
|
-
const composeArgs =
|
|
346
|
+
const composeArgs = composeArgsForStack(options.composeFile, options.envFile);
|
|
331
347
|
if (lockData?.services) {
|
|
332
348
|
for (const [serviceName, service] of Object.entries(lockData.services)) {
|
|
333
349
|
if (scopedServiceNames.length > 0 && !scopedServiceNames.includes(serviceName)) continue;
|
|
@@ -440,6 +456,22 @@ function manifestImagesForPull(release) {
|
|
|
440
456
|
Object.values(release.services).map((service) => imagePullRef(service.image.trim())).filter(Boolean)
|
|
441
457
|
));
|
|
442
458
|
}
|
|
459
|
+
var COMPOSE_SIDECARS = {
|
|
460
|
+
// exe-crm-worker uses the same CRM_IMAGE_TAG as exe-crm but is a distinct
|
|
461
|
+
// compose service. Pull/restart it whenever the CRM API image changes so the
|
|
462
|
+
// API and worker cannot drift to different versions. (bug 9e324fd2)
|
|
463
|
+
"exe-crm": ["exe-crm-worker"],
|
|
464
|
+
"exe-erp": ["exe-erp-nginx", "exe-erp-websocket", "exe-erp-queue", "exe-erp-scheduler"]
|
|
465
|
+
};
|
|
466
|
+
function expandComposeServicesWithSidecars(primaryComposeServices) {
|
|
467
|
+
const expanded = [...primaryComposeServices];
|
|
468
|
+
for (const primary of primaryComposeServices) {
|
|
469
|
+
for (const sidecar of COMPOSE_SIDECARS[primary] ?? []) {
|
|
470
|
+
if (!expanded.includes(sidecar)) expanded.push(sidecar);
|
|
471
|
+
}
|
|
472
|
+
}
|
|
473
|
+
return expanded;
|
|
474
|
+
}
|
|
443
475
|
function cloneReleaseWithServices(release, serviceNames) {
|
|
444
476
|
const wanted = new Set(serviceNames);
|
|
445
477
|
const services = {};
|
|
@@ -463,6 +495,18 @@ function readStackUpdateLock(lockFile) {
|
|
|
463
495
|
function writeStackUpdateLock(lockFile, data) {
|
|
464
496
|
writeFileSync(lockFile, JSON.stringify(data, null, 2) + "\n");
|
|
465
497
|
}
|
|
498
|
+
function composeOverrideFileFor(composeFile) {
|
|
499
|
+
return path.join(path.dirname(composeFile), "docker-compose.override.yml");
|
|
500
|
+
}
|
|
501
|
+
function composeArgsForStack(composeFile, envFile, includeOverride = true) {
|
|
502
|
+
const args = ["compose", "--file", composeFile];
|
|
503
|
+
const overrideFile = composeOverrideFileFor(composeFile);
|
|
504
|
+
if (includeOverride && existsSync(overrideFile)) {
|
|
505
|
+
args.push("--file", overrideFile);
|
|
506
|
+
}
|
|
507
|
+
args.push("--env-file", envFile);
|
|
508
|
+
return args;
|
|
509
|
+
}
|
|
466
510
|
function buildInitialServiceStatus(plan, envRaw, now, activeServices) {
|
|
467
511
|
const env = parseEnv(envRaw);
|
|
468
512
|
const at = now().toISOString();
|
|
@@ -1017,6 +1061,8 @@ async function resolveStackImageCredentials(options, release) {
|
|
|
1017
1061
|
async function verifyManifestImagesAvailable(plan, options) {
|
|
1018
1062
|
const exec = options.exec ?? defaultExec;
|
|
1019
1063
|
const images = manifestImagesForPull(plan.release);
|
|
1064
|
+
const maxAttempts = Math.max(1, Math.floor(options.verifyImageMaxAttempts ?? 3));
|
|
1065
|
+
const baseDelayMs = Math.max(0, Math.floor(options.verifyImageRetryBaseDelayMs ?? 1e3));
|
|
1020
1066
|
let registryForLogout;
|
|
1021
1067
|
const creds = await resolveStackImageCredentials(options, plan.release);
|
|
1022
1068
|
if (creds) {
|
|
@@ -1024,15 +1070,29 @@ async function verifyManifestImagesAvailable(plan, options) {
|
|
|
1024
1070
|
registryForLogout = creds.registry;
|
|
1025
1071
|
}
|
|
1026
1072
|
try {
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1073
|
+
const results = [];
|
|
1074
|
+
for (const image of images) {
|
|
1075
|
+
let lastError = "";
|
|
1076
|
+
let ok = false;
|
|
1077
|
+
for (let attempt = 1; attempt <= maxAttempts; attempt++) {
|
|
1078
|
+
try {
|
|
1079
|
+
exec("docker", ["manifest", "inspect", image]);
|
|
1080
|
+
ok = true;
|
|
1081
|
+
break;
|
|
1082
|
+
} catch (err) {
|
|
1083
|
+
lastError = err instanceof Error ? err.message : String(err);
|
|
1084
|
+
if (attempt < maxAttempts) {
|
|
1085
|
+
const delayMs = baseDelayMs * Math.pow(2, attempt - 1);
|
|
1086
|
+
console.warn(
|
|
1087
|
+
`[stack-update] manifest inspect failed for ${image} (attempt ${attempt}/${maxAttempts}): ${lastError}. Retrying in ${delayMs}ms.`
|
|
1088
|
+
);
|
|
1089
|
+
if (delayMs > 0) await new Promise((resolve) => setTimeout(resolve, delayMs));
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1034
1092
|
}
|
|
1035
|
-
|
|
1093
|
+
results.push(ok ? { image, ok: true } : { image, ok: false, error: `manifest inspect failed after ${maxAttempts} attempt(s): ${lastError}` });
|
|
1094
|
+
}
|
|
1095
|
+
return results;
|
|
1036
1096
|
} finally {
|
|
1037
1097
|
if (registryForLogout) {
|
|
1038
1098
|
try {
|
|
@@ -1058,6 +1118,17 @@ function allServiceList(release) {
|
|
|
1058
1118
|
function errorMessage(err) {
|
|
1059
1119
|
return err instanceof Error ? err.message : String(err);
|
|
1060
1120
|
}
|
|
1121
|
+
function packagedComposeTemplatePath(options) {
|
|
1122
|
+
return options.composeTemplateFileForUpdate ?? path.join(resolvePackageRoot(), "deploy", "compose", "docker-compose.yml");
|
|
1123
|
+
}
|
|
1124
|
+
function readStagedComposeTemplate(options, currentComposeRaw) {
|
|
1125
|
+
const templatePath = packagedComposeTemplatePath(options);
|
|
1126
|
+
if (!existsSync(templatePath)) {
|
|
1127
|
+
return { raw: currentComposeRaw, templatePath, templateFound: false, shouldRefresh: false };
|
|
1128
|
+
}
|
|
1129
|
+
const raw = readFileSync(templatePath, "utf8");
|
|
1130
|
+
return { raw, templatePath, templateFound: true, shouldRefresh: raw !== currentComposeRaw };
|
|
1131
|
+
}
|
|
1061
1132
|
async function assertPreDeployImagesPullable(plan, options) {
|
|
1062
1133
|
let results;
|
|
1063
1134
|
try {
|
|
@@ -1238,6 +1309,18 @@ function backupStackConfig(stackDir, composeFile, envRaw, now = () => /* @__PURE
|
|
|
1238
1309
|
} catch {
|
|
1239
1310
|
backupComposeFile = void 0;
|
|
1240
1311
|
}
|
|
1312
|
+
const composeOverrideFile = composeOverrideFileFor(composeFile);
|
|
1313
|
+
const hadComposeOverrideFile = existsSync(composeOverrideFile);
|
|
1314
|
+
let backupComposeOverrideFile;
|
|
1315
|
+
try {
|
|
1316
|
+
if (hadComposeOverrideFile) {
|
|
1317
|
+
backupComposeOverrideFile = path.join(updateBackupDir, "docker-compose.override.yml.bak");
|
|
1318
|
+
copyFileSync(composeOverrideFile, backupComposeOverrideFile);
|
|
1319
|
+
copyFileSync(composeOverrideFile, path.join(updateBackupDir, "docker-compose.override.yml"));
|
|
1320
|
+
}
|
|
1321
|
+
} catch {
|
|
1322
|
+
backupComposeOverrideFile = void 0;
|
|
1323
|
+
}
|
|
1241
1324
|
for (const f of [...PROTECTED_CONFIG_FILES, ...BOOTSTRAP_OVERWRITTEN_CONFIG_FILES]) {
|
|
1242
1325
|
const src = path.join(stackDir, f);
|
|
1243
1326
|
try {
|
|
@@ -1271,7 +1354,7 @@ function backupStackConfig(stackDir, composeFile, envRaw, now = () => /* @__PURE
|
|
|
1271
1354
|
} catch {
|
|
1272
1355
|
}
|
|
1273
1356
|
console.log(`[stack-update] Config backed up to ${updateBackupDir}`);
|
|
1274
|
-
return { updateBackupDir, backupEnvFile, backupComposeFile };
|
|
1357
|
+
return { updateBackupDir, backupEnvFile, backupComposeFile, backupComposeOverrideFile, hadComposeOverrideFile };
|
|
1275
1358
|
}
|
|
1276
1359
|
function installDockerUbuntu(exec) {
|
|
1277
1360
|
if (process.platform !== "linux") throw new Error("Docker auto-install is only supported on Linux. Install Docker manually, then retry.");
|
|
@@ -1643,7 +1726,7 @@ function hardenSsh(exec, result) {
|
|
|
1643
1726
|
}
|
|
1644
1727
|
function areStackContainersRunning(composeFile, envFile) {
|
|
1645
1728
|
try {
|
|
1646
|
-
const result = spawnSync("docker", [
|
|
1729
|
+
const result = spawnSync("docker", [...composeArgsForStack(composeFile, envFile), "ps", "-q"], {
|
|
1647
1730
|
stdio: ["pipe", "pipe", "pipe"],
|
|
1648
1731
|
timeout: 15e3
|
|
1649
1732
|
});
|
|
@@ -1854,6 +1937,7 @@ async function runStackUpdate(options) {
|
|
|
1854
1937
|
const scopedServiceNames = options.serviceName ? [options.serviceName] : resumeServices;
|
|
1855
1938
|
const effectiveTargetVersion = options.targetVersion ?? resumeLock?.stackVersion;
|
|
1856
1939
|
const composeRaw = readFileSync(options.composeFile, "utf8");
|
|
1940
|
+
const stagedCompose = readStagedComposeTemplate(options, composeRaw);
|
|
1857
1941
|
const plan = createStackUpdatePlan(manifest, envRaw, effectiveTargetVersion, scopedServiceNames, serviceSelection, composeRaw);
|
|
1858
1942
|
const fullTargetPlan = scopedServiceNames.length > 0 ? createStackUpdatePlan(manifest, envRaw, effectiveTargetVersion, void 0, serviceSelection, composeRaw) : plan;
|
|
1859
1943
|
assertRolloutStageAllowed(plan, {
|
|
@@ -1862,7 +1946,20 @@ async function runStackUpdate(options) {
|
|
|
1862
1946
|
});
|
|
1863
1947
|
assertBreakingChangesAllowed(plan, options.allowedBreakingChangeIds ?? []);
|
|
1864
1948
|
assertDeploymentScopeAllowed(plan, options.deploymentPersona ?? "customer");
|
|
1865
|
-
const
|
|
1949
|
+
const requiredEnvValidation = options.dryRun ? { derived: {}, unresolvable: [] } : detectMissingRequiredEnvVars(stagedCompose.raw, envRaw);
|
|
1950
|
+
const migratedEnvVars = requiredEnvValidation.derived;
|
|
1951
|
+
if (requiredEnvValidation.unresolvable.length > 0) {
|
|
1952
|
+
const lines = requiredEnvValidation.unresolvable.map((r) => ` - ${r.key}${r.message ? ` (${r.message})` : ""}`);
|
|
1953
|
+
throw new Error(
|
|
1954
|
+
`Stack update aborted before any changes: the updated compose template requires env vars that are missing from ${options.envFile} and cannot be derived automatically.
|
|
1955
|
+
Set these in ${options.envFile}, then re-run stack-update:
|
|
1956
|
+
${lines.join("\n")}`
|
|
1957
|
+
);
|
|
1958
|
+
}
|
|
1959
|
+
const plannedEnvRaw = patchEnv(envRaw, {
|
|
1960
|
+
...migratedEnvVars,
|
|
1961
|
+
...Object.fromEntries(plan.changes.map((c) => [c.key, c.after]))
|
|
1962
|
+
});
|
|
1866
1963
|
assertProductionDeployGate(plan, plannedEnvRaw, composeRaw, {
|
|
1867
1964
|
breakGlassReason: options.breakGlassReason,
|
|
1868
1965
|
breakGlassAuditFile: options.breakGlassAuditFile,
|
|
@@ -1907,13 +2004,13 @@ async function runStackUpdate(options) {
|
|
|
1907
2004
|
const updateBackupDir = configBackup.updateBackupDir;
|
|
1908
2005
|
const backupEnvFile = configBackup.backupEnvFile;
|
|
1909
2006
|
const backupComposeFile = configBackup.backupComposeFile;
|
|
2007
|
+
const backupComposeOverrideFile = configBackup.backupComposeOverrideFile;
|
|
2008
|
+
const hadComposeOverrideFile = configBackup.hadComposeOverrideFile;
|
|
1910
2009
|
try {
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
const templateRaw = readFileSync(templateCompose, "utf8");
|
|
1914
|
-
if (templateRaw !== composeRaw) {
|
|
2010
|
+
if (stagedCompose.templateFound) {
|
|
2011
|
+
if (stagedCompose.shouldRefresh) {
|
|
1915
2012
|
const tmpCompose = `${options.composeFile}.tmp-${process.pid}`;
|
|
1916
|
-
writeFileSync(tmpCompose,
|
|
2013
|
+
writeFileSync(tmpCompose, stagedCompose.raw, { mode: 420 });
|
|
1917
2014
|
renameSync(tmpCompose, options.composeFile);
|
|
1918
2015
|
console.log(
|
|
1919
2016
|
`[stack-update] Refreshed docker-compose.yml from packaged template (old saved to ${path.join(updateBackupDir, "docker-compose.yml")}). Customer overrides should live in docker-compose.override.yml.`
|
|
@@ -1921,44 +2018,19 @@ async function runStackUpdate(options) {
|
|
|
1921
2018
|
}
|
|
1922
2019
|
} else {
|
|
1923
2020
|
console.warn(
|
|
1924
|
-
`[stack-update] Packaged compose template not found at ${
|
|
2021
|
+
`[stack-update] Packaged compose template not found at ${stagedCompose.templatePath}; keeping existing docker-compose.yml. Shipped compose fixes will not apply.`
|
|
1925
2022
|
);
|
|
1926
2023
|
}
|
|
1927
2024
|
} catch (err) {
|
|
1928
2025
|
const reason = err instanceof Error ? err.message : String(err);
|
|
1929
2026
|
console.warn(`[stack-update] Could not refresh docker-compose.yml (${reason}); using existing compose.`);
|
|
1930
2027
|
}
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
if (unresolvable.length > 0) {
|
|
1936
|
-
const lines = unresolvable.map((r) => ` - ${r.key}${r.message ? ` (${r.message})` : ""}`);
|
|
1937
|
-
throw new Error(
|
|
1938
|
-
`Stack update aborted before any changes: the updated compose template requires env vars that are missing from ${options.envFile} and cannot be derived automatically.
|
|
1939
|
-
Set these in ${options.envFile}, then re-run stack-update:
|
|
1940
|
-
${lines.join("\n")}`
|
|
1941
|
-
);
|
|
1942
|
-
}
|
|
1943
|
-
migratedEnvVars = derived;
|
|
1944
|
-
if (Object.keys(derived).length > 0) {
|
|
1945
|
-
console.log(
|
|
1946
|
-
`[stack-update] Migrating ${Object.keys(derived).length} newly-required env var(s) into ${options.envFile} with derived defaults: ${Object.keys(derived).join(", ")}`
|
|
1947
|
-
);
|
|
1948
|
-
}
|
|
1949
|
-
} catch (err) {
|
|
1950
|
-
throw err instanceof Error ? err : new Error(String(err));
|
|
2028
|
+
if (Object.keys(migratedEnvVars).length > 0) {
|
|
2029
|
+
console.log(
|
|
2030
|
+
`[stack-update] Migrating ${Object.keys(migratedEnvVars).length} newly-required env var(s) into ${options.envFile} with derived defaults: ${Object.keys(migratedEnvVars).join(", ")}`
|
|
2031
|
+
);
|
|
1951
2032
|
}
|
|
1952
2033
|
const initialServiceStatus = options.resume && resumeLock?.serviceStatus ? resumeLock.serviceStatus : buildInitialServiceStatus(fullTargetPlan, envRaw, now, new Set(Object.keys(plan.release.services)));
|
|
1953
|
-
writeStackUpdateLock(lockFile, {
|
|
1954
|
-
stackVersion: plan.targetVersion,
|
|
1955
|
-
previousVersion,
|
|
1956
|
-
updatedAt: now().toISOString(),
|
|
1957
|
-
backupEnvFile: resumeLock?.backupEnvFile ?? backupEnvFile,
|
|
1958
|
-
backupComposeFile: resumeLock?.backupComposeFile ?? backupComposeFile,
|
|
1959
|
-
services: { ...fullTargetPlan.release.services, ...resumeLock?.services ?? {}, ...plan.release.services },
|
|
1960
|
-
serviceStatus: initialServiceStatus
|
|
1961
|
-
});
|
|
1962
2034
|
try {
|
|
1963
2035
|
const { spawnSync: sp } = await import("child_process");
|
|
1964
2036
|
const backupSh = path.join(stackDir, "backup.sh");
|
|
@@ -2003,6 +2075,19 @@ ${lines.join("\n")}`
|
|
|
2003
2075
|
if (overrideResolution.warn) console.warn(overrideResolution.notice);
|
|
2004
2076
|
else console.log(overrideResolution.notice);
|
|
2005
2077
|
}
|
|
2078
|
+
const mutatedEnvKeys = Object.keys(updates);
|
|
2079
|
+
writeStackUpdateLock(lockFile, {
|
|
2080
|
+
stackVersion: plan.targetVersion,
|
|
2081
|
+
previousVersion,
|
|
2082
|
+
updatedAt: now().toISOString(),
|
|
2083
|
+
backupEnvFile: resumeLock?.backupEnvFile ?? backupEnvFile,
|
|
2084
|
+
backupComposeFile: resumeLock?.backupComposeFile ?? backupComposeFile,
|
|
2085
|
+
backupComposeOverrideFile: resumeLock?.backupComposeOverrideFile ?? backupComposeOverrideFile,
|
|
2086
|
+
hadComposeOverrideFile: resumeLock?.hadComposeOverrideFile ?? hadComposeOverrideFile,
|
|
2087
|
+
mutatedEnvKeys: [.../* @__PURE__ */ new Set([...resumeLock?.mutatedEnvKeys ?? [], ...mutatedEnvKeys])],
|
|
2088
|
+
services: { ...fullTargetPlan.release.services, ...resumeLock?.services ?? {}, ...plan.release.services },
|
|
2089
|
+
serviceStatus: initialServiceStatus
|
|
2090
|
+
});
|
|
2006
2091
|
const patched = patchEnv(envRaw, updates);
|
|
2007
2092
|
const tmp = `${options.envFile}.tmp-${process.pid}`;
|
|
2008
2093
|
writeSecretFile(tmp, patched);
|
|
@@ -2010,7 +2095,7 @@ ${lines.join("\n")}`
|
|
|
2010
2095
|
for (const serviceName of Object.keys(plan.release.services)) {
|
|
2011
2096
|
updateServiceStatus(lockFile, serviceName, "env_patched", now);
|
|
2012
2097
|
}
|
|
2013
|
-
const composeArgs =
|
|
2098
|
+
const composeArgs = composeArgsForStack(options.composeFile, options.envFile);
|
|
2014
2099
|
let registryForLogout;
|
|
2015
2100
|
try {
|
|
2016
2101
|
let credsLogged = false;
|
|
@@ -2102,7 +2187,9 @@ Push the missing image(s) to the registry, or re-run with --break-glass <reason>
|
|
|
2102
2187
|
);
|
|
2103
2188
|
}
|
|
2104
2189
|
}
|
|
2105
|
-
const composePullTargets =
|
|
2190
|
+
const composePullTargets = expandComposeServicesWithSidecars(
|
|
2191
|
+
Object.entries(plan.release.services).map(([name, svc]) => svc.composeService ?? name)
|
|
2192
|
+
);
|
|
2106
2193
|
try {
|
|
2107
2194
|
if (composePullTargets.length > 0) {
|
|
2108
2195
|
exec("docker", [...composeArgs, "pull", ...composePullTargets]);
|
|
@@ -2214,16 +2301,8 @@ Push the missing image(s) to the registry, or re-run with --break-glass <reason>
|
|
|
2214
2301
|
"cloudflared"
|
|
2215
2302
|
// tunnel — restarted last so services are healthy before it connects
|
|
2216
2303
|
];
|
|
2217
|
-
const COMPOSE_SIDECARS = {
|
|
2218
|
-
"exe-erp": ["exe-erp-nginx", "exe-erp-websocket", "exe-erp-queue", "exe-erp-scheduler"]
|
|
2219
|
-
};
|
|
2220
2304
|
const primaryComposeServices = Object.entries(plan.release.services).map(([serviceName, service]) => service.composeService ?? serviceName);
|
|
2221
|
-
const scopedComposeServices =
|
|
2222
|
-
for (const primary of primaryComposeServices) {
|
|
2223
|
-
for (const sidecar of COMPOSE_SIDECARS[primary] ?? []) {
|
|
2224
|
-
if (!scopedComposeServices.includes(sidecar)) scopedComposeServices.push(sidecar);
|
|
2225
|
-
}
|
|
2226
|
-
}
|
|
2305
|
+
const scopedComposeServices = expandComposeServicesWithSidecars(primaryComposeServices);
|
|
2227
2306
|
const restartOrder = [
|
|
2228
2307
|
...RESTART_ORDER.filter((service) => scopedComposeServices.includes(service)),
|
|
2229
2308
|
...scopedComposeServices.filter((service) => !RESTART_ORDER.includes(service))
|
|
@@ -2389,7 +2468,18 @@ Fix these before the stack is safe to operate.`);
|
|
|
2389
2468
|
progress.logOverallSummary();
|
|
2390
2469
|
printPhaseSummary();
|
|
2391
2470
|
const finalLock = readStackUpdateLock(lockFile) ?? {};
|
|
2392
|
-
writeStackUpdateLock(lockFile, {
|
|
2471
|
+
writeStackUpdateLock(lockFile, {
|
|
2472
|
+
...finalLock,
|
|
2473
|
+
stackVersion: plan.targetVersion,
|
|
2474
|
+
previousVersion,
|
|
2475
|
+
updatedAt: now().toISOString(),
|
|
2476
|
+
backupEnvFile: finalLock.backupEnvFile ?? backupEnvFile,
|
|
2477
|
+
backupComposeFile: finalLock.backupComposeFile ?? backupComposeFile,
|
|
2478
|
+
backupComposeOverrideFile: finalLock.backupComposeOverrideFile ?? backupComposeOverrideFile,
|
|
2479
|
+
hadComposeOverrideFile: finalLock.hadComposeOverrideFile ?? hadComposeOverrideFile,
|
|
2480
|
+
mutatedEnvKeys: finalLock.mutatedEnvKeys ?? mutatedEnvKeys,
|
|
2481
|
+
services: { ...fullTargetPlan.release.services, ...finalLock.services ?? {}, ...plan.release.services }
|
|
2482
|
+
});
|
|
2393
2483
|
await postDeployAudit(options, "success", plan.targetVersion, previousVersion, void 0, { changes: plan.changes.length });
|
|
2394
2484
|
return { status: "updated", targetVersion: plan.targetVersion, changes: plan.changes, backupEnvFile, lockFile, serviceStatus: readStackUpdateLock(lockFile)?.serviceStatus };
|
|
2395
2485
|
} catch (err) {
|
|
@@ -2926,6 +3016,8 @@ export {
|
|
|
2926
3016
|
buildReleaseMigrationArgs,
|
|
2927
3017
|
runReleaseMigrations,
|
|
2928
3018
|
isExecFormMigration,
|
|
3019
|
+
expandComposeServicesWithSidecars,
|
|
3020
|
+
composeArgsForStack,
|
|
2929
3021
|
parseStackManifest,
|
|
2930
3022
|
loadStackManifest,
|
|
2931
3023
|
parseEnv,
|