@outerlayer/cli 0.34.0-next.20261025133402 → 0.34.0-next.20261025180645

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.
Files changed (123) hide show
  1. package/dist/{agent-setup-UXUWLV7O.js → agent-setup-FNDKCPUP.js} +8 -9
  2. package/dist/{bridge-OWCSVCXL.js → bridge-YJBB4YA3.js} +2 -3
  3. package/dist/build-B4OKU4MV.js +16 -0
  4. package/dist/{build-disk-5ZQHYBO3.js → build-disk-ZL46AEN3.js} +6 -8
  5. package/dist/build-info.json +1 -1
  6. package/dist/{builder-54GLXGFV.js → builder-XFPWE74N.js} +5 -7
  7. package/dist/{check-4TQZZOIQ.js → check-QULEN437.js} +43 -43
  8. package/dist/{chunk-CXQCBAKO.js → chunk-25GRRBTH.js} +1 -1
  9. package/dist/{chunk-4XYC2663.js → chunk-2D6CKNR7.js} +8 -4
  10. package/dist/{chunk-IHY457PB.js → chunk-2ILU7UAU.js} +1 -1
  11. package/dist/{chunk-JEOPIRUR.js → chunk-3EJBI5JW.js} +3 -3
  12. package/dist/{chunk-TVGLNHEB.js → chunk-3N77LUQI.js} +1 -1
  13. package/dist/{chunk-ES4ULBAL.js → chunk-4UPET3R7.js} +7 -3
  14. package/dist/{chunk-MPDLZCXM.js → chunk-5AFPP3GZ.js} +238 -14
  15. package/dist/{chunk-HAEDLXHA.js → chunk-63IVRRIO.js} +3 -3
  16. package/dist/{chunk-BTG5NZHN.js → chunk-6OLVVAOK.js} +4 -4
  17. package/dist/{chunk-3M6UYJSR.js → chunk-AVPLEFQR.js} +3 -3
  18. package/dist/{chunk-TVOZOOIW.js → chunk-BHSSGVOY.js} +3 -3
  19. package/dist/{chunk-QOUR4CQ7.js → chunk-CAQCDYKF.js} +2 -2
  20. package/dist/{chunk-SMMNU65K.js → chunk-DNZYXEMY.js} +13 -12
  21. package/dist/{chunk-LMICI7AY.js → chunk-EGVHFHY4.js} +3 -3
  22. package/dist/{chunk-RNVBSRZZ.js → chunk-FD5ASWTG.js} +18 -19
  23. package/dist/{chunk-NW5PDZYA.js → chunk-FDJPDZSR.js} +1 -1
  24. package/dist/{chunk-XA6PGME5.js → chunk-FVCHHSHB.js} +3 -3
  25. package/dist/{chunk-YOBQIXX6.js → chunk-G4W4B33M.js} +182 -3
  26. package/dist/{chunk-CCISO7EQ.js → chunk-HHFZXOBC.js} +12 -14
  27. package/dist/{chunk-AABYHGVO.js → chunk-INOUUSYI.js} +29 -9
  28. package/dist/{chunk-KDLQGTN6.js → chunk-JBCOUY4M.js} +2 -2
  29. package/dist/{chunk-POGPX7LI.js → chunk-JQSZTQSK.js} +24 -30
  30. package/dist/{chunk-JZD2NTRH.js → chunk-K2UAQWYO.js} +3 -3
  31. package/dist/{chunk-UC2DKBMS.js → chunk-KM2HLQE3.js} +2 -2
  32. package/dist/{chunk-T7N3BAOO.js → chunk-LUHIN4UZ.js} +3 -3
  33. package/dist/{chunk-XLJLR7EK.js → chunk-MOI2KDLH.js} +1 -1
  34. package/dist/{chunk-BUF6DSSM.js → chunk-NW26E4YU.js} +3 -3
  35. package/dist/{chunk-ZV2JJPDS.js → chunk-O4Z2MNNL.js} +6 -6
  36. package/dist/{chunk-2RBIW2PD.js → chunk-OGPEHSNW.js} +1 -1
  37. package/dist/{chunk-EZ7L5IZU.js → chunk-OQLF3MQQ.js} +3 -4
  38. package/dist/{chunk-J246WRLZ.js → chunk-OS7DJOQJ.js} +1 -1
  39. package/dist/{chunk-O5G6VQGZ.js → chunk-PFHTT4PP.js} +5 -5
  40. package/dist/{chunk-N7LAEN3T.js → chunk-PXGU3GKY.js} +1 -1
  41. package/dist/{chunk-WIK5KUGK.js → chunk-QANM5COC.js} +6 -6
  42. package/dist/{chunk-PSXVAOEB.js → chunk-QQP3S5FU.js} +3 -3
  43. package/dist/{chunk-AVLLJW5D.js → chunk-RFVIQLNB.js} +5 -5
  44. package/dist/{chunk-Z76GVJGQ.js → chunk-RHV5SRI2.js} +3 -3
  45. package/dist/{chunk-75KZUBHD.js → chunk-SI6WDF3U.js} +1 -1
  46. package/dist/chunk-SUOZYOWO.js +51 -0
  47. package/dist/{chunk-36T6W5RA.js → chunk-SYVRBBLW.js} +1 -1
  48. package/dist/{chunk-E34FRRSW.js → chunk-TBKV4L2W.js} +4 -4
  49. package/dist/{chunk-56ZHWIR2.js → chunk-TFPNPS4Q.js} +1 -1
  50. package/dist/{chunk-DUPM5LVJ.js → chunk-UMYYYF7B.js} +1 -1
  51. package/dist/{chunk-IW6Z337K.js → chunk-UN3SQTVL.js} +7 -7
  52. package/dist/{chunk-3NFZN7H6.js → chunk-UO4FQAOX.js} +16 -12
  53. package/dist/{chunk-ZWLEUSJW.js → chunk-VJ34F55N.js} +55 -39
  54. package/dist/{chunk-3RAAYBSG.js → chunk-YHKU2NOZ.js} +1 -1
  55. package/dist/{chunk-ENFBYN4A.js → chunk-YNMVVQOQ.js} +1 -1
  56. package/dist/{claude-launcher-JEB5BN7Q.js → claude-launcher-OQZNW7XJ.js} +1 -1
  57. package/dist/{cli-DY3EGPUB.js → cli-G3P2B2XE.js} +123 -117
  58. package/dist/{command-ZAXYAZCI.js → command-4XOXVWFW.js} +169 -48
  59. package/dist/{config-UN3X6AP2.js → config-QASNKYM6.js} +7 -9
  60. package/dist/{connect-cmd-TWM4FEKD.js → connect-cmd-MEDWMW3L.js} +8 -9
  61. package/dist/{container-start-JUNBJ7MU.js → container-start-2DHCWV73.js} +34 -36
  62. package/dist/{context-show-cmd-K5LRMDEO.js → context-show-cmd-VSFCG663.js} +9 -10
  63. package/dist/{control-plane-launch-LHOV2FPA.js → control-plane-launch-XBGHM7DB.js} +5 -6
  64. package/dist/{docker-YZKRM7IP.js → docker-TAC6G4VU.js} +5 -7
  65. package/dist/{doctor-YOAF7QPL.js → doctor-LK6E3XOW.js} +66 -41
  66. package/dist/{emit-artifact-cmd-SCF2FKKS.js → emit-artifact-cmd-L4REOPWX.js} +13 -14
  67. package/dist/{emit-cmd-7NMNKDK7.js → emit-cmd-7TU3JBJ2.js} +2 -2
  68. package/dist/{emit-criteria-cmd-B6CKUWTW.js → emit-criteria-cmd-QVFOQARC.js} +10 -11
  69. package/dist/{emit-demo-cmd-BNWRETMJ.js → emit-demo-cmd-L4B6OOTV.js} +15 -16
  70. package/dist/{emit-finding-cmd-TPSHNZNE.js → emit-finding-cmd-YXFCIWMU.js} +10 -11
  71. package/dist/{emit-result-cmd-J5DXIC2Q.js → emit-result-cmd-NI4LCTUM.js} +12 -13
  72. package/dist/{emit-step-cmd-NPH46KAO.js → emit-step-cmd-HWAUCZZB.js} +10 -11
  73. package/dist/{exec-client-ANW4KGMN.js → exec-client-QB4OZRGM.js} +3 -4
  74. package/dist/find-unit-4UR647S4.js +18 -0
  75. package/dist/{findings-cmd-4FJDCFL3.js → findings-cmd-O2IBO25E.js} +10 -11
  76. package/dist/{fleet-readiness-OK6534T6.js → fleet-readiness-NJYTQYTA.js} +5 -6
  77. package/dist/{governing-source-GNKTNM32.js → governing-source-JCI7VDQ6.js} +12 -13
  78. package/dist/{guest-init-C6M7YT3U.js → guest-init-IF5LXGUL.js} +4 -5
  79. package/dist/{hook-fast-LVTJWAG3.js → hook-fast-GPUL7T77.js} +1 -1
  80. package/dist/host-key-5RU322O3.js +9 -0
  81. package/dist/{image-tag-53DJPMSZ.js → image-tag-SEMBVB5D.js} +3 -4
  82. package/dist/index.js +4 -4
  83. package/dist/{init-RAJKTSPJ.js → init-2CEULE3F.js} +25 -27
  84. package/dist/{init-JGYMAOD5.js → init-FAIF7KOK.js} +25 -27
  85. package/dist/{init-cmd-IB3KTYCV.js → init-cmd-HZUUMO45.js} +13 -14
  86. package/dist/{init-update-VPWSWDY7.js → init-update-TTMFFNMB.js} +12 -13
  87. package/dist/{install-cmd-NP7GULCD.js → install-cmd-TWGRGEVL.js} +5 -6
  88. package/dist/{logs-V6AES5FE.js → logs-6CMB3DO6.js} +2 -3
  89. package/dist/{loop-ZGDZMVFN.js → loop-7U7MVICV.js} +40 -42
  90. package/dist/{machine-LJ3VMGS3.js → machine-S3JHOX4V.js} +25 -27
  91. package/dist/{mcp-serve-cmd-DHGCAMJS.js → mcp-serve-cmd-MWGIN6YL.js} +4 -5
  92. package/dist/{paths-DMKAJVA5.js → paths-T2DEBI62.js} +2 -3
  93. package/dist/pending-ERXWVLLG.js +9 -0
  94. package/dist/{pidfile-XCTXBGA3.js → pidfile-EAD2OEM7.js} +3 -4
  95. package/dist/{record-RQLGRYWG.js → record-IMXQNHPB.js} +3 -4
  96. package/dist/{runner-env-AUG2OIP4.js → runner-env-BJPUHAKZ.js} +9 -11
  97. package/dist/{runner-identity-BQA4SBU6.js → runner-identity-ZCPPC2BJ.js} +5 -7
  98. package/dist/{runner-key-ZIF7M7YN.js → runner-key-CYSUYKSX.js} +25 -27
  99. package/dist/{session-sender-VQ4LHJ5K.js → session-sender-5T7BXPKC.js} +13 -14
  100. package/dist/{spec-cmd-PXM4FJ2O.js → spec-cmd-4ABYAFNZ.js} +11 -12
  101. package/dist/{status-27EFD2WE.js → status-2AP7J2L7.js} +32 -34
  102. package/dist/{sync-cmd-VAV7TR2A.js → sync-cmd-34CGNA6T.js} +12 -13
  103. package/dist/{update-steps-7YLAFW3E.js → update-steps-JQOCCDWO.js} +33 -35
  104. package/dist/{watch-42XJSTTB.js → watch-6HU7LCUY.js} +12 -13
  105. package/dist/{work-claim-cmd-HSG4OHFI.js → work-claim-cmd-5QKLHSCR.js} +16 -18
  106. package/dist/{work-cmd-KCBU3RSD.js → work-cmd-3MKUIE2C.js} +10 -11
  107. package/dist/{work-comment-cmd-QIP2OUJC.js → work-comment-cmd-ESC3DSHI.js} +11 -12
  108. package/dist/{work-demo-cmd-6IKAG6ES.js → work-demo-cmd-7S23DGYO.js} +10 -11
  109. package/dist/{work-logs-cmd-RMKJA4AI.js → work-logs-cmd-46UPNN7Q.js} +10 -11
  110. package/dist/{work-open-pr-cmd-IAVLUUWW.js → work-open-pr-cmd-JNGTGLIP.js} +11 -12
  111. package/dist/{work-pr-cmd-3U7SVQII.js → work-pr-cmd-2J2LKETD.js} +10 -11
  112. package/dist/{work-proofs-cmd-6ZY6ZNNE.js → work-proofs-cmd-HRWTHYSS.js} +11 -12
  113. package/dist/{work-proofs-record-54GBEUJP.js → work-proofs-record-6OKAT3IC.js} +18 -19
  114. package/dist/{work-stop-cmd-LH5XY4YL.js → work-stop-cmd-Y22XIVQ6.js} +10 -11
  115. package/package.json +1 -1
  116. package/dist/build-4HFDZTUX.js +0 -14
  117. package/dist/chunk-3Z3MPR55.js +0 -226
  118. package/dist/chunk-HACGUL52.js +0 -183
  119. package/dist/host-key-DUGGHAGR.js +0 -10
  120. package/dist/inspect-DNLXTXLA.js +0 -6
  121. package/dist/install-QJWJFIWB.js +0 -19
  122. package/dist/pending-B55JZFOV.js +0 -10
  123. package/dist/{chunk-2AIOOU3A.js → chunk-KPHRRCUY.js} +1 -1
