@zitadel/cli 0.1.0-alpha.8 → 1.0.0-alpha.20
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/README.md +250 -62
- package/SKILLS.md +227 -38
- package/dist/branding-cygSBPkV.mjs +79 -0
- package/dist/branding-cygSBPkV.mjs.map +1 -0
- package/dist/claim-state-DlfD6Res.mjs +66 -0
- package/dist/claim-state-DlfD6Res.mjs.map +1 -0
- package/dist/commands/apply.mjs +27 -8
- package/dist/commands/apply.mjs.map +1 -1
- package/dist/commands/branding/eject.mjs +104 -0
- package/dist/commands/branding/eject.mjs.map +1 -0
- package/dist/commands/claim.mjs +402 -0
- package/dist/commands/claim.mjs.map +1 -0
- package/dist/commands/doctor.mjs +687 -55
- package/dist/commands/doctor.mjs.map +1 -1
- package/dist/commands/eject.mjs +18 -6
- package/dist/commands/eject.mjs.map +1 -1
- package/dist/commands/logs.mjs +2 -2
- package/dist/commands/plan.mjs +19 -6
- package/dist/commands/plan.mjs.map +1 -1
- package/dist/commands/reset.mjs +12 -4
- package/dist/commands/reset.mjs.map +1 -1
- package/dist/commands/schemas/list.mjs +146 -0
- package/dist/commands/schemas/list.mjs.map +1 -0
- package/dist/commands/setup.mjs +642 -287
- package/dist/commands/setup.mjs.map +1 -1
- package/dist/commands/start.mjs +73 -6
- package/dist/commands/start.mjs.map +1 -1
- package/dist/commands/status.mjs +52 -13
- package/dist/commands/status.mjs.map +1 -1
- package/dist/commands/stop.mjs +59 -6
- package/dist/commands/stop.mjs.map +1 -1
- package/dist/designs-Ckz18Dpo.mjs +38 -0
- package/dist/designs-Ckz18Dpo.mjs.map +1 -0
- package/dist/{docker-BA78SdC2.mjs → docker-DcRGTOJa.mjs} +61 -11
- package/dist/docker-DcRGTOJa.mjs.map +1 -0
- package/dist/environment-rjRVkJjW.mjs +17 -0
- package/dist/environment-rjRVkJjW.mjs.map +1 -0
- package/dist/journey-guidance-BGrOX_gT.mjs +40 -0
- package/dist/journey-guidance-BGrOX_gT.mjs.map +1 -0
- package/dist/oclif-CanO3zdt.mjs +1769 -0
- package/dist/oclif-CanO3zdt.mjs.map +1 -0
- package/dist/{orca-CfKDQRop.mjs → orca-BzQIQqzt.mjs} +1663 -303
- package/dist/orca-BzQIQqzt.mjs.map +1 -0
- package/dist/package-manager-DFdLcDx1.mjs +194 -0
- package/dist/package-manager-DFdLcDx1.mjs.map +1 -0
- package/dist/ports-BM20XIZb.mjs +116 -0
- package/dist/ports-BM20XIZb.mjs.map +1 -0
- package/dist/processes-DKHPkU8O.mjs +120 -0
- package/dist/processes-DKHPkU8O.mjs.map +1 -0
- package/dist/{project-CKAHtHML.mjs → project-CHhot85s.mjs} +57 -4
- package/dist/project-CHhot85s.mjs.map +1 -0
- package/dist/sync-BBlACKzT.mjs +1633 -0
- package/dist/sync-BBlACKzT.mjs.map +1 -0
- package/dist/user-schema-DTuOsdKE.mjs +91 -0
- package/dist/user-schema-DTuOsdKE.mjs.map +1 -0
- package/oclif.manifest.json +412 -5
- package/package.json +10 -5
- package/dist/docker-BA78SdC2.mjs.map +0 -1
- package/dist/docker-guidance-BvfpmsDj.mjs +0 -21
- package/dist/docker-guidance-BvfpmsDj.mjs.map +0 -1
- package/dist/oclif-VkCTGIEk.mjs +0 -818
- package/dist/oclif-VkCTGIEk.mjs.map +0 -1
- package/dist/orca-CfKDQRop.mjs.map +0 -1
- package/dist/project-CKAHtHML.mjs.map +0 -1
- package/dist/sync-B5lqgQO3.mjs +0 -733
- package/dist/sync-B5lqgQO3.mjs.map +0 -1
package/oclif.manifest.json
CHANGED
|
@@ -60,6 +60,12 @@
|
|
|
60
60
|
"allowNo": false,
|
|
61
61
|
"type": "boolean"
|
|
62
62
|
},
|
|
63
|
+
"telemetry": {
|
|
64
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
65
|
+
"name": "telemetry",
|
|
66
|
+
"allowNo": true,
|
|
67
|
+
"type": "boolean"
|
|
68
|
+
},
|
|
63
69
|
"environment": {
|
|
64
70
|
"char": "e",
|
|
65
71
|
"description": "Target environment (default: development).",
|
|
@@ -89,6 +95,106 @@
|
|
|
89
95
|
"apply.mjs"
|
|
90
96
|
]
|
|
91
97
|
},
|
|
98
|
+
"claim": {
|
|
99
|
+
"aliases": [],
|
|
100
|
+
"args": {},
|
|
101
|
+
"description": "Attach this project to a team so it becomes permanent. Opens a browser to finish signing in.",
|
|
102
|
+
"examples": [
|
|
103
|
+
"<%= config.bin %> <%= command.id %>",
|
|
104
|
+
"<%= config.bin %> <%= command.id %> --no-open",
|
|
105
|
+
"<%= config.bin %> <%= command.id %> --timeout 120"
|
|
106
|
+
],
|
|
107
|
+
"flags": {
|
|
108
|
+
"json": {
|
|
109
|
+
"description": "Format output as json.",
|
|
110
|
+
"helpGroup": "GLOBAL",
|
|
111
|
+
"name": "json",
|
|
112
|
+
"allowNo": false,
|
|
113
|
+
"type": "boolean"
|
|
114
|
+
},
|
|
115
|
+
"cwd": {
|
|
116
|
+
"char": "c",
|
|
117
|
+
"description": "Project directory to operate on.",
|
|
118
|
+
"name": "cwd",
|
|
119
|
+
"hasDynamicHelp": false,
|
|
120
|
+
"multiple": false,
|
|
121
|
+
"type": "option"
|
|
122
|
+
},
|
|
123
|
+
"server": {
|
|
124
|
+
"char": "s",
|
|
125
|
+
"description": "Override the resolved server URL.",
|
|
126
|
+
"name": "server",
|
|
127
|
+
"hasDynamicHelp": false,
|
|
128
|
+
"multiple": false,
|
|
129
|
+
"type": "option"
|
|
130
|
+
},
|
|
131
|
+
"non-interactive": {
|
|
132
|
+
"char": "n",
|
|
133
|
+
"description": "Disable prompts. Required when scripting or running as an agent.",
|
|
134
|
+
"name": "non-interactive",
|
|
135
|
+
"allowNo": false,
|
|
136
|
+
"type": "boolean"
|
|
137
|
+
},
|
|
138
|
+
"force": {
|
|
139
|
+
"char": "f",
|
|
140
|
+
"description": "Overwrite protected files on conflict.",
|
|
141
|
+
"name": "force",
|
|
142
|
+
"allowNo": false,
|
|
143
|
+
"type": "boolean"
|
|
144
|
+
},
|
|
145
|
+
"dry-run": {
|
|
146
|
+
"description": "Preview without mutating files or the platform.",
|
|
147
|
+
"name": "dry-run",
|
|
148
|
+
"allowNo": false,
|
|
149
|
+
"type": "boolean"
|
|
150
|
+
},
|
|
151
|
+
"verbose": {
|
|
152
|
+
"description": "Verbose logging.",
|
|
153
|
+
"name": "verbose",
|
|
154
|
+
"allowNo": false,
|
|
155
|
+
"type": "boolean"
|
|
156
|
+
},
|
|
157
|
+
"debug": {
|
|
158
|
+
"description": "Debug logging.",
|
|
159
|
+
"name": "debug",
|
|
160
|
+
"allowNo": false,
|
|
161
|
+
"type": "boolean"
|
|
162
|
+
},
|
|
163
|
+
"telemetry": {
|
|
164
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
165
|
+
"name": "telemetry",
|
|
166
|
+
"allowNo": true,
|
|
167
|
+
"type": "boolean"
|
|
168
|
+
},
|
|
169
|
+
"no-open": {
|
|
170
|
+
"description": "Print the link instead of opening a browser.",
|
|
171
|
+
"name": "no-open",
|
|
172
|
+
"allowNo": false,
|
|
173
|
+
"type": "boolean"
|
|
174
|
+
},
|
|
175
|
+
"timeout": {
|
|
176
|
+
"description": "Seconds to wait for the browser step. Defaults to the link's own expiry (10 minutes).",
|
|
177
|
+
"name": "timeout",
|
|
178
|
+
"hasDynamicHelp": false,
|
|
179
|
+
"multiple": false,
|
|
180
|
+
"type": "option"
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
"hasDynamicHelp": false,
|
|
184
|
+
"hiddenAliases": [],
|
|
185
|
+
"id": "claim",
|
|
186
|
+
"pluginAlias": "@zitadel/cli",
|
|
187
|
+
"pluginName": "@zitadel/cli",
|
|
188
|
+
"pluginType": "core",
|
|
189
|
+
"strict": true,
|
|
190
|
+
"enableJsonFlag": true,
|
|
191
|
+
"isESM": true,
|
|
192
|
+
"relativePath": [
|
|
193
|
+
"dist",
|
|
194
|
+
"commands",
|
|
195
|
+
"claim.mjs"
|
|
196
|
+
]
|
|
197
|
+
},
|
|
92
198
|
"doctor": {
|
|
93
199
|
"aliases": [],
|
|
94
200
|
"args": {},
|
|
@@ -149,8 +255,14 @@
|
|
|
149
255
|
"allowNo": false,
|
|
150
256
|
"type": "boolean"
|
|
151
257
|
},
|
|
258
|
+
"telemetry": {
|
|
259
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
260
|
+
"name": "telemetry",
|
|
261
|
+
"allowNo": true,
|
|
262
|
+
"type": "boolean"
|
|
263
|
+
},
|
|
152
264
|
"fix": {
|
|
153
|
-
"description": "
|
|
265
|
+
"description": "Repair missing files and stale managed wiring.",
|
|
154
266
|
"name": "fix",
|
|
155
267
|
"allowNo": false,
|
|
156
268
|
"type": "boolean"
|
|
@@ -258,6 +370,12 @@
|
|
|
258
370
|
"name": "debug",
|
|
259
371
|
"allowNo": false,
|
|
260
372
|
"type": "boolean"
|
|
373
|
+
},
|
|
374
|
+
"telemetry": {
|
|
375
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
376
|
+
"name": "telemetry",
|
|
377
|
+
"allowNo": true,
|
|
378
|
+
"type": "boolean"
|
|
261
379
|
}
|
|
262
380
|
},
|
|
263
381
|
"hasDynamicHelp": false,
|
|
@@ -335,6 +453,12 @@
|
|
|
335
453
|
"allowNo": false,
|
|
336
454
|
"type": "boolean"
|
|
337
455
|
},
|
|
456
|
+
"telemetry": {
|
|
457
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
458
|
+
"name": "telemetry",
|
|
459
|
+
"allowNo": true,
|
|
460
|
+
"type": "boolean"
|
|
461
|
+
},
|
|
338
462
|
"follow": {
|
|
339
463
|
"description": "Follow logs.",
|
|
340
464
|
"name": "follow",
|
|
@@ -425,6 +549,12 @@
|
|
|
425
549
|
"allowNo": false,
|
|
426
550
|
"type": "boolean"
|
|
427
551
|
},
|
|
552
|
+
"telemetry": {
|
|
553
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
554
|
+
"name": "telemetry",
|
|
555
|
+
"allowNo": true,
|
|
556
|
+
"type": "boolean"
|
|
557
|
+
},
|
|
428
558
|
"environment": {
|
|
429
559
|
"char": "e",
|
|
430
560
|
"description": "Target environment (default: development).",
|
|
@@ -513,6 +643,12 @@
|
|
|
513
643
|
"name": "debug",
|
|
514
644
|
"allowNo": false,
|
|
515
645
|
"type": "boolean"
|
|
646
|
+
},
|
|
647
|
+
"telemetry": {
|
|
648
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
649
|
+
"name": "telemetry",
|
|
650
|
+
"allowNo": true,
|
|
651
|
+
"type": "boolean"
|
|
516
652
|
}
|
|
517
653
|
},
|
|
518
654
|
"hasDynamicHelp": false,
|
|
@@ -594,6 +730,12 @@
|
|
|
594
730
|
"allowNo": false,
|
|
595
731
|
"type": "boolean"
|
|
596
732
|
},
|
|
733
|
+
"telemetry": {
|
|
734
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
735
|
+
"name": "telemetry",
|
|
736
|
+
"allowNo": true,
|
|
737
|
+
"type": "boolean"
|
|
738
|
+
},
|
|
597
739
|
"framework": {
|
|
598
740
|
"description": "Framework to target.",
|
|
599
741
|
"name": "framework",
|
|
@@ -604,18 +746,20 @@
|
|
|
604
746
|
"nuxt",
|
|
605
747
|
"react",
|
|
606
748
|
"vue",
|
|
749
|
+
"solid",
|
|
750
|
+
"svelte",
|
|
751
|
+
"qwik",
|
|
607
752
|
"angular"
|
|
608
753
|
],
|
|
609
754
|
"type": "option"
|
|
610
755
|
},
|
|
611
756
|
"renderer": {
|
|
612
|
-
"description": "Renderer (default: react).",
|
|
757
|
+
"description": "Renderer (default: react). Not yet available: web-component.",
|
|
613
758
|
"name": "renderer",
|
|
614
759
|
"hasDynamicHelp": false,
|
|
615
760
|
"multiple": false,
|
|
616
761
|
"options": [
|
|
617
|
-
"react"
|
|
618
|
-
"web-component"
|
|
762
|
+
"react"
|
|
619
763
|
],
|
|
620
764
|
"type": "option"
|
|
621
765
|
},
|
|
@@ -631,6 +775,43 @@
|
|
|
631
775
|
"name": "skip-install",
|
|
632
776
|
"allowNo": false,
|
|
633
777
|
"type": "boolean"
|
|
778
|
+
},
|
|
779
|
+
"preset": {
|
|
780
|
+
"description": "Sign-in preset for the scaffolded schema and login flow (default: password-first).",
|
|
781
|
+
"name": "preset",
|
|
782
|
+
"hasDynamicHelp": false,
|
|
783
|
+
"multiple": false,
|
|
784
|
+
"options": [
|
|
785
|
+
"password-first",
|
|
786
|
+
"passkey-first"
|
|
787
|
+
],
|
|
788
|
+
"type": "option"
|
|
789
|
+
},
|
|
790
|
+
"use-case": {
|
|
791
|
+
"description": "Use case for the scaffolded schema fields: who signs in to the app (default: minimal).",
|
|
792
|
+
"name": "use-case",
|
|
793
|
+
"hasDynamicHelp": false,
|
|
794
|
+
"multiple": false,
|
|
795
|
+
"options": [
|
|
796
|
+
"minimal",
|
|
797
|
+
"consumer",
|
|
798
|
+
"business"
|
|
799
|
+
],
|
|
800
|
+
"type": "option"
|
|
801
|
+
},
|
|
802
|
+
"design": {
|
|
803
|
+
"description": "Login design to eject into .zitadel/branding/ and publish as branding revision 1. Skips the wizard's design question. When omitted in non-interactive runs, the login uses the built-in template; run the `branding eject` command later to customize. Split-family designs (split, split-right, hero) collapse their brand pane by container width: narrow containers — including widget-posture embeds at card width — render the compact brand mark instead (logo_url, else hero_url, from .zitadel/branding/branding.json; hero falls back to editable text).",
|
|
804
|
+
"name": "design",
|
|
805
|
+
"hasDynamicHelp": false,
|
|
806
|
+
"multiple": false,
|
|
807
|
+
"options": [
|
|
808
|
+
"centered",
|
|
809
|
+
"split",
|
|
810
|
+
"split-right",
|
|
811
|
+
"hero",
|
|
812
|
+
"minimal"
|
|
813
|
+
],
|
|
814
|
+
"type": "option"
|
|
634
815
|
}
|
|
635
816
|
},
|
|
636
817
|
"hasDynamicHelp": false,
|
|
@@ -708,6 +889,12 @@
|
|
|
708
889
|
"allowNo": false,
|
|
709
890
|
"type": "boolean"
|
|
710
891
|
},
|
|
892
|
+
"telemetry": {
|
|
893
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
894
|
+
"name": "telemetry",
|
|
895
|
+
"allowNo": true,
|
|
896
|
+
"type": "boolean"
|
|
897
|
+
},
|
|
711
898
|
"image": {
|
|
712
899
|
"description": "Container image to run.",
|
|
713
900
|
"name": "image",
|
|
@@ -809,6 +996,12 @@
|
|
|
809
996
|
"name": "debug",
|
|
810
997
|
"allowNo": false,
|
|
811
998
|
"type": "boolean"
|
|
999
|
+
},
|
|
1000
|
+
"telemetry": {
|
|
1001
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
1002
|
+
"name": "telemetry",
|
|
1003
|
+
"allowNo": true,
|
|
1004
|
+
"type": "boolean"
|
|
812
1005
|
}
|
|
813
1006
|
},
|
|
814
1007
|
"hasDynamicHelp": false,
|
|
@@ -885,6 +1078,18 @@
|
|
|
885
1078
|
"name": "debug",
|
|
886
1079
|
"allowNo": false,
|
|
887
1080
|
"type": "boolean"
|
|
1081
|
+
},
|
|
1082
|
+
"telemetry": {
|
|
1083
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
1084
|
+
"name": "telemetry",
|
|
1085
|
+
"allowNo": true,
|
|
1086
|
+
"type": "boolean"
|
|
1087
|
+
},
|
|
1088
|
+
"all": {
|
|
1089
|
+
"description": "Stop all discovered CLI-managed local Zitadel runtime processes.",
|
|
1090
|
+
"name": "all",
|
|
1091
|
+
"allowNo": false,
|
|
1092
|
+
"type": "boolean"
|
|
888
1093
|
}
|
|
889
1094
|
},
|
|
890
1095
|
"hasDynamicHelp": false,
|
|
@@ -901,7 +1106,209 @@
|
|
|
901
1106
|
"commands",
|
|
902
1107
|
"stop.mjs"
|
|
903
1108
|
]
|
|
1109
|
+
},
|
|
1110
|
+
"branding:eject": {
|
|
1111
|
+
"aliases": [],
|
|
1112
|
+
"args": {},
|
|
1113
|
+
"description": "Take ownership of the login template: scaffold .zitadel/branding/ from a shipped design.",
|
|
1114
|
+
"flags": {
|
|
1115
|
+
"json": {
|
|
1116
|
+
"description": "Format output as json.",
|
|
1117
|
+
"helpGroup": "GLOBAL",
|
|
1118
|
+
"name": "json",
|
|
1119
|
+
"allowNo": false,
|
|
1120
|
+
"type": "boolean"
|
|
1121
|
+
},
|
|
1122
|
+
"cwd": {
|
|
1123
|
+
"char": "c",
|
|
1124
|
+
"description": "Project directory to operate on.",
|
|
1125
|
+
"name": "cwd",
|
|
1126
|
+
"hasDynamicHelp": false,
|
|
1127
|
+
"multiple": false,
|
|
1128
|
+
"type": "option"
|
|
1129
|
+
},
|
|
1130
|
+
"server": {
|
|
1131
|
+
"char": "s",
|
|
1132
|
+
"description": "Override the resolved server URL.",
|
|
1133
|
+
"name": "server",
|
|
1134
|
+
"hasDynamicHelp": false,
|
|
1135
|
+
"multiple": false,
|
|
1136
|
+
"type": "option"
|
|
1137
|
+
},
|
|
1138
|
+
"non-interactive": {
|
|
1139
|
+
"char": "n",
|
|
1140
|
+
"description": "Disable prompts. Required when scripting or running as an agent.",
|
|
1141
|
+
"name": "non-interactive",
|
|
1142
|
+
"allowNo": false,
|
|
1143
|
+
"type": "boolean"
|
|
1144
|
+
},
|
|
1145
|
+
"force": {
|
|
1146
|
+
"char": "f",
|
|
1147
|
+
"description": "Overwrite protected files on conflict.",
|
|
1148
|
+
"name": "force",
|
|
1149
|
+
"allowNo": false,
|
|
1150
|
+
"type": "boolean"
|
|
1151
|
+
},
|
|
1152
|
+
"dry-run": {
|
|
1153
|
+
"description": "Preview without mutating files or the platform.",
|
|
1154
|
+
"name": "dry-run",
|
|
1155
|
+
"allowNo": false,
|
|
1156
|
+
"type": "boolean"
|
|
1157
|
+
},
|
|
1158
|
+
"verbose": {
|
|
1159
|
+
"description": "Verbose logging.",
|
|
1160
|
+
"name": "verbose",
|
|
1161
|
+
"allowNo": false,
|
|
1162
|
+
"type": "boolean"
|
|
1163
|
+
},
|
|
1164
|
+
"debug": {
|
|
1165
|
+
"description": "Debug logging.",
|
|
1166
|
+
"name": "debug",
|
|
1167
|
+
"allowNo": false,
|
|
1168
|
+
"type": "boolean"
|
|
1169
|
+
},
|
|
1170
|
+
"telemetry": {
|
|
1171
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
1172
|
+
"name": "telemetry",
|
|
1173
|
+
"allowNo": true,
|
|
1174
|
+
"type": "boolean"
|
|
1175
|
+
},
|
|
1176
|
+
"design": {
|
|
1177
|
+
"description": "Design to start from (default: centered).",
|
|
1178
|
+
"name": "design",
|
|
1179
|
+
"hasDynamicHelp": false,
|
|
1180
|
+
"multiple": false,
|
|
1181
|
+
"options": [
|
|
1182
|
+
"centered",
|
|
1183
|
+
"split",
|
|
1184
|
+
"split-right",
|
|
1185
|
+
"hero",
|
|
1186
|
+
"minimal"
|
|
1187
|
+
],
|
|
1188
|
+
"type": "option"
|
|
1189
|
+
}
|
|
1190
|
+
},
|
|
1191
|
+
"hasDynamicHelp": false,
|
|
1192
|
+
"hiddenAliases": [],
|
|
1193
|
+
"id": "branding:eject",
|
|
1194
|
+
"pluginAlias": "@zitadel/cli",
|
|
1195
|
+
"pluginName": "@zitadel/cli",
|
|
1196
|
+
"pluginType": "core",
|
|
1197
|
+
"strict": true,
|
|
1198
|
+
"enableJsonFlag": true,
|
|
1199
|
+
"isESM": true,
|
|
1200
|
+
"relativePath": [
|
|
1201
|
+
"dist",
|
|
1202
|
+
"commands",
|
|
1203
|
+
"branding",
|
|
1204
|
+
"eject.mjs"
|
|
1205
|
+
]
|
|
1206
|
+
},
|
|
1207
|
+
"schemas:list": {
|
|
1208
|
+
"aliases": [],
|
|
1209
|
+
"args": {},
|
|
1210
|
+
"description": "List revisions of a user-schema by objectType.",
|
|
1211
|
+
"flags": {
|
|
1212
|
+
"json": {
|
|
1213
|
+
"description": "Format output as json.",
|
|
1214
|
+
"helpGroup": "GLOBAL",
|
|
1215
|
+
"name": "json",
|
|
1216
|
+
"allowNo": false,
|
|
1217
|
+
"type": "boolean"
|
|
1218
|
+
},
|
|
1219
|
+
"cwd": {
|
|
1220
|
+
"char": "c",
|
|
1221
|
+
"description": "Project directory to operate on.",
|
|
1222
|
+
"name": "cwd",
|
|
1223
|
+
"hasDynamicHelp": false,
|
|
1224
|
+
"multiple": false,
|
|
1225
|
+
"type": "option"
|
|
1226
|
+
},
|
|
1227
|
+
"server": {
|
|
1228
|
+
"char": "s",
|
|
1229
|
+
"description": "Override the resolved server URL.",
|
|
1230
|
+
"name": "server",
|
|
1231
|
+
"hasDynamicHelp": false,
|
|
1232
|
+
"multiple": false,
|
|
1233
|
+
"type": "option"
|
|
1234
|
+
},
|
|
1235
|
+
"non-interactive": {
|
|
1236
|
+
"char": "n",
|
|
1237
|
+
"description": "Disable prompts. Required when scripting or running as an agent.",
|
|
1238
|
+
"name": "non-interactive",
|
|
1239
|
+
"allowNo": false,
|
|
1240
|
+
"type": "boolean"
|
|
1241
|
+
},
|
|
1242
|
+
"force": {
|
|
1243
|
+
"char": "f",
|
|
1244
|
+
"description": "Overwrite protected files on conflict.",
|
|
1245
|
+
"name": "force",
|
|
1246
|
+
"allowNo": false,
|
|
1247
|
+
"type": "boolean"
|
|
1248
|
+
},
|
|
1249
|
+
"dry-run": {
|
|
1250
|
+
"description": "Preview without mutating files or the platform.",
|
|
1251
|
+
"name": "dry-run",
|
|
1252
|
+
"allowNo": false,
|
|
1253
|
+
"type": "boolean"
|
|
1254
|
+
},
|
|
1255
|
+
"verbose": {
|
|
1256
|
+
"description": "Verbose logging.",
|
|
1257
|
+
"name": "verbose",
|
|
1258
|
+
"allowNo": false,
|
|
1259
|
+
"type": "boolean"
|
|
1260
|
+
},
|
|
1261
|
+
"debug": {
|
|
1262
|
+
"description": "Debug logging.",
|
|
1263
|
+
"name": "debug",
|
|
1264
|
+
"allowNo": false,
|
|
1265
|
+
"type": "boolean"
|
|
1266
|
+
},
|
|
1267
|
+
"telemetry": {
|
|
1268
|
+
"description": "Send anonymous usage analytics. Disable with --no-telemetry.",
|
|
1269
|
+
"name": "telemetry",
|
|
1270
|
+
"allowNo": true,
|
|
1271
|
+
"type": "boolean"
|
|
1272
|
+
},
|
|
1273
|
+
"object-type": {
|
|
1274
|
+
"char": "t",
|
|
1275
|
+
"description": "Filter revisions by objectType (e.g. human-user).",
|
|
1276
|
+
"name": "object-type",
|
|
1277
|
+
"required": true,
|
|
1278
|
+
"hasDynamicHelp": false,
|
|
1279
|
+
"multiple": false,
|
|
1280
|
+
"type": "option"
|
|
1281
|
+
},
|
|
1282
|
+
"environment": {
|
|
1283
|
+
"char": "e",
|
|
1284
|
+
"description": "Target environment (default: development).",
|
|
1285
|
+
"name": "environment",
|
|
1286
|
+
"hasDynamicHelp": false,
|
|
1287
|
+
"multiple": false,
|
|
1288
|
+
"options": [
|
|
1289
|
+
"development",
|
|
1290
|
+
"preview",
|
|
1291
|
+
"production"
|
|
1292
|
+
],
|
|
1293
|
+
"type": "option"
|
|
1294
|
+
}
|
|
1295
|
+
},
|
|
1296
|
+
"hasDynamicHelp": false,
|
|
1297
|
+
"hiddenAliases": [],
|
|
1298
|
+
"id": "schemas:list",
|
|
1299
|
+
"pluginAlias": "@zitadel/cli",
|
|
1300
|
+
"pluginName": "@zitadel/cli",
|
|
1301
|
+
"pluginType": "core",
|
|
1302
|
+
"strict": true,
|
|
1303
|
+
"enableJsonFlag": true,
|
|
1304
|
+
"isESM": true,
|
|
1305
|
+
"relativePath": [
|
|
1306
|
+
"dist",
|
|
1307
|
+
"commands",
|
|
1308
|
+
"schemas",
|
|
1309
|
+
"list.mjs"
|
|
1310
|
+
]
|
|
904
1311
|
}
|
|
905
1312
|
},
|
|
906
|
-
"version": "
|
|
1313
|
+
"version": "1.0.0-alpha.20"
|
|
907
1314
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zitadel/cli",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "1.0.0-alpha.20",
|
|
4
4
|
"description": "Agent-friendly Zitadel CLI",
|
|
5
5
|
"homepage": "https://github.com/zitadel/nextgen/tree/main/apps/cli#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -56,20 +56,25 @@
|
|
|
56
56
|
"ajv": "^8.20.0",
|
|
57
57
|
"consola": "^3.4.2",
|
|
58
58
|
"magicast": "^0.5.3",
|
|
59
|
+
"mixpanel": "^0.18.1",
|
|
59
60
|
"safe-stable-stringify": "^2.5.0",
|
|
61
|
+
"semver": "^7.7.3",
|
|
62
|
+
"undici": "^7.24.7",
|
|
60
63
|
"zod": "^4.3.6",
|
|
61
64
|
"picocolors": "^1.1.1",
|
|
62
|
-
"@zitadel/
|
|
63
|
-
"@zitadel/
|
|
65
|
+
"@zitadel/api": "1.0.0-alpha.20",
|
|
66
|
+
"@zitadel/config": "1.0.0-alpha.20",
|
|
67
|
+
"@zitadel/server": "1.0.0-alpha.20"
|
|
64
68
|
},
|
|
65
69
|
"devDependencies": {
|
|
66
70
|
"@types/node": "^25.6.0",
|
|
71
|
+
"@types/semver": "^7.7.1",
|
|
67
72
|
"msw": "^2.14.6",
|
|
68
73
|
"oclif": "^4.17.46",
|
|
69
74
|
"tsdown": "^0.21.10",
|
|
70
75
|
"vitest": "^3.0.0",
|
|
71
|
-
"@zitadel/
|
|
72
|
-
"@zitadel/
|
|
76
|
+
"@zitadel/api-mock": "0.0.0",
|
|
77
|
+
"@zitadel/sdk-next": "1.0.0-alpha.20"
|
|
73
78
|
},
|
|
74
79
|
"scripts": {
|
|
75
80
|
"build": "tsdown",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"docker-BA78SdC2.mjs","names":[],"sources":["../src/lib/local-server/binary.ts","../src/lib/local-server/docker.ts"],"sourcesContent":["import { spawn } from \"node:child_process\";\nimport { createReadStream } from \"node:fs\";\nimport { mkdir, open, readFile, stat } from \"node:fs/promises\";\nimport { createRequire } from \"node:module\";\nimport { dirname, join } from \"node:path\";\n\nimport { ZitadelError } from \"../errors\";\nimport {\n type BinaryRuntimeMetadata,\n type RuntimeMetadata,\n checkLocalServerHealth,\n} from \"./runtime\";\n\nexport const SERVER_NPM_PACKAGE = \"@zitadel/server\";\nconst START_COMMAND_ENV = \"ZITADEL_SERVER_BINARY\";\n\nconst require = createRequire(import.meta.url);\n\nexport type BinaryRunSpec = {\n cliVersion: string;\n dataDir: string;\n logPath: string;\n port: number;\n serverUrl: string;\n};\n\nexport function resolveServerCommand(env: NodeJS.ProcessEnv = process.env): {\n command: string;\n args: string[];\n serverPackage: string;\n serverVersion: string;\n} {\n if (env[START_COMMAND_ENV]) {\n return {\n command: env[START_COMMAND_ENV],\n args: [],\n serverPackage: SERVER_NPM_PACKAGE,\n serverVersion: \"override\",\n };\n }\n\n const manifestPath = resolveServerPackageManifest();\n const manifest = require(manifestPath) as { version?: unknown };\n return {\n command: process.execPath,\n args: [join(dirname(manifestPath), \"bin\", \"zitadel-server.js\")],\n serverPackage: SERVER_NPM_PACKAGE,\n serverVersion: typeof manifest.version === \"string\" ? manifest.version : \"unknown\",\n };\n}\n\nexport async function startBinaryRuntime(spec: BinaryRunSpec): Promise<BinaryRuntimeMetadata> {\n const command = resolveServerCommand();\n await mkdir(dirname(spec.logPath), { recursive: true, mode: 0o700 });\n const log = await open(spec.logPath, \"a\", 0o600);\n try {\n const child = spawn(command.command, command.args, {\n detached: true,\n env: {\n ...process.env,\n NEXTGEN_SERVER_ADDRESS: `:${String(spec.port)}`,\n NEXTGEN_SERVER_DATA_DIR: spec.dataDir,\n },\n stdio: [\"ignore\", log.fd, log.fd],\n });\n child.unref();\n if (!child.pid) {\n throw new Error(\"server process did not expose a pid\");\n }\n return {\n schema_version: 1,\n backend: \"binary\",\n pid: child.pid,\n command: [command.command, ...command.args].join(\" \"),\n log_path: spec.logPath,\n server_package: command.serverPackage,\n server_version: command.serverVersion,\n port: spec.port,\n server_url: spec.serverUrl,\n data_dir: spec.dataDir,\n created_at: new Date().toISOString(),\n cli_version: spec.cliVersion,\n };\n } finally {\n await log.close();\n }\n}\n\nexport async function stopBinaryRuntime(pid: number): Promise<void> {\n if (!isProcessRunning(pid)) {\n return;\n }\n if (!signalProcess(pid, \"SIGTERM\")) {\n return;\n }\n const deadline = Date.now() + 10_000;\n while (Date.now() < deadline) {\n if (!isProcessRunning(pid)) {\n return;\n }\n await delay(200);\n }\n if (isProcessRunning(pid)) {\n signalProcess(pid, \"SIGKILL\");\n }\n}\n\nexport function isProcessRunning(pid: number): boolean {\n try {\n process.kill(pid, 0);\n return true;\n } catch (error) {\n return isErrno(error, \"EPERM\");\n }\n}\n\nexport async function binaryLogs(logPath: string, tail: number): Promise<string> {\n let content = \"\";\n try {\n content = await readFile(logPath, \"utf8\");\n } catch (error) {\n if (isErrno(error, \"ENOENT\")) {\n return \"\";\n }\n throw error;\n }\n const lines = content.split(/\\r?\\n/);\n const hasTrailingNewline = lines.at(-1) === \"\";\n const body = hasTrailingNewline ? lines.slice(0, -1) : lines;\n const selected = body.slice(-tail).join(\"\\n\");\n return selected.length === 0 ? \"\" : `${selected}${hasTrailingNewline ? \"\\n\" : \"\"}`;\n}\n\nexport async function followBinaryLogs(logPath: string, tail: number): Promise<void> {\n process.stdout.write(await binaryLogs(logPath, tail));\n let offset = await fileSize(logPath);\n await new Promise<void>((resolveFollow, reject) => {\n const interval = setInterval(() => {\n void (async () => {\n try {\n const size = await fileSize(logPath);\n if (size > offset) {\n const stream = createReadStream(logPath, { start: offset, end: size - 1 });\n stream.pipe(process.stdout, { end: false });\n offset = size;\n }\n } catch (error) {\n reject(error);\n }\n })();\n }, 1000);\n const stop = () => {\n clearInterval(interval);\n resolveFollow();\n };\n process.once(\"SIGINT\", stop);\n process.once(\"SIGTERM\", stop);\n });\n}\n\nexport async function assertServerPackageAvailable(): Promise<string> {\n try {\n const command = resolveServerCommand();\n return command.serverVersion;\n } catch (error) {\n throw new ZitadelError(\"E_VALIDATION\", \"Zitadel server npm package is not available\", {\n hint: \"Reinstall @zitadel/cli so npm can install @zitadel/server and its platform package.\",\n nextCommands: [\"npm install @zitadel/cli@alpha\"],\n details: { package: SERVER_NPM_PACKAGE, message: errorMessage(error) },\n });\n }\n}\n\nexport async function binaryRuntimeHealthy(runtime: RuntimeMetadata): Promise<boolean> {\n return (\n runtime.backend === \"binary\" &&\n isProcessRunning(runtime.pid) &&\n (await checkLocalServerHealth(runtime.server_url))\n );\n}\n\nfunction resolveServerPackageManifest(): string {\n try {\n return require.resolve(`${SERVER_NPM_PACKAGE}/package.json`);\n } catch (error) {\n throw new Error(`Missing ${SERVER_NPM_PACKAGE}. Reinstall @zitadel/cli.`, { cause: error });\n }\n}\n\nasync function fileSize(path: string): Promise<number> {\n try {\n return (await stat(path)).size;\n } catch (error) {\n if (isErrno(error, \"ENOENT\")) {\n return 0;\n }\n throw error;\n }\n}\n\nfunction isErrno(error: unknown, code: string): boolean {\n return (\n typeof error === \"object\" &&\n error !== null &&\n \"code\" in error &&\n (error as { code?: unknown }).code === code\n );\n}\n\nfunction signalProcess(pid: number, signal: NodeJS.Signals): boolean {\n try {\n process.kill(pid, signal);\n return true;\n } catch (error) {\n if (isErrno(error, \"ESRCH\")) {\n return false;\n }\n throw error;\n }\n}\n\nfunction errorMessage(error: unknown): string {\n return error instanceof Error ? error.message : String(error);\n}\n\nfunction delay(ms: number): Promise<void> {\n return new Promise((resolveDelay) => setTimeout(resolveDelay, ms));\n}\n","import { spawn } from \"node:child_process\";\n\nimport { ZitadelError } from \"../errors\";\nimport {\n CONTAINER_DATA_DIR,\n CONTAINER_HTTP_PORT,\n type ContainerIdentity,\n type RuntimeMetadata,\n} from \"./runtime\";\n\nexport type DockerResult = {\n status: number;\n stdout: string;\n stderr: string;\n};\n\nexport type DockerRunSpec = {\n containerName: string;\n image: string;\n port: number;\n dataDir: string;\n identity?: ContainerIdentity;\n};\n\nexport function dockerRunArgs(spec: DockerRunSpec): string[] {\n const args = [\n \"run\",\n \"--detach\",\n \"--name\",\n spec.containerName,\n \"--publish\",\n `127.0.0.1:${spec.port}:${CONTAINER_HTTP_PORT}`,\n \"--volume\",\n `${spec.dataDir}:${CONTAINER_DATA_DIR}`,\n \"--env\",\n `NEXTGEN_SERVER_ADDRESS=:${CONTAINER_HTTP_PORT}`,\n \"--env\",\n `NEXTGEN_SERVER_DATA_DIR=${CONTAINER_DATA_DIR}`,\n ];\n\n if (spec.identity) {\n args.push(\n \"--volume\",\n `${spec.identity.passwdFile}:/etc/passwd:ro`,\n \"--volume\",\n `${spec.identity.groupFile}:/etc/group:ro`,\n \"--user\",\n `${spec.identity.uid}:${spec.identity.gid}`,\n );\n }\n\n args.push(spec.image);\n return args;\n}\n\nexport async function runDocker(args: string[]): Promise<DockerResult> {\n return new Promise((resolve, reject) => {\n const child = spawn(\"docker\", args, {\n stdio: [\"ignore\", \"pipe\", \"pipe\"],\n env: process.env,\n });\n let stdout = \"\";\n let stderr = \"\";\n child.stdout?.setEncoding(\"utf8\");\n child.stderr?.setEncoding(\"utf8\");\n child.stdout?.on(\"data\", (chunk: string) => {\n stdout += chunk;\n });\n child.stderr?.on(\"data\", (chunk: string) => {\n stderr += chunk;\n });\n child.on(\"error\", reject);\n child.on(\"close\", (code) => {\n resolve({ status: code ?? 1, stdout, stderr });\n });\n });\n}\n\nexport async function streamDocker(args: string[]): Promise<void> {\n await new Promise<void>((resolve, reject) => {\n const child = spawn(\"docker\", args, {\n stdio: \"inherit\",\n env: process.env,\n });\n child.on(\"error\", reject);\n child.on(\"close\", (code) => {\n if (code === 0) {\n resolve();\n } else {\n reject(new Error(`docker ${args.join(\" \")} exited with status ${code ?? 1}`));\n }\n });\n });\n}\n\nexport async function dockerAvailable(): Promise<DockerResult> {\n return runDocker([\"version\", \"--format\", \"{{.Server.Version}}\"]);\n}\n\nexport async function pullImage(image: string): Promise<void> {\n await requireDocker([\"pull\", \"--quiet\", image], `Pull Docker image ${image}`);\n}\n\nexport async function imageExists(image: string): Promise<boolean> {\n let result: DockerResult;\n const args = [\"image\", \"inspect\", image];\n try {\n result = await runDocker(args);\n } catch (error) {\n throw dockerError(`Inspect Docker image ${image}`, args, error);\n }\n return result.status === 0;\n}\n\nexport async function imageAvailable(image: string): Promise<\"local\" | \"remote\"> {\n if (await imageExists(image)) {\n return \"local\";\n }\n\n const args = [\"manifest\", \"inspect\", image];\n let result: DockerResult;\n try {\n result = await runDocker(args);\n } catch (error) {\n throw dockerError(`Inspect Docker image ${image}`, args, error);\n }\n if (result.status === 0) {\n return \"remote\";\n }\n throw dockerError(`Inspect Docker image ${image}`, args, result);\n}\n\nexport async function ensureImage(image: string): Promise<\"local\" | \"pulled\"> {\n if (await imageExists(image)) {\n return \"local\";\n }\n await pullImage(image);\n return \"pulled\";\n}\n\nexport async function inspectContainer(containerName: string): Promise<{\n exists: boolean;\n running: boolean;\n id?: string;\n image?: string;\n}> {\n const result = await runDocker([\n \"inspect\",\n \"--format\",\n \"{{.Id}} {{.State.Running}} {{.Config.Image}}\",\n containerName,\n ]);\n if (result.status !== 0) {\n return { exists: false, running: false };\n }\n const [id, running, ...imageParts] = result.stdout.trim().split(/\\s+/);\n return { exists: true, running: running === \"true\", id, image: imageParts.join(\" \") };\n}\n\nexport async function startContainer(spec: DockerRunSpec): Promise<string> {\n const args = dockerRunArgs(spec);\n const result = await requireDocker(args, \"Start local Zitadel container\");\n return result.stdout.trim();\n}\n\nexport async function stopAndRemoveContainer(containerName: string): Promise<void> {\n const inspect = await inspectContainer(containerName);\n if (!inspect.exists) {\n return;\n }\n if (inspect.running) {\n await requireDocker([\"stop\", containerName], `Stop ${containerName}`);\n }\n await requireDocker([\"rm\", containerName], `Remove ${containerName}`);\n}\n\nexport async function containerLogs(containerName: string, tail: number): Promise<string> {\n const result = await requireDocker([\"logs\", \"--tail\", String(tail), containerName], \"Read logs\");\n return result.stdout;\n}\n\nexport async function followContainerLogs(containerName: string, tail: number): Promise<void> {\n await streamDocker([\"logs\", \"--tail\", String(tail), \"--follow\", containerName]);\n}\n\nexport function currentUser(): { uid?: number; gid?: number } {\n const getuid = process.getuid;\n const getgid = process.getgid;\n if (typeof getuid !== \"function\") {\n return {};\n }\n const uid = getuid();\n const gid = typeof getgid === \"function\" ? getgid() : uid;\n return { uid, gid };\n}\n\nexport function metadataFromStart(input: {\n cwdDataDir: string;\n cliVersion: string;\n containerName: string;\n containerId: string;\n image: string;\n port: number;\n serverUrl: string;\n}): RuntimeMetadata {\n return {\n schema_version: 1,\n backend: \"docker\",\n container_name: input.containerName,\n container_id: input.containerId,\n image: input.image,\n port: input.port,\n server_url: input.serverUrl,\n data_dir: input.cwdDataDir,\n created_at: new Date().toISOString(),\n cli_version: input.cliVersion,\n };\n}\n\nexport async function requireDocker(args: string[], action: string): Promise<DockerResult> {\n let result: DockerResult;\n try {\n result = await runDocker(args);\n } catch (error) {\n throw dockerError(action, args, error);\n }\n if (result.status !== 0) {\n throw dockerError(action, args, result);\n }\n return result;\n}\n\nfunction dockerError(action: string, args: string[], cause: unknown): ZitadelError {\n const details =\n cause && typeof cause === \"object\" && \"stderr\" in cause\n ? { command: [\"docker\", ...args], stderr: String((cause as { stderr?: unknown }).stderr) }\n : { command: [\"docker\", ...args], cause };\n return new ZitadelError(\"E_VALIDATION\", `${action} failed`, {\n hint: \"Check that Docker is installed, running, and reachable from this shell.\",\n nextCommands: [\"zitadel doctor\"],\n details,\n });\n}\n"],"mappings":";;;;;;;AAaA,MAAa,qBAAqB;AAClC,MAAM,oBAAoB;AAE1B,MAAM,UAAU,cAAc,OAAO,KAAK,IAAI;AAU9C,SAAgB,qBAAqB,MAAyB,QAAQ,KAKpE;AACA,KAAI,IAAI,mBACN,QAAO;EACL,SAAS,IAAI;EACb,MAAM,EAAE;EACR,eAAe;EACf,eAAe;EAChB;CAGH,MAAM,eAAe,8BAA8B;CACnD,MAAM,WAAW,QAAQ,aAAa;AACtC,QAAO;EACL,SAAS,QAAQ;EACjB,MAAM,CAAC,KAAK,QAAQ,aAAa,EAAE,OAAO,oBAAoB,CAAC;EAC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GjF,SAAgB,cAA8C;CAC5D,MAAM,SAAS,QAAQ;CACvB,MAAM,SAAS,QAAQ;AACvB,KAAI,OAAO,WAAW,WACpB,QAAO,EAAE;CAEX,MAAM,MAAM,QAAQ;AAEpB,QAAO;EAAE;EAAK,KADF,OAAO,WAAW,aAAa,QAAQ,GAAG;EACnC;;AAGrB,SAAgB,kBAAkB,OAQd;AAClB,QAAO;EACL,gBAAgB;EAChB,SAAS;EACT,gBAAgB,MAAM;EACtB,cAAc,MAAM;EACpB,OAAO,MAAM;EACb,MAAM,MAAM;EACZ,YAAY,MAAM;EAClB,UAAU,MAAM;EAChB,6BAAY,IAAI,MAAM,EAAC,aAAa;EACpC,aAAa,MAAM;EACpB;;AAGH,eAAsB,cAAc,MAAgB,QAAuC;CACzF,IAAI;AACJ,KAAI;AACF,WAAS,MAAM,UAAU,KAAK;UACvB,OAAO;AACd,QAAM,YAAY,QAAQ,MAAM,MAAM;;AAExC,KAAI,OAAO,WAAW,EACpB,OAAM,YAAY,QAAQ,MAAM,OAAO;AAEzC,QAAO;;AAGT,SAAS,YAAY,QAAgB,MAAgB,OAA8B;CACjF,MAAM,UACJ,SAAS,OAAO,UAAU,YAAY,YAAY,QAC9C;EAAE,SAAS,CAAC,UAAU,GAAG,KAAK;EAAE,QAAQ,OAAQ,MAA+B,OAAO;EAAE,GACxF;EAAE,SAAS,CAAC,UAAU,GAAG,KAAK;EAAE;EAAO;AAC7C,QAAO,IAAI,aAAa,gBAAgB,GAAG,OAAO,UAAU;EAC1D,MAAM;EACN,cAAc,CAAC,iBAAiB;EAChC;EACD,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { x as publicCliCommand } from "./oclif-VkCTGIEk.mjs";
|
|
2
|
-
//#region src/lib/local-server/docker-guidance.ts
|
|
3
|
-
function dockerUnavailableMessage(error) {
|
|
4
|
-
const detail = error instanceof Error ? error.message : String(error);
|
|
5
|
-
return `Docker is not reachable${detail.trim() ? ` (${detail.trim()})` : ""}; managed local runtime commands need Docker, but remote or cloud setup can continue with --server <url>.`;
|
|
6
|
-
}
|
|
7
|
-
function dockerRuntimeGuidance(retryCommand, cliVersion) {
|
|
8
|
-
return {
|
|
9
|
-
hint: "Docker is required only for the managed local runtime (`zitadel start` and `--server local`). Start Docker, then retry; or target a remote server with `--server <url>`.",
|
|
10
|
-
nextActions: [
|
|
11
|
-
"Start Docker Desktop, Docker Engine, or a Docker-compatible runtime such as Colima.",
|
|
12
|
-
`Run \`docker version\`, then rerun \`${publicCliCommand(retryCommand, cliVersion)}\`.`,
|
|
13
|
-
"If you are not using the managed local runtime, run setup with `--server <url>` instead."
|
|
14
|
-
],
|
|
15
|
-
nextCommands: ["docker version", publicCliCommand(retryCommand, cliVersion)]
|
|
16
|
-
};
|
|
17
|
-
}
|
|
18
|
-
//#endregion
|
|
19
|
-
export { dockerUnavailableMessage as n, dockerRuntimeGuidance as t };
|
|
20
|
-
|
|
21
|
-
//# sourceMappingURL=docker-guidance-BvfpmsDj.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"docker-guidance-BvfpmsDj.mjs","names":[],"sources":["../src/lib/local-server/docker-guidance.ts"],"sourcesContent":["import { publicCliCommand } from \"../public-cli\";\n\nexport type DockerRuntimeGuidance = {\n hint: string;\n nextActions: string[];\n nextCommands: string[];\n};\n\nexport function dockerUnavailableMessage(error: unknown): string {\n const detail = error instanceof Error ? error.message : String(error);\n const suffix = detail.trim() ? ` (${detail.trim()})` : \"\";\n return `Docker is not reachable${suffix}; managed local runtime commands need Docker, but remote or cloud setup can continue with --server <url>.`;\n}\n\nexport function dockerRuntimeGuidance(\n retryCommand: \"doctor\" | \"start\",\n cliVersion: string,\n): DockerRuntimeGuidance {\n return {\n hint:\n \"Docker is required only for the managed local runtime (`zitadel start` and `--server local`). Start Docker, then retry; or target a remote server with `--server <url>`.\",\n nextActions: [\n \"Start Docker Desktop, Docker Engine, or a Docker-compatible runtime such as Colima.\",\n `Run \\`docker version\\`, then rerun \\`${publicCliCommand(retryCommand, cliVersion)}\\`.`,\n \"If you are not using the managed local runtime, run setup with `--server <url>` instead.\",\n ],\n nextCommands: [\"docker version\", publicCliCommand(retryCommand, cliVersion)],\n };\n}\n"],"mappings":";;AAQA,SAAgB,yBAAyB,OAAwB;CAC/D,MAAM,SAAS,iBAAiB,QAAQ,MAAM,UAAU,OAAO,MAAM;AAErE,QAAO,0BADQ,OAAO,MAAM,GAAG,KAAK,OAAO,MAAM,CAAC,KAAK,GACf;;AAG1C,SAAgB,sBACd,cACA,YACuB;AACvB,QAAO;EACL,MACE;EACF,aAAa;GACX;GACA,wCAAwC,iBAAiB,cAAc,WAAW,CAAC;GACnF;GACD;EACD,cAAc,CAAC,kBAAkB,iBAAiB,cAAc,WAAW,CAAC;EAC7E"}
|