@@ -1,18 +1,16 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { keepHandWritten, runAgentSetup } from './chunk-JEOPIRUR.js';
4
- import './chunk-2AIOOU3A.js';
3
+ export { keepHandWritten, runAgentSetup } from './chunk-3EJBI5JW.js';
4
+ import './chunk-KPHRRCUY.js';
5
5
  import './chunk-KT4CN6OU.js';
6
6
  import './chunk-4P6QGMPN.js';
7
- import './chunk-NKOM4JKY.js';
8
7
  import './chunk-ANPNT6PM.js';
9
- import './chunk-QOUR4CQ7.js';
8
+ import './chunk-NKOM4JKY.js';
9
+ import './chunk-CAQCDYKF.js';
10
10
  import './chunk-JWNH4ZTF.js';
11
- import './chunk-TVGLNHEB.js';
11
+ import './chunk-3N77LUQI.js';
12
12
  import './chunk-PJDQPF5N.js';
13
- import './chunk-XLJLR7EK.js';
14
- import './chunk-N7LAEN3T.js';
15
- import './chunk-YOBQIXX6.js';
13
+ import './chunk-MOI2KDLH.js';
16
14
  import './chunk-ZJSNLVCE.js';
17
15
  import './chunk-BJ3KTMDH.js';
18
16
  import './chunk-ZQSANKS4.js';
@@ -26,7 +24,8 @@ import './chunk-TUSYOL2O.js';
26
24
  import './chunk-FGXT5OXS.js';
27
25
  import './chunk-EOTMDIYC.js';
28
26
  import './chunk-VNVZDWO3.js';
29
- import './chunk-HACGUL52.js';
27
+ import './chunk-PXGU3GKY.js';
28
+ import './chunk-G4W4B33M.js';
30
29
  import './chunk-MESOOLF4.js';
31
30
  import './chunk-Z5GEFMRW.js';
32
31
 
@@ -1,8 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { BRIDGE_ADDRESS, BRIDGE_CIDR, CONTAINER_NO_PROXY, CONTAINER_PROXY, TUNNEL_PORT, dockerClientConfig, startBridgeForward, writeDockerClientConfig } from './chunk-75KZUBHD.js';
4
- import './chunk-YOBQIXX6.js';
5
- import './chunk-HACGUL52.js';
3
+ export { BRIDGE_ADDRESS, BRIDGE_CIDR, CONTAINER_NO_PROXY, CONTAINER_PROXY, TUNNEL_PORT, dockerClientConfig, startBridgeForward, writeDockerClientConfig } from './chunk-SI6WDF3U.js';
4
+ import './chunk-G4W4B33M.js';
6
5
  import './chunk-MESOOLF4.js';
7
6
  import './chunk-Z5GEFMRW.js';
8
7
 
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire } from 'node:module';
3
+ export { KEY_PREFIX, TAG_HOST, buildRepositoryImage, metadataFromLabels, prepareImageBuild, writeRecord } from './chunk-UO4FQAOX.js';
4
+ export { RecipeError } from './chunk-5AFPP3GZ.js';
5
+ import './chunk-4UPET3R7.js';
6
+ import './chunk-YNMVVQOQ.js';
7
+ import './chunk-JBJTC3UU.js';
8
+ import './chunk-MOI2KDLH.js';
9
+ import './chunk-AJYZNISW.js';
10
+ import './chunk-EOTMDIYC.js';
11
+ import './chunk-PXGU3GKY.js';
12
+ import './chunk-G4W4B33M.js';
13
+ import './chunk-MESOOLF4.js';
14
+ import './chunk-Z5GEFMRW.js';
15
+
16
+ createRequire(import.meta.url);
@@ -1,15 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { DEFAULT_BUILD_DISK, DEFAULT_CACHE_DISK, DOCKER_CACHE_MS, allocatedBytes, checkDiskFit, realBuildDiskProbe, runDocker, volumeBytes } from './chunk-UC2DKBMS.js';
4
- import './chunk-MPDLZCXM.js';
5
- import './chunk-3Z3MPR55.js';
6
- import './chunk-ES4ULBAL.js';
3
+ export { DEFAULT_BUILD_DISK, DEFAULT_CACHE_DISK, DOCKER_CACHE_MS, allocatedBytes, checkDiskFit, realBuildDiskProbe, runDocker, volumeBytes } from './chunk-KM2HLQE3.js';
4
+ import './chunk-5AFPP3GZ.js';
5
+ import './chunk-4UPET3R7.js';
6
+ import './chunk-MOI2KDLH.js';
7
7
  import './chunk-AJYZNISW.js';
8
- import './chunk-XLJLR7EK.js';
9
- import './chunk-N7LAEN3T.js';
10
- import './chunk-YOBQIXX6.js';
11
8
  import './chunk-EOTMDIYC.js';
12
- import './chunk-HACGUL52.js';
9
+ import './chunk-PXGU3GKY.js';
10
+ import './chunk-G4W4B33M.js';
13
11
  import './chunk-MESOOLF4.js';
14
12
  import './chunk-Z5GEFMRW.js';
15
13
 
@@ -1 +1 @@
1
- {"id":"2026-10-25T13:35:18.143Z+b97ae23","root":"/home/runner/_work/outerlayer/outerlayer","pkg":"outerlayer"}
1
+ {"id":"2026-10-25T18:08:18.697Z+424fcf9","root":"/home/runner/_work/outerlayer/outerlayer","pkg":"outerlayer"}
@@ -1,14 +1,12 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- export { MIN_BUILDX_VERSION, builderName, builderSpec, buildxState, ensureBuilder, ensureFailureCount, isOutOfMemory, proxyEnvironment, trackImageBuild } from './chunk-MPDLZCXM.js';
4
- import './chunk-3Z3MPR55.js';
5
- import './chunk-ES4ULBAL.js';
3
+ export { MIN_BUILDX_VERSION, builderName, builderSpec, buildxState, ensureBuilder, ensureFailureCount, isOutOfMemory, proxyEnvironment, trackImageBuild } from './chunk-5AFPP3GZ.js';
4
+ import './chunk-4UPET3R7.js';
5
+ import './chunk-MOI2KDLH.js';
6
6
  import './chunk-AJYZNISW.js';
7
- import './chunk-XLJLR7EK.js';
8
- import './chunk-N7LAEN3T.js';
9
- import './chunk-YOBQIXX6.js';
10
7
  import './chunk-EOTMDIYC.js';
11
- import './chunk-HACGUL52.js';
8
+ import './chunk-PXGU3GKY.js';
9
+ import './chunk-G4W4B33M.js';
12
10
  import './chunk-MESOOLF4.js';
13
11
  import './chunk-Z5GEFMRW.js';
14
12
 
@@ -1,61 +1,58 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { probeCredentials } from './chunk-ZWLEUSJW.js';
3
+ import { probeCredentials } from './chunk-VJ34F55N.js';
4
+ import './chunk-O4Z2MNNL.js';
5
+ import './chunk-TFPNPS4Q.js';
6
+ import './chunk-RHV5SRI2.js';
7
+ import './chunk-FD5ASWTG.js';
8
+ import './chunk-ZVB57WI6.js';
9
+ import './chunk-FDJPDZSR.js';
4
10
  import './chunk-3JVYMD4G.js';
5
- import './chunk-ZV2JJPDS.js';
6
11
  import './chunk-E7R2GIAW.js';
7
- import './chunk-56ZHWIR2.js';
8
- import './chunk-Z76GVJGQ.js';
9
- import './chunk-RNVBSRZZ.js';
10
- import './chunk-ZVB57WI6.js';
11
- import './chunk-NW5PDZYA.js';
12
12
  import './chunk-PAK5P2ND.js';
13
- import './chunk-HAEDLXHA.js';
14
- import './chunk-75KZUBHD.js';
13
+ import './chunk-63IVRRIO.js';
15
14
  import './chunk-I3LTIAOR.js';
16
- import './chunk-KDLQGTN6.js';
17
- import './chunk-WIK5KUGK.js';
18
- import './chunk-LMICI7AY.js';
15
+ import './chunk-JBCOUY4M.js';
16
+ import './chunk-QANM5COC.js';
17
+ import './chunk-EGVHFHY4.js';
19
18
  import './chunk-ESVW4MJY.js';
20
- import { managedProblems, managedFactsOf } from './chunk-SMMNU65K.js';
21
- import './chunk-DUPM5LVJ.js';
19
+ import './chunk-SI6WDF3U.js';
20
+ import { managedProblems, managedFactsOf } from './chunk-DNZYXEMY.js';
21
+ import './chunk-UMYYYF7B.js';
22
22
  import './chunk-TBT347UY.js';
23
- import { placeholderQueues, placeholderProblem, permissionModeProblems, permissionModeProblem, probeHelper, HELPER_ENV, helperSocketPath, needsClaudeCredential, claudeCredentialCheck, claimPermissionProblem, formerSkillQueues, formerSkillProblem } from './chunk-POGPX7LI.js';
23
+ import { findServiceUnit } from './chunk-SUOZYOWO.js';
24
+ import { placeholderQueues, placeholderProblem, permissionModeProblems, permissionModeProblem, HELPER_ENV, helperSocketPath, probeHelper, needsClaudeCredential, claudeCredentialCheck, claimPermissionProblem, formerSkillQueues, formerSkillProblem } from './chunk-JQSZTQSK.js';
24
25
  import './chunk-2PGI6RDE.js';
25
- import './chunk-EZ7L5IZU.js';
26
- import './chunk-3NFZN7H6.js';
27
- import './chunk-ENFBYN4A.js';
28
- import './chunk-JBJTC3UU.js';
26
+ import './chunk-UO4FQAOX.js';
29
27
  import './chunk-OGFGZQA3.js';
30
- import './chunk-IHY457PB.js';
31
- import './chunk-2RBIW2PD.js';
32
- import './chunk-AVLLJW5D.js';
33
- import './chunk-36T6W5RA.js';
28
+ import './chunk-2ILU7UAU.js';
29
+ import './chunk-OGPEHSNW.js';
30
+ import './chunk-RFVIQLNB.js';
31
+ import './chunk-SYVRBBLW.js';
34
32
  import './chunk-TQMI335S.js';
35
- import { DEFAULT_UNIT_NAME } from './chunk-AABYHGVO.js';
36
- import { loadRunnerConfig, RunnerConfigError, checkHooks } from './chunk-4XYC2663.js';
37
- import './chunk-UC2DKBMS.js';
38
- import './chunk-MPDLZCXM.js';
39
- import './chunk-3Z3MPR55.js';
40
- import './chunk-ES4ULBAL.js';
41
- import './chunk-IW6Z337K.js';
33
+ import './chunk-OQLF3MQQ.js';
34
+ import './chunk-INOUUSYI.js';
35
+ import { loadRunnerConfig, RunnerConfigError, checkHooks } from './chunk-2D6CKNR7.js';
36
+ import './chunk-KM2HLQE3.js';
37
+ import './chunk-5AFPP3GZ.js';
38
+ import './chunk-4UPET3R7.js';
39
+ import './chunk-YNMVVQOQ.js';
40
+ import './chunk-JBJTC3UU.js';
41
+ import './chunk-UN3SQTVL.js';
42
42
  import './chunk-IP7BIBXJ.js';
43
- import './chunk-3M6UYJSR.js';
44
- import './chunk-XA6PGME5.js';
45
- import './chunk-MECW77XP.js';
46
- import './chunk-AJYZNISW.js';
47
- import './chunk-NKOM4JKY.js';
43
+ import './chunk-AVPLEFQR.js';
44
+ import './chunk-FVCHHSHB.js';
48
45
  import './chunk-Y5YCX6AL.js';
49
46
  import './chunk-G2JWZDFA.js';
50
47
  import './chunk-ANPNT6PM.js';
51
- import './chunk-QOUR4CQ7.js';
48
+ import './chunk-MECW77XP.js';
49
+ import './chunk-NKOM4JKY.js';
50
+ import './chunk-CAQCDYKF.js';
52
51
  import './chunk-JWNH4ZTF.js';
53
- import './chunk-TVGLNHEB.js';
52
+ import './chunk-3N77LUQI.js';
54
53
  import './chunk-PJDQPF5N.js';
55
- import './chunk-XLJLR7EK.js';
56
- import './chunk-N7LAEN3T.js';
57
- import { claudeEnvPath } from './chunk-YOBQIXX6.js';
58
- import './chunk-CXQCBAKO.js';
54
+ import './chunk-MOI2KDLH.js';
55
+ import './chunk-25GRRBTH.js';
59
56
  import './chunk-ZJSNLVCE.js';
60
57
  import './chunk-2O5KA67H.js';
61
58
  import './chunk-BKO6JEZI.js';
@@ -63,6 +60,7 @@ import './chunk-FGF52V4V.js';
63
60
  import './chunk-HCVLP7XA.js';
64
61
  import './chunk-BJ3KTMDH.js';
65
62
  import './chunk-ZQSANKS4.js';
63
+ import './chunk-AJYZNISW.js';
66
64
  import './chunk-5BHIBJDA.js';
67
65
  import './chunk-CDDED64E.js';
68
66
  import './chunk-RA3O54FC.js';
@@ -75,7 +73,8 @@ import './chunk-TUSYOL2O.js';
75
73
  import './chunk-FGXT5OXS.js';
76
74
  import './chunk-EOTMDIYC.js';
77
75
  import './chunk-VNVZDWO3.js';
78
- import { parseRunnerEnv } from './chunk-HACGUL52.js';
76
+ import './chunk-PXGU3GKY.js';
77
+ import { claudeEnvPath, parseRunnerEnv } from './chunk-G4W4B33M.js';
79
78
  import './chunk-MESOOLF4.js';
80
79
  import './chunk-Z5GEFMRW.js';
81
80
  import { readFileSync } from 'fs';
@@ -116,7 +115,8 @@ async function runRunnerCheck(configPath, deps = {}) {
116
115
  Object.assign(env, fromFile.env);
117
116
  }
118
117
  Object.assign(env, deps.env ?? process.env);
119
- const asked = await (deps.helper ?? (() => probeHelper(env[HELPER_ENV] ?? helperSocketPath(DEFAULT_UNIT_NAME))))();
118
+ const socket = env[HELPER_ENV] ?? helperSocketPath(findServiceUnit(dirname(configPath), deps.units));
119
+ const asked = await (deps.helper ?? probeHelper)(socket);
120
120
  const unmet = managedProblems(managedFactsOf(config, { env, jailer: asked.ok ? "usable" : { problem: asked.detail } }))[0];
121
121
  if (unmet !== void 0) return { ok: false, check: "managed", message: `${configPath}: ${unmet.reason}` };
122
122
  }
@@ -684,7 +684,7 @@ async function missingControlPlane(cwd, sessionId, home, env) {
684
684
  cleanupEarlierCopies(dirs);
685
685
  }
686
686
  if (!contextPossiblyGoverned(cwd, home)) return void 0;
687
- const { governanceOf } = await import('./control-plane-launch-LHOV2FPA.js');
687
+ const { governanceOf } = await import('./control-plane-launch-XBGHM7DB.js');
688
688
  if (await governanceOf({ cwd, env, home }) !== "governed") return void 0;
689
689
  recordMissingContext(dirs, sessionId, home);
690
690
  const launcher = `${cliInvocation()} claude`;
@@ -1,9 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { DEFAULT_CACHE_DISK, DEFAULT_BUILD_DISK } from './chunk-UC2DKBMS.js';
4
- import { parseSize } from './chunk-MPDLZCXM.js';
5
- import { isRefusedInConfig, resolveDestinations, isReservedVariable } from './chunk-YOBQIXX6.js';
3
+ import { DEFAULT_CACHE_DISK, DEFAULT_BUILD_DISK } from './chunk-KM2HLQE3.js';
4
+ import { parseSize } from './chunk-5AFPP3GZ.js';
5
+ import { builderDiskPinned } from './chunk-4UPET3R7.js';
6
6
  import { homeFromEnv } from './chunk-VNVZDWO3.js';
7
+ import { isRefusedInConfig, resolveDestinations, isReservedVariable } from './chunk-G4W4B33M.js';
7
8
  import { existsSync, statSync, accessSync, constants, readFileSync } from 'fs';
8
9
  import { hostname } from 'os';
9
10
  import { join } from 'path';
@@ -78,6 +79,9 @@ function imageBuildOf(config) {
78
79
  if (builtinKind(config.hooks.provision) !== "vm") return "host";
79
80
  return config.build?.imageBuild ?? "vm";
80
81
  }
82
+ function keepsHostBuilder(config, builderDiskIsPinned) {
83
+ return !(imageBuildOf(config) === "vm" && (builderDiskIsPinned ?? builderDiskPinned()));
84
+ }
81
85
  var BUILD_KEYS = ["memory", "cpus", "pids", "disk", "cacheDisk", "variables", "destinations", "allowHosts", "imageBuild"];
82
86
  var HOUSEKEEPING_KEYS = ["jobsKeepDays", "buildCacheMax", "minFreeDisk"];
83
87
  var DEFAULT_JOBS_KEEP_DAYS = 30;
@@ -455,4 +459,4 @@ function resolveBuild(configPath, block) {
455
459
  };
456
460
  }
457
461
 
458
- export { DEFAULT_CHECK_TIME_LIMIT_MINUTES, DEFAULT_UPDATE_MAX_WAIT_HOURS, MAX_ALLOW_HOSTS, RunnerConfigError, allowHostProblem, builtinKind, checkHooks, defaultRunnerConfigPath, hasRunnerBlock, hostAllowed, imageBuildOf, isBuiltinContainer, isBuiltinProcess, isBuiltinVm, loadRunnerConfig, resolveBuild, resolveHousekeeping, runnerCredentialProblem, runnerVmOf };
462
+ export { DEFAULT_CHECK_TIME_LIMIT_MINUTES, DEFAULT_UPDATE_MAX_WAIT_HOURS, MAX_ALLOW_HOSTS, RunnerConfigError, allowHostProblem, builtinKind, checkHooks, defaultRunnerConfigPath, hasRunnerBlock, hostAllowed, imageBuildOf, isBuiltinContainer, isBuiltinProcess, isBuiltinVm, keepsHostBuilder, loadRunnerConfig, resolveBuild, resolveHousekeeping, runnerCredentialProblem, runnerVmOf };
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { EXEC_PORT } from './chunk-2RBIW2PD.js';
3
+ import { EXEC_PORT } from './chunk-OGPEHSNW.js';
4
4
  import { createConnection } from 'net';
5
5
 
6
6
  createRequire(import.meta.url);
@@ -1,11 +1,11 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { runEmit } from './chunk-2AIOOU3A.js';
3
+ import { runEmit } from './chunk-KPHRRCUY.js';
4
4
  import { addStdioMcpEntryIfAbsent, addDocsMcpEntryIfAbsent, DOCS_MCP_SERVER_NAME } from './chunk-KT4CN6OU.js';
5
5
  import { installStarterPack } from './chunk-4P6QGMPN.js';
6
- import { AGENTS_MD_LAYOUT, declareAgentsMdLayout, linkClaudeSkills, SKILLS_LINK_PATH, describeSkillsLink, isAgentsMdLayout, holdsTodaysLayoutSources, discoverOuterlayerPaths } from './chunk-NKOM4JKY.js';
7
6
  import { C } from './chunk-ANPNT6PM.js';
8
- import { resolveGitCommonDir, defaultGitRunner } from './chunk-QOUR4CQ7.js';
7
+ import { AGENTS_MD_LAYOUT, declareAgentsMdLayout, linkClaudeSkills, SKILLS_LINK_PATH, describeSkillsLink, isAgentsMdLayout, holdsTodaysLayoutSources, discoverOuterlayerPaths } from './chunk-NKOM4JKY.js';
8
+ import { resolveGitCommonDir, defaultGitRunner } from './chunk-CAQCDYKF.js';
9
9
  import { loadTemplateFiles, loadMaintainedFiles, skillDir, AGENTS_SKILLS_BASE } from './chunk-ZQSANKS4.js';
10
10
  import { cliInvocation } from './chunk-CRB3POP4.js';
11
11
  import { linkedAgentsPath } from './chunk-DQ6YO7FH.js';
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
3
  import { readCloudConfigStrict, readCloudConfig, cloudConfigPath } from './chunk-PJDQPF5N.js';
4
- import { signRunnerRequest, signerFor } from './chunk-XLJLR7EK.js';
4
+ import { signRunnerRequest, signerFor } from './chunk-MOI2KDLH.js';
5
5
  import { readRepoConnection, findGitDirs } from './chunk-BJ3KTMDH.js';
6
6
  import { PLAIN_VERSION, recordCliVersion, removeRecordedVersion } from './chunk-5BHIBJDA.js';
7
7
  import { resolvePackageVersion } from './chunk-RA3O54FC.js';
@@ -44,11 +44,15 @@ function guestAssetsPinned(arch) {
44
44
  var JAILER_BINARY_SHA256 = {
45
45
  x86_64: "65ef226e96f0ceda55ba643f445801ef2cc0ea667ef67cad8ac4f406c9c8434f"
46
46
  };
47
- var HOST_HELPER_ASSETS_VERSION = "13";
47
+ var HOST_HELPER_ASSETS_VERSION = "15";
48
48
  var HOST_HELPER_BASE_URL = `https://github.com/outerlayerai/guest-assets/releases/download/guest-${HOST_HELPER_ASSETS_VERSION}`;
49
49
  var HOST_HELPER_SHA256 = {
50
- x86_64: "0d6cdbce1e5a5e084726b1d1b1cc0bc208f6662fe8d10a1d7a91e8573035505f"
50
+ x86_64: "710176334d514f5cf21871a96a7712646e88ed1d31dc95d835de9f0a817601c4"
51
51
  };
52
+ var HOST_HELPER_SLICE_SINCE = 15;
53
+ function hostHelperSupportsSlice(version = HOST_HELPER_ASSETS_VERSION) {
54
+ return Number(version) >= HOST_HELPER_SLICE_SINCE;
55
+ }
52
56
  function hostHelperPinned(arch = "x86_64", hashes = HOST_HELPER_SHA256) {
53
57
  return hashes[arch] !== "0".repeat(64);
54
58
  }
@@ -105,4 +109,4 @@ var FFMPEG_STATIC = {
105
109
  var MEDIA_PINS = `${VOICE_PACK_VERSION}+${FFMPEG_BUILD_TAG}`;
106
110
  var PLAYWRIGHT_VERSION = "1.64.1";
107
111
 
108
- export { BUILDER_DISK_BASE_URL, BUILDER_DISK_SHA256, BUILDER_DISK_VERSION, BUILDKIT_IMAGE, CLAUDE_CODE_VERSION, DEFAULT_BASE_IMAGE, FFMPEG_BUILD_TAG, FFMPEG_STATIC, FIRECRACKER_BINARY_SHA256, FIRECRACKER_SHA256, FIRECRACKER_VERSION, GH_SHA256, GH_VERSION, GUEST_ASSETS_BASE_URL, GUEST_ASSETS_VERSION, GUEST_HELPER_SHA256, GUEST_KERNEL_SHA256, HOST_HELPER_ASSETS_VERSION, HOST_HELPER_BASE_URL, HOST_HELPER_SHA256, JAILER_BINARY_SHA256, MEDIA_PINS, MICROVM_ARCHES, NODE_IMAGE, PLAYWRIGHT_VERSION, TINI_SHA256, TINI_VERSION, VOICE_PACK_FILES, VOICE_PACK_VERSION, builderDiskPinned, firecrackerArch, guestAssetsPinned, hostHelperPinned };
112
+ export { BUILDER_DISK_BASE_URL, BUILDER_DISK_SHA256, BUILDER_DISK_VERSION, BUILDKIT_IMAGE, CLAUDE_CODE_VERSION, DEFAULT_BASE_IMAGE, FFMPEG_BUILD_TAG, FFMPEG_STATIC, FIRECRACKER_BINARY_SHA256, FIRECRACKER_SHA256, FIRECRACKER_VERSION, GH_SHA256, GH_VERSION, GUEST_ASSETS_BASE_URL, GUEST_ASSETS_VERSION, GUEST_HELPER_SHA256, GUEST_KERNEL_SHA256, HOST_HELPER_ASSETS_VERSION, HOST_HELPER_BASE_URL, HOST_HELPER_SHA256, HOST_HELPER_SLICE_SINCE, JAILER_BINARY_SHA256, MEDIA_PINS, MICROVM_ARCHES, NODE_IMAGE, PLAYWRIGHT_VERSION, TINI_SHA256, TINI_VERSION, VOICE_PACK_FILES, VOICE_PACK_VERSION, builderDiskPinned, firecrackerArch, guestAssetsPinned, hostHelperPinned, hostHelperSupportsSlice };
@@ -1,15 +1,14 @@
1
1
  #!/usr/bin/env node
2
2
  import { createRequire } from 'node:module';
3
- import { RecipeError } from './chunk-3Z3MPR55.js';
4
- import { BUILDKIT_IMAGE } from './chunk-ES4ULBAL.js';
3
+ import { BUILDKIT_IMAGE } from './chunk-4UPET3R7.js';
4
+ import { ensureHostKey } from './chunk-MOI2KDLH.js';
5
5
  import { compareVersions } from './chunk-AJYZNISW.js';
6
- import { ensureHostKey } from './chunk-XLJLR7EK.js';
7
- import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, runnerDir, jobsDir } from './chunk-N7LAEN3T.js';
8
- import { CLAUDE_PORT, JOB_MOUNT, GATEWAY_PORT, GATEWAY_SOCKET, CLAUDE_SOCKET, RELAY_PORT, DESTINATION_BASE_PORT } from './chunk-YOBQIXX6.js';
6
+ import { RUNNER_DIR_MODE, RUNNER_FILE_MODE, runnerDir, jobsDir } from './chunk-PXGU3GKY.js';
7
+ import { CLAUDE_PORT, JOB_MOUNT, GATEWAY_PORT, GATEWAY_SOCKET, CLAUDE_SOCKET, RELAY_PORT, DESTINATION_BASE_PORT } from './chunk-G4W4B33M.js';
9
8
  import { JOIN_DIR, RELAY_ID, JOIN_SOCKET, TARGET_GATEWAY, TARGET_CLAUDE, destinationTarget, RELAY_USER } from './chunk-MESOOLF4.js';
10
9
  import { createHash } from 'crypto';
11
- import { existsSync, mkdirSync, createWriteStream, rmSync, readFileSync, chmodSync, writeFileSync, realpathSync, readdirSync, renameSync } from 'fs';
12
- import { join, dirname, resolve } from 'path';
10
+ import { existsSync, readdirSync, readFileSync, lstatSync, realpathSync, writeFileSync, mkdirSync, createWriteStream, rmSync, chmodSync, renameSync } from 'fs';
11
+ import { join, resolve, relative, dirname, sep, basename } from 'path';
13
12
  import { StringDecoder } from 'string_decoder';
14
13
  import { spawn } from 'child_process';
15
14
  import { createRequire as createRequire$1 } from 'module';
@@ -48,6 +47,228 @@ function cut(line) {
48
47
  const last = head.charCodeAt(head.length - 1);
49
48
  return last >= 55296 && last <= 56319 ? head.slice(0, -1) : head;
50
49
  }
50
+
51
+ // src/runner/image/properties.ts
52
+ var LIFECYCLE = ["onCreateCommand", "updateContentCommand", "postCreateCommand", "postStartCommand"];
53
+ var HONOURED = ["image", "build", "features", "containerEnv", "remoteUser", ...LIFECYCLE];
54
+ var IGNORED_BUILD_KEYS = ["options"];
55
+ var HOST_REFERENCE = /\$\{(?:localEnv|env)[:}]/;
56
+ var DROP = /* @__PURE__ */ Symbol("drop");
57
+ function isHonoured(property) {
58
+ return HONOURED.includes(property);
59
+ }
60
+ function isObject(value) {
61
+ return typeof value === "object" && value !== null && !Array.isArray(value);
62
+ }
63
+ function featureName(id) {
64
+ const slash = id.lastIndexOf("/");
65
+ const cut2 = id.slice(slash + 1).search(/[:@]/);
66
+ return cut2 === -1 ? id : id.slice(0, slash + 1 + cut2);
67
+ }
68
+ var DOCKER_FEATURE = "ghcr.io/devcontainers/features/docker-in-docker";
69
+ function asksForDocker(recipe, metadata) {
70
+ const isDocker = (id) => featureName(id) === DOCKER_FEATURE;
71
+ if (isObject(recipe.features) && Object.keys(recipe.features).some(isDocker)) return true;
72
+ return metadata.some((entry) => typeof entry.id === "string" && isDocker(entry.id));
73
+ }
74
+ function sameValue(a, b) {
75
+ return JSON.stringify(a) === JSON.stringify(b);
76
+ }
77
+ function isFilesOwnEntry(entry, recipe) {
78
+ if (typeof entry.id === "string") return false;
79
+ const keys = Object.keys(entry);
80
+ return keys.length > 0 && keys.every((key) => key in recipe && sameValue(entry[key], recipe[key]));
81
+ }
82
+ function withoutHostReferences(value, path, dropped) {
83
+ if (typeof value === "string") {
84
+ if (!HOST_REFERENCE.test(value)) return value;
85
+ dropped.push(path);
86
+ return DROP;
87
+ }
88
+ if (Array.isArray(value)) {
89
+ if (!HOST_REFERENCE.test(JSON.stringify(value))) return value;
90
+ dropped.push(path);
91
+ return DROP;
92
+ }
93
+ if (isObject(value)) {
94
+ const kept = {};
95
+ for (const [key, item] of Object.entries(value)) {
96
+ if (HOST_REFERENCE.test(key)) {
97
+ dropped.push(`${path}.${key}`);
98
+ continue;
99
+ }
100
+ const clean = withoutHostReferences(item, `${path}.${key}`, dropped);
101
+ if (clean !== DROP) kept[key] = clean;
102
+ }
103
+ return kept;
104
+ }
105
+ return value;
106
+ }
107
+ function honouredWithoutHostReferences(entry) {
108
+ const kept = {};
109
+ const dropped = [];
110
+ for (const property of HONOURED) {
111
+ if (!(property in entry)) continue;
112
+ const value = entry[property];
113
+ const clean = withoutHostReferences(
114
+ property === "build" && isObject(value) ? withoutIgnoredBuildKeys(value) : value,
115
+ property,
116
+ dropped
117
+ );
118
+ if (clean !== DROP) kept[property] = clean;
119
+ }
120
+ return { kept, dropped };
121
+ }
122
+ function withoutIgnoredBuildKeys(build) {
123
+ return Object.fromEntries(Object.entries(build).filter(([key]) => !IGNORED_BUILD_KEYS.includes(key)));
124
+ }
125
+ function ignoredIn(entry, source) {
126
+ const found = [];
127
+ for (const property of Object.keys(entry)) {
128
+ if (property === "id" || property.startsWith("$") || isHonoured(property)) continue;
129
+ found.push({ property, source });
130
+ }
131
+ if (isObject(entry.build)) {
132
+ for (const key of IGNORED_BUILD_KEYS) {
133
+ if (key in entry.build) found.push({ property: `build.${key}`, source });
134
+ }
135
+ }
136
+ for (const property of honouredWithoutHostReferences(entry).dropped) found.push({ property, source });
137
+ return found;
138
+ }
139
+ function emptyApply() {
140
+ return { containerEnv: {}, lifecycle: { onCreateCommand: [], updateContentCommand: [], postCreateCommand: [], postStartCommand: [] } };
141
+ }
142
+ function applyEntry(apply, raw, source) {
143
+ const entry = honouredWithoutHostReferences(raw).kept;
144
+ if (typeof entry.remoteUser === "string") apply.remoteUser = entry.remoteUser;
145
+ if (isObject(entry.containerEnv)) {
146
+ for (const [key, value] of Object.entries(entry.containerEnv)) {
147
+ if (typeof value === "string") apply.containerEnv[key] = value;
148
+ }
149
+ }
150
+ for (const name of LIFECYCLE) {
151
+ if (entry[name] !== void 0) apply.lifecycle[name].push({ source, command: entry[name] });
152
+ }
153
+ }
154
+ function classifyProperties(recipe, metadata) {
155
+ const ignored = ignoredIn(recipe, "file");
156
+ const apply = emptyApply();
157
+ let fileApplied = false;
158
+ const sanitized = sanitizeRecipe(recipe);
159
+ for (const entry of metadata) {
160
+ if (isFilesOwnEntry(entry, sanitized)) {
161
+ applyEntry(apply, entry, "file");
162
+ fileApplied = true;
163
+ continue;
164
+ }
165
+ const source = typeof entry.id === "string" ? `feature ${featureName(entry.id)}` : "image label";
166
+ ignored.push(...ignoredIn(entry, source));
167
+ applyEntry(apply, entry, source);
168
+ }
169
+ if (!fileApplied) applyEntry(apply, recipe, "file");
170
+ return { docker: asksForDocker(recipe, metadata), honoured: HONOURED.filter((property) => property in recipe), ignored, apply };
171
+ }
172
+ function sanitizeRecipe(recipe) {
173
+ return honouredWithoutHostReferences(recipe).kept;
174
+ }
175
+
176
+ // src/runner/image/recipe.ts
177
+ var RecipeError = class extends Error {
178
+ constructor(code, message, logPath) {
179
+ super(message);
180
+ this.code = code;
181
+ this.logPath = logPath;
182
+ }
183
+ };
184
+ var DIR_RECIPE = ".devcontainer/devcontainer.json";
185
+ var ROOT_RECIPE = ".devcontainer.json";
186
+ function locateRecipe(checkoutDir) {
187
+ if (existsSync(join(checkoutDir, DIR_RECIPE))) return { kind: "file", path: DIR_RECIPE };
188
+ if (existsSync(join(checkoutDir, ROOT_RECIPE))) return { kind: "file", path: ROOT_RECIPE };
189
+ const named = namedConfigurations(checkoutDir);
190
+ if (named.length > 0) {
191
+ throw new RecipeError(
192
+ "recipe_ambiguous",
193
+ `the repository has only named devcontainer configurations (${named.join(", ")}); add ${DIR_RECIPE} so the runner knows which to build`
194
+ );
195
+ }
196
+ return { kind: "default" };
197
+ }
198
+ function namedConfigurations(checkoutDir) {
199
+ const dir = join(checkoutDir, ".devcontainer");
200
+ if (!existsSync(dir)) return [];
201
+ return readdirSync(dir).sort().map((entry) => `.devcontainer/${entry}/devcontainer.json`).filter((path) => existsSync(join(checkoutDir, path)));
202
+ }
203
+ var COMMENTS = /("(?:[^"\\]|\\.)*")|\/\/[^\n]*|\/\*[\s\S]*?(?:\*\/|$)/g;
204
+ var TRAILING_COMMAS = /("(?:[^"\\]|\\.)*")|,(\s*[}\]])/g;
205
+ function parseJsonc(text) {
206
+ const withoutComments = text.replace(COMMENTS, (_match, str) => str ?? "");
207
+ return JSON.parse(withoutComments.replace(TRAILING_COMMAS, (_match, str, close) => str ?? close ?? ""));
208
+ }
209
+ function readRecipe(checkoutDir, location) {
210
+ if (location.kind === "default") return {};
211
+ const parsed = parseJsonc(readFileSync(join(checkoutDir, location.path), "utf8"));
212
+ if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) {
213
+ throw new Error(`${location.path} is not a JSON object`);
214
+ }
215
+ return parsed;
216
+ }
217
+ function within(dir, path) {
218
+ const rel = relative(dir, path);
219
+ return rel !== ".." && !rel.startsWith(`..${sep}`);
220
+ }
221
+ function realish(path) {
222
+ let existing = path;
223
+ let rest = "";
224
+ while (!existsSync(existing)) {
225
+ rest = join(basename(existing), rest);
226
+ existing = dirname(existing);
227
+ }
228
+ return join(realpathSync(existing), rest);
229
+ }
230
+ function assertBuildable(checkoutDir, location, recipe) {
231
+ if (location.kind === "default") return;
232
+ const devcontainerDir = join(checkoutDir, ".devcontainer");
233
+ if (existsSync(devcontainerDir) && lstatSync(devcontainerDir).isSymbolicLink()) {
234
+ throw new RecipeError(
235
+ "recipe_context_outside",
236
+ ".devcontainer is a symbolic link, so the build could read files outside the repository; commit a real directory"
237
+ );
238
+ }
239
+ if (recipe.dockerComposeFile !== void 0) {
240
+ throw new RecipeError(
241
+ "recipe_needs_docker",
242
+ "the recipe uses dockerComposeFile; its services need Docker, which a container build does not have"
243
+ );
244
+ }
245
+ const build = recipe.build;
246
+ if (typeof build !== "object" || build === null) return;
247
+ const { dockerfile, context } = build;
248
+ const base = resolve(checkoutDir, location.path, "..");
249
+ const allowed = join(realpathSync(checkoutDir), ".devcontainer");
250
+ const contextPath = resolve(base, typeof context === "string" ? context : ".");
251
+ const paths = [contextPath];
252
+ if (typeof dockerfile === "string") paths.push(resolve(base, dockerfile));
253
+ for (const path of paths) {
254
+ if (!within(devcontainerDir, path) || !within(allowed, realish(path))) {
255
+ throw new RecipeError(
256
+ "recipe_context_outside",
257
+ `the recipe's build reads ${relative(checkoutDir, path) || "."}, outside .devcontainer/; move the build files into .devcontainer/`
258
+ );
259
+ }
260
+ }
261
+ }
262
+ function writeSanitizedRecipe(checkoutDir, location, recipe) {
263
+ if (location.kind === "default") throw new Error("the default image has no recipe to sanitize");
264
+ const path = location.path === ROOT_RECIPE ? join(checkoutDir, ".outerlayer-recipe.json") : join(checkoutDir, ".devcontainer", SANITIZED_NAME);
265
+ writeFileSync(path, `${JSON.stringify(sanitizeRecipe(recipe), null, 2)}
266
+ `);
267
+ return path;
268
+ }
269
+ var SANITIZED_NAME = "outerlayer-recipe.json";
270
+
271
+ // src/runner/image/devcontainer-cli.ts
51
272
  var PACKAGE = "@devcontainers/cli";
52
273
  function buildRootFromDist(moduleDir = dirname(fileURLToPath(import.meta.url))) {
53
274
  try {
@@ -58,9 +279,9 @@ function buildRootFromDist(moduleDir = dirname(fileURLToPath(import.meta.url)))
58
279
  }
59
280
  }
60
281
  function resolveDevcontainerCli(opts = {}) {
61
- const resolve2 = opts.resolve ?? createRequire$1(import.meta.url).resolve;
282
+ const resolve3 = opts.resolve ?? createRequire$1(import.meta.url).resolve;
62
283
  try {
63
- const bin = join(dirname(resolve2(`${PACKAGE}/package.json`)), "devcontainer.js");
284
+ const bin = join(dirname(resolve3(`${PACKAGE}/package.json`)), "devcontainer.js");
64
285
  if (existsSync(bin)) return { command: process.execPath, args: [bin] };
65
286
  } catch {
66
287
  }
@@ -133,7 +354,7 @@ function childEnvironment(base) {
133
354
  }
134
355
  return env;
135
356
  }
136
- var spawnRun = (command, args, opts = {}) => new Promise((resolve2) => {
357
+ var spawnRun = (command, args, opts = {}) => new Promise((resolve3) => {
137
358
  let log;
138
359
  if (opts.logPath !== void 0) {
139
360
  mkdirSync(dirname(opts.logPath), { recursive: true });
@@ -149,11 +370,11 @@ var spawnRun = (command, args, opts = {}) => new Promise((resolve2) => {
149
370
  settled = true;
150
371
  const result = { status, stdout: stdout + stdoutDecoder.end(), stderr: stderr + stderrDecoder.end() + extra };
151
372
  if (log === void 0) {
152
- resolve2(result);
373
+ resolve3(result);
153
374
  return;
154
375
  }
155
376
  if (extra) log.write(extra);
156
- log.end(() => resolve2(result));
377
+ log.end(() => resolve3(result));
157
378
  };
158
379
  let timer;
159
380
  const child = spawn(command, args, {
@@ -374,6 +595,9 @@ function readRunnerIdentity(configPath) {
374
595
  return void 0;
375
596
  }
376
597
  }
598
+ function identityDockerFor(runner) {
599
+ return runner.keepsHostBuilder ? void 0 : { holdsObjects: async () => false };
600
+ }
377
601
  function dockerIdentity(run = spawnRun) {
378
602
  return {
379
603
  async holdsObjects(label, builder) {
@@ -697,7 +921,7 @@ function ensureBuilder(rawRun, spec, options = {}) {
697
921
  const result = serialized(async () => {
698
922
  const state = await buildxState(run);
699
923
  if (state !== "usable") return { ok: false, problem: state.problem };
700
- const sleep = options.sleep ?? ((ms) => new Promise((resolve2) => setTimeout(resolve2, ms)));
924
+ const sleep = options.sleep ?? ((ms) => new Promise((resolve3) => setTimeout(resolve3, ms)));
701
925
  const inspected = await run("docker", ["buildx", "inspect", spec.name]);
702
926
  let create = inspected.status !== 0;
703
927
  if (!create) {
@@ -763,4 +987,4 @@ function ensureBuilder(rawRun, spec, options = {}) {
763
987
  );
764
988
  }
765
989
 
766
- export { BUILD_LABEL, COMMAND_DIR, HASH_ARGV, JUDGE_DIR, JUDGE_ITEMS, JUDGE_MAX_TURNS, JUDGE_PROGRAM, JUDGE_REPORT, MAX_ITEMS_BYTES, MAX_REPORT_BYTES, MIN_BUILDX_VERSION, RUNNER_LABEL, builderName, builderNameFor, builderSpec, buildxState, childEnvironment, containerExecArgs, containerRunArgs, createDockerHost, dockerIdentity, ensureBuilder, ensureFailureCount, ensureRunnerIdentity, exceedsDisk, isOutOfMemory, judgeCommand, parseProgramHash, parseSize, pathLabelValue, prepareRunArgs, proxyEnvironment, readDu, readJobFile, readJobFileChecked, readRunnerIdentity, resolveDevcontainerCli, runnerLabelValue, spawnRun, trackImageBuild, withAnswerProtocol, writeJobFile };
990
+ export { BUILD_LABEL, COMMAND_DIR, DOCKER_FEATURE, HASH_ARGV, JUDGE_DIR, JUDGE_ITEMS, JUDGE_MAX_TURNS, JUDGE_PROGRAM, JUDGE_REPORT, MAX_ITEMS_BYTES, MAX_REPORT_BYTES, MIN_BUILDX_VERSION, RUNNER_LABEL, RecipeError, SANITIZED_NAME, assertBuildable, builderName, builderNameFor, builderSpec, buildxState, childEnvironment, classifyProperties, containerExecArgs, containerRunArgs, createDockerHost, dockerIdentity, ensureBuilder, ensureFailureCount, ensureRunnerIdentity, exceedsDisk, identityDockerFor, isOutOfMemory, judgeCommand, locateRecipe, parseProgramHash, parseSize, pathLabelValue, prepareRunArgs, proxyEnvironment, readDu, readJobFile, readJobFileChecked, readRecipe, readRunnerIdentity, resolveDevcontainerCli, runnerLabelValue, spawnRun, trackImageBuild, withAnswerProtocol, writeJobFile, writeSanitizedRecipe };