codefresh 0.84.10 → 0.85.0
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/Dockerfile +12 -6
- package/Dockerfile-debian +15 -6
- package/Dockerfile-debian-rootless +15 -7
- package/Dockerfile-rootless +13 -7
- package/codefresh-arm.yml +16 -8
- package/codefresh.yml +21 -9
- package/lib/interface/cli/commands/agent/install.cmd.js +191 -113
- package/lib/interface/cli/commands/runtimeEnvironments/attach.cmd.js +105 -84
- package/lib/interface/cli/commands/runtimeEnvironments/install.cmd.js +216 -188
- package/lib/interface/cli/completion/tree.json +1 -1
- package/package.json +1 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
/* eslint-disable max-len */
|
|
2
|
+
const cliProgress = require('cli-progress');
|
|
3
|
+
const colors = require('colors');
|
|
4
|
+
const _ = require('lodash');
|
|
2
5
|
const Command = require('../../Command');
|
|
3
6
|
const { sdk } = require('../../../../logic');
|
|
4
7
|
const attachRuntimeCmd = require('./attach.cmd');
|
|
5
8
|
const installRoot = require('../root/install.cmd');
|
|
6
9
|
const { getKubeContext } = require('../../helpers/kubernetes');
|
|
7
10
|
const ProgressEvents = require('../../helpers/progressEvents');
|
|
8
|
-
const cliProgress = require('cli-progress');
|
|
9
11
|
const createClusterCmd = require('../cluster/create.cmd');
|
|
10
|
-
const
|
|
11
|
-
const _ = require('lodash');
|
|
12
|
-
const { DefaultLogFormatter, INSTALLATION_DEFAULTS } = require('./../hybrid/helper');
|
|
12
|
+
const { DefaultLogFormatter, INSTALLATION_DEFAULTS } = require('../hybrid/helper');
|
|
13
13
|
|
|
14
14
|
const defaultNamespace = 'codefresh';
|
|
15
15
|
const defaultStorageClassPrefix = 'dind-local-volumes-runner';
|
|
@@ -20,10 +20,10 @@ async function newRuntimeName(kubeContextName, kubeNamespace) {
|
|
|
20
20
|
const runtimes = await sdk.runtimeEnvs.list({ });
|
|
21
21
|
let name;
|
|
22
22
|
|
|
23
|
-
if (!_.isArray(runtimes) || !_.find(runtimes, re => _.get(re, 'metadata.name') === defaultName)) {
|
|
23
|
+
if (!_.isArray(runtimes) || !_.find(runtimes, (re) => _.get(re, 'metadata.name') === defaultName)) {
|
|
24
24
|
name = defaultName; // use the default name if there are no collisions
|
|
25
25
|
} else {
|
|
26
|
-
const reNames = new Set(_.map(runtimes, re => _.get(re, 'metadata.name'))); // for fast lookup
|
|
26
|
+
const reNames = new Set(_.map(runtimes, (re) => _.get(re, 'metadata.name'))); // for fast lookup
|
|
27
27
|
let i = 1;
|
|
28
28
|
let suggestName;
|
|
29
29
|
// eslint-disable-next-line no-constant-condition
|
|
@@ -34,11 +34,185 @@ async function newRuntimeName(kubeContextName, kubeNamespace) {
|
|
|
34
34
|
}
|
|
35
35
|
i += 1;
|
|
36
36
|
}
|
|
37
|
+
|
|
37
38
|
name = suggestName;
|
|
38
39
|
}
|
|
39
40
|
|
|
40
41
|
return name;
|
|
41
42
|
}
|
|
43
|
+
|
|
44
|
+
async function createRuntimeInPlatform(argv, runtimeName) {
|
|
45
|
+
const {
|
|
46
|
+
kubeNodeSelector,
|
|
47
|
+
buildAnnotations,
|
|
48
|
+
makeDefaultRuntime,
|
|
49
|
+
runtimeKubeConfigPath,
|
|
50
|
+
runtimeKubeContextName = getKubeContext(runtimeKubeConfigPath),
|
|
51
|
+
runtimeKubeNamespace = defaultNamespace,
|
|
52
|
+
storageClassName = `${defaultStorageClassPrefix}-${runtimeKubeNamespace}`,
|
|
53
|
+
} = argv;
|
|
54
|
+
|
|
55
|
+
// parse kubeNodeSelector in form key1=value1,key2=value2 to {key1: value1, key2: value2}
|
|
56
|
+
const kubeNodeSelectorObj = {};
|
|
57
|
+
if (kubeNodeSelector) {
|
|
58
|
+
const nsSplitParts = kubeNodeSelector.split(',');
|
|
59
|
+
nsSplitParts.forEach((nsPart) => {
|
|
60
|
+
const [key, value] = nsPart.split('=');
|
|
61
|
+
if (!key || !value) {
|
|
62
|
+
throw new Error('invalid kube-node-selector parameter');
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
kubeNodeSelectorObj[key] = value;
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// create RE in codefresh
|
|
70
|
+
await sdk.cluster.create({
|
|
71
|
+
runtimeEnvironmentName: runtimeName,
|
|
72
|
+
storageClassName: storageClassName || `${defaultStorageClassPrefix}-${runtimeKubeNamespace}`,
|
|
73
|
+
serviceAccount: INSTALLATION_DEFAULTS.RUNTIME_SERVICE_ACCOUNT,
|
|
74
|
+
nodeSelector: kubeNodeSelectorObj,
|
|
75
|
+
annotations: buildAnnotations,
|
|
76
|
+
clusterName: runtimeKubeContextName,
|
|
77
|
+
namespace: runtimeKubeNamespace,
|
|
78
|
+
agent: true,
|
|
79
|
+
});
|
|
80
|
+
console.log(`Runtime environment "${colors.cyan(runtimeName)}" has been created`);
|
|
81
|
+
if (makeDefaultRuntime) {
|
|
82
|
+
const re = await sdk.runtimeEnvs.get({
|
|
83
|
+
name: runtimeName,
|
|
84
|
+
});
|
|
85
|
+
await sdk.runtimeEnvs.setDefault({ account: re.accountId, name: re.metadata.name });
|
|
86
|
+
console.log(`Runtime environment "${colors.cyan(runtimeName)}" has been set as the default runtime`);
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
async function createClusterInPlatform(argv) {
|
|
91
|
+
const {
|
|
92
|
+
clusterServiceAccount,
|
|
93
|
+
runtimeKubeConfigPath,
|
|
94
|
+
runtimeKubeContextName = getKubeContext(runtimeKubeConfigPath),
|
|
95
|
+
runtimeKubeNamespace = defaultNamespace,
|
|
96
|
+
} = argv;
|
|
97
|
+
|
|
98
|
+
try {
|
|
99
|
+
// check if cluster already exists
|
|
100
|
+
const clusters = await sdk.clusters.list() || [];
|
|
101
|
+
// should create cluster if it does not exist already
|
|
102
|
+
const createCluster = !clusters.find((cluster) => cluster.selector === runtimeKubeContextName);
|
|
103
|
+
|
|
104
|
+
// create the cluster in codefresh if does not exists
|
|
105
|
+
if (createCluster) {
|
|
106
|
+
console.log(`Adding cluster "${colors.cyan(runtimeKubeContextName)}" integration to your Codefresh account`);
|
|
107
|
+
try {
|
|
108
|
+
await createClusterCmd.handler({
|
|
109
|
+
'kube-context': runtimeKubeContextName,
|
|
110
|
+
namespace: runtimeKubeNamespace,
|
|
111
|
+
'behind-firewall': true,
|
|
112
|
+
serviceaccount: clusterServiceAccount || 'default',
|
|
113
|
+
terminateProcess: false,
|
|
114
|
+
});
|
|
115
|
+
} catch (error) {
|
|
116
|
+
console.log(`Failed to register cluster on Codefresh, cause: ${error.message}`);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
} catch (error) {
|
|
120
|
+
console.log(`Failed to fetch account clusters, cause: ${error.message}`);
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
async function installRuntimeInCluster(argv, runtimeName) {
|
|
125
|
+
const {
|
|
126
|
+
storageClassName,
|
|
127
|
+
dryRun,
|
|
128
|
+
inCluster,
|
|
129
|
+
kubeNodeSelector,
|
|
130
|
+
setValue,
|
|
131
|
+
setFile,
|
|
132
|
+
attachRuntime,
|
|
133
|
+
dockerRegistry,
|
|
134
|
+
runtimeKubeConfigPath,
|
|
135
|
+
runtimeKubeContextName = getKubeContext(runtimeKubeConfigPath),
|
|
136
|
+
runtimeKubeNamespace = defaultNamespace,
|
|
137
|
+
token = sdk.config.context.token,
|
|
138
|
+
verbose,
|
|
139
|
+
} = argv;
|
|
140
|
+
|
|
141
|
+
const apiHost = sdk.config.context.url;
|
|
142
|
+
|
|
143
|
+
// install RE on cluster
|
|
144
|
+
const runtimeEvents = new ProgressEvents();
|
|
145
|
+
const runtimeFormat = 'downloading runtime installer [{bar}] {percentage}% | {value}/{total}';
|
|
146
|
+
const runtimmrProgressBar = new cliProgress.SingleBar({ stopOnComplete: true, format: runtimeFormat }, cliProgress.Presets.shades_classic);
|
|
147
|
+
let runtimeTotalSize;
|
|
148
|
+
runtimeEvents.onStart((size) => {
|
|
149
|
+
console.log('Downloading runtime installer:\n');
|
|
150
|
+
runtimmrProgressBar.start(size, 0);
|
|
151
|
+
runtimeTotalSize = size;
|
|
152
|
+
});
|
|
153
|
+
runtimeEvents.onProgress((progress) => {
|
|
154
|
+
runtimmrProgressBar.update(progress);
|
|
155
|
+
if (progress >= runtimeTotalSize) {
|
|
156
|
+
console.log('\n');
|
|
157
|
+
}
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
const installRuntimeExitCode = await sdk.runtime.install({
|
|
161
|
+
apiHost,
|
|
162
|
+
name: runtimeName,
|
|
163
|
+
storageClassName: storageClassName && storageClassName.startsWith('dind-local-volumes') ? undefined : storageClassName,
|
|
164
|
+
kubeConfigPath: runtimeKubeConfigPath,
|
|
165
|
+
kubeContextName: runtimeKubeContextName,
|
|
166
|
+
kubeNamespace: runtimeKubeNamespace,
|
|
167
|
+
kubeNodeSelector,
|
|
168
|
+
token,
|
|
169
|
+
inCluster,
|
|
170
|
+
dockerRegistry,
|
|
171
|
+
setValue,
|
|
172
|
+
setFile,
|
|
173
|
+
terminateProcess: !attachRuntime,
|
|
174
|
+
events: runtimeEvents,
|
|
175
|
+
dryRun,
|
|
176
|
+
verbose,
|
|
177
|
+
logFormatting: DefaultLogFormatter,
|
|
178
|
+
});
|
|
179
|
+
// attach RE to agent in codefresh
|
|
180
|
+
|
|
181
|
+
if (installRuntimeExitCode !== 0) {
|
|
182
|
+
throw new Error(`Runtime environment installation failed with exit code: ${installRuntimeExitCode}`);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
async function attachRuntimeToAgent(argv, runtimeName) {
|
|
187
|
+
const {
|
|
188
|
+
agentName,
|
|
189
|
+
runtimeKubeConfigPath,
|
|
190
|
+
runtimeKubeContextName = getKubeContext(runtimeKubeConfigPath),
|
|
191
|
+
runtimeKubeNamespace = defaultNamespace,
|
|
192
|
+
agentKubeConfigPath = runtimeKubeConfigPath,
|
|
193
|
+
agentKubeContextName = runtimeKubeContextName,
|
|
194
|
+
agentKubeNamespace,
|
|
195
|
+
platformOnly,
|
|
196
|
+
} = argv;
|
|
197
|
+
|
|
198
|
+
const attachRuntimeStatusCode = await attachRuntimeCmd.handler({
|
|
199
|
+
agentName,
|
|
200
|
+
runtimeName,
|
|
201
|
+
runtimeKubeConfigPath,
|
|
202
|
+
runtimeKubeContextName,
|
|
203
|
+
runtimeKubeNamespace,
|
|
204
|
+
agentKubeConfigPath,
|
|
205
|
+
agentKubeContextName,
|
|
206
|
+
agentKubeNamespace,
|
|
207
|
+
restartAgent: true,
|
|
208
|
+
platformOnly,
|
|
209
|
+
terminateProcess: false,
|
|
210
|
+
});
|
|
211
|
+
if (attachRuntimeStatusCode !== 0) {
|
|
212
|
+
throw new Error(`Attach runtime failed with exit code ${attachRuntimeStatusCode}`);
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
42
216
|
const installRuntimeCmd = new Command({
|
|
43
217
|
root: false,
|
|
44
218
|
parent: installRoot,
|
|
@@ -49,8 +223,11 @@ const installRuntimeCmd = new Command({
|
|
|
49
223
|
title: 'Install Runtime-Environment',
|
|
50
224
|
weight: 100,
|
|
51
225
|
},
|
|
52
|
-
builder: yargs => yargs
|
|
226
|
+
builder: (yargs) => yargs
|
|
53
227
|
.env('CF_ARG_') // this means that every process.env.CF_ARG_* will be passed to argv
|
|
228
|
+
.option('runtime-name', {
|
|
229
|
+
describe: 'The name of the runtime to install',
|
|
230
|
+
})
|
|
54
231
|
.option('token', {
|
|
55
232
|
describe: 'Agent\'s token',
|
|
56
233
|
})
|
|
@@ -60,12 +237,6 @@ const installRuntimeCmd = new Command({
|
|
|
60
237
|
.option('storage-class-name', {
|
|
61
238
|
describe: 'Set a name of your custom storage class, note: this will not install volume provisioning components',
|
|
62
239
|
})
|
|
63
|
-
.option('runtime-kube-context-name', {
|
|
64
|
-
describe: 'Name of the kubernetes context on which the runtime should be installed (default is current-context) [$CF_ARG_KUBE_CONTEXT_NAME]',
|
|
65
|
-
})
|
|
66
|
-
.option('kube-node-selector', {
|
|
67
|
-
describe: 'The kubernetes node selector "key=value" to be used by runner build resources (default is no node selector) (string)',
|
|
68
|
-
})
|
|
69
240
|
.option('docker-registry', {
|
|
70
241
|
describe: 'The prefix for the container registry that will be used for pulling the required components images. Example: --docker-registry="docker.io"',
|
|
71
242
|
type: 'string',
|
|
@@ -82,20 +253,26 @@ const installRuntimeCmd = new Command({
|
|
|
82
253
|
.option('in-cluster', {
|
|
83
254
|
describe: 'Set flag if runner is been installed from inside a cluster',
|
|
84
255
|
})
|
|
256
|
+
.option('kube-node-selector', {
|
|
257
|
+
describe: 'The kubernetes node selector "key=value" to be used by runner build resources (default is no node selector) (string)',
|
|
258
|
+
})
|
|
259
|
+
.option('runtime-kube-config-path', {
|
|
260
|
+
describe: 'Path to kubeconfig file (default is $HOME/.kube/config)',
|
|
261
|
+
})
|
|
262
|
+
.option('runtime-kube-context-name', {
|
|
263
|
+
describe: 'Name of the kubernetes context on which the runtime should be installed (default is current-context) [$CF_ARG_KUBE_CONTEXT_NAME]',
|
|
264
|
+
})
|
|
85
265
|
.option('runtime-kube-namespace', {
|
|
86
266
|
describe: 'Name of the namespace on which runtime should be installed [$CF_ARG_KUBE_NAMESPACE]',
|
|
87
267
|
})
|
|
88
268
|
.option('build-annotations', {
|
|
89
269
|
describe: 'The kubernetes metadata.annotations as "key=value" to be used by runner build resources (default is no node selector)',
|
|
90
270
|
})
|
|
91
|
-
.option('runtime-kube-config-path', {
|
|
92
|
-
describe: 'Path to kubeconfig file (default is $HOME/.kube/config)',
|
|
93
|
-
})
|
|
94
271
|
.option('attach-runtime', {
|
|
95
272
|
describe: 'if set to true, auto attach runtime to agent (need to provide ....)',
|
|
96
273
|
})
|
|
97
274
|
.option('agent-kube-config-path', {
|
|
98
|
-
describe: 'Path to kubeconfig file for the agent (default is $HOME/.kube/config)',
|
|
275
|
+
describe: 'Path to kubeconfig file for the agent (default is $HOME/.kube/config) (on attach)',
|
|
99
276
|
})
|
|
100
277
|
.option('agent-kube-context-name', {
|
|
101
278
|
describe: 'Agent kubernetes context (on attach)',
|
|
@@ -103,210 +280,61 @@ const installRuntimeCmd = new Command({
|
|
|
103
280
|
.option('agent-kube-namespace', {
|
|
104
281
|
describe: 'Agent\'s namespace (on attach)',
|
|
105
282
|
})
|
|
106
|
-
.option('agent-kube-config-path', {
|
|
107
|
-
describe: 'Path to kubeconfig file for the agent (default is $HOME/.kube/config) (on attach)',
|
|
108
|
-
})
|
|
109
283
|
.option('cluster-service-account', {
|
|
110
284
|
describe: 'service account for cluster default is default',
|
|
111
285
|
})
|
|
112
286
|
.option('make-default-runtime', {
|
|
113
287
|
describe: 'should all pipelines run on the this runtime (default is false)',
|
|
114
288
|
})
|
|
289
|
+
.option('skip-re-creation', {
|
|
290
|
+
description: 'If set to true, will skip runtime creation in the platform',
|
|
291
|
+
})
|
|
115
292
|
.option('skip-cluster-creation', {
|
|
116
293
|
description: 'If set to true, will skip cluster integration creation for this runtime',
|
|
117
294
|
})
|
|
295
|
+
.option('platform-only', {
|
|
296
|
+
describe: 'Set to true to create runtime on the platform side only',
|
|
297
|
+
})
|
|
118
298
|
.option('verbose', {
|
|
119
299
|
describe: 'Print logs',
|
|
120
300
|
}),
|
|
121
301
|
handler: async (argv) => {
|
|
122
302
|
const {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
'set-value': setValue,
|
|
133
|
-
'set-file': setFile,
|
|
134
|
-
verbose,
|
|
135
|
-
'build-annotations': buildAnnotations,
|
|
136
|
-
'attach-runtime': attachRuntime,
|
|
137
|
-
'cluster-service-account': clusterServiceAccount,
|
|
138
|
-
'make-default-runtime': shouldMakeDefaultRe,
|
|
139
|
-
'docker-registry': dockerRegistry,
|
|
140
|
-
terminateProcess,
|
|
141
|
-
} = argv;
|
|
142
|
-
|
|
143
|
-
let {
|
|
144
|
-
'runtime-kube-context-name': kubeContextName,
|
|
145
|
-
'agent-kube-context-name': agentKubeContextName,
|
|
146
|
-
'agent-kube-namespace': agentKubeNamespace,
|
|
147
|
-
'agent-kube-config-path': agentKubeConfigPath,
|
|
148
|
-
'runtime-kube-namespace': kubeNamespace,
|
|
149
|
-
token,
|
|
303
|
+
runtimeName,
|
|
304
|
+
skipReCreation,
|
|
305
|
+
skipClusterCreation,
|
|
306
|
+
attachRuntime,
|
|
307
|
+
runtimeKubeConfigPath,
|
|
308
|
+
runtimeKubeContextName = getKubeContext(runtimeKubeConfigPath),
|
|
309
|
+
runtimeKubeNamespace = defaultNamespace,
|
|
310
|
+
agentKubeNamespace,
|
|
311
|
+
platformOnly,
|
|
150
312
|
} = argv;
|
|
151
313
|
|
|
152
|
-
if (!kubeNamespace) {
|
|
153
|
-
kubeNamespace = defaultNamespace;
|
|
154
|
-
}
|
|
155
314
|
if (attachRuntime && !agentKubeNamespace) {
|
|
156
315
|
throw new Error('agent-kube-namespace is a mandatory parameter');
|
|
157
316
|
}
|
|
158
317
|
|
|
159
|
-
|
|
160
|
-
const kubeNodeSelectorObj = {};
|
|
161
|
-
if (kubeNodeSelector) {
|
|
162
|
-
const nsSplitParts = kubeNodeSelector.split(',');
|
|
163
|
-
nsSplitParts.forEach((nsPart) => {
|
|
164
|
-
const nsRecordSplit = nsPart.split('=');
|
|
165
|
-
if (nsRecordSplit.length !== 2) {
|
|
166
|
-
throw new Error('invalid kube-node-selector parameter');
|
|
167
|
-
}
|
|
168
|
-
kubeNodeSelectorObj[nsRecordSplit[0]] = nsRecordSplit[1];
|
|
169
|
-
});
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
const apiHost = sdk.config.context.url;
|
|
173
|
-
if (!kubeContextName) {
|
|
174
|
-
kubeContextName = getKubeContext(kubeConfigPath);
|
|
175
|
-
}
|
|
176
|
-
const clusterName = kubeContextName || getKubeContext(kubeConfigPath);
|
|
177
|
-
const runtimeName = reName || await newRuntimeName(kubeContextName, kubeNamespace);
|
|
318
|
+
const finalName = runtimeName || await newRuntimeName(runtimeKubeContextName, runtimeKubeNamespace);
|
|
178
319
|
|
|
179
|
-
if (!
|
|
180
|
-
|
|
181
|
-
token = sdk.config.context.token;
|
|
320
|
+
if (!skipReCreation) {
|
|
321
|
+
await createRuntimeInPlatform(argv, finalName);
|
|
182
322
|
}
|
|
183
323
|
|
|
184
|
-
// create RE in codefresh
|
|
185
|
-
if (!skipRuntimeCreation) {
|
|
186
|
-
await sdk.cluster.create({
|
|
187
|
-
namespace: kubeNamespace,
|
|
188
|
-
storageClassName: storageClassName || `${defaultStorageClassPrefix}-${kubeNamespace}`,
|
|
189
|
-
serviceAccount: INSTALLATION_DEFAULTS.RUNTIME_SERVICE_ACCOUNT,
|
|
190
|
-
nodeSelector: kubeNodeSelectorObj,
|
|
191
|
-
annotations: buildAnnotations,
|
|
192
|
-
clusterName,
|
|
193
|
-
runtimeEnvironmentName: runtimeName,
|
|
194
|
-
agent: true,
|
|
195
|
-
});
|
|
196
|
-
console.log(`Runtime environment "${colors.cyan(runtimeName)}" has been created`);
|
|
197
|
-
if (shouldMakeDefaultRe) {
|
|
198
|
-
const re = await sdk.runtimeEnvs.get({
|
|
199
|
-
name: runtimeName,
|
|
200
|
-
});
|
|
201
|
-
await sdk.runtimeEnvs.setDefault({ account: re.accountId, name: re.metadata.name });
|
|
202
|
-
console.log(`Runtime environment "${colors.cyan(runtimeName)}" has been set as the default runtime`);
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
// check if cluster already exists
|
|
207
|
-
let createCluster = false;
|
|
208
324
|
if (!skipClusterCreation) {
|
|
209
|
-
|
|
210
|
-
const clusters = await sdk.clusters.list() || [];
|
|
211
|
-
// should create cluster if it does not exist already
|
|
212
|
-
createCluster = !clusters.find(cluster => cluster.selector === kubeContextName);
|
|
213
|
-
} catch (error) {
|
|
214
|
-
console.log(`Failed to fetch account clusters, cause: ${error.message}`);
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
// create the cluster in codefresh if does not exists
|
|
219
|
-
if (createCluster) {
|
|
220
|
-
console.log(`Adding cluster "${colors.cyan(kubeContextName)}" integration to your Codefresh account`);
|
|
221
|
-
try {
|
|
222
|
-
await createClusterCmd.handler({
|
|
223
|
-
'kube-context': kubeContextName,
|
|
224
|
-
namespace: kubeNamespace,
|
|
225
|
-
'behind-firewall': true,
|
|
226
|
-
serviceaccount: clusterServiceAccount || 'default',
|
|
227
|
-
terminateProcess: false,
|
|
228
|
-
});
|
|
229
|
-
} catch (error) {
|
|
230
|
-
console.log(`Failed to register cluster on Codefresh, cause: ${error.message}`);
|
|
231
|
-
}
|
|
325
|
+
await createClusterInPlatform(argv);
|
|
232
326
|
}
|
|
233
327
|
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
const runtimeFormat = 'downloading runtime installer [{bar}] {percentage}% | {value}/{total}';
|
|
237
|
-
const runtimmrProgressBar = new cliProgress.SingleBar({ stopOnComplete: true, format: runtimeFormat }, cliProgress.Presets.shades_classic);
|
|
238
|
-
let runtimeTotalSize;
|
|
239
|
-
runtimeEvents.onStart((size) => {
|
|
240
|
-
console.log('Downloading runtime installer:\n');
|
|
241
|
-
runtimmrProgressBar.start(size, 0);
|
|
242
|
-
runtimeTotalSize = size;
|
|
243
|
-
});
|
|
244
|
-
runtimeEvents.onProgress((progress) => {
|
|
245
|
-
runtimmrProgressBar.update(progress);
|
|
246
|
-
if (progress >= runtimeTotalSize) {
|
|
247
|
-
console.log('\n');
|
|
248
|
-
}
|
|
249
|
-
});
|
|
250
|
-
|
|
251
|
-
const installRuntimeExitCode = await sdk.runtime.install({
|
|
252
|
-
apiHost,
|
|
253
|
-
name: runtimeName,
|
|
254
|
-
kubeContextName,
|
|
255
|
-
kubeNamespace,
|
|
256
|
-
token,
|
|
257
|
-
dryRun,
|
|
258
|
-
inCluster,
|
|
259
|
-
kubeConfigPath,
|
|
260
|
-
dockerRegistry,
|
|
261
|
-
verbose,
|
|
262
|
-
kubeNodeSelector,
|
|
263
|
-
setValue,
|
|
264
|
-
setFile,
|
|
265
|
-
terminateProcess: !attachRuntime,
|
|
266
|
-
events: runtimeEvents,
|
|
267
|
-
storageClassName: storageClassName && storageClassName.startsWith('dind-local-volumes') ? undefined : storageClassName,
|
|
268
|
-
logFormatting: DefaultLogFormatter,
|
|
269
|
-
});
|
|
270
|
-
// attach RE to agent in codefresh
|
|
271
|
-
|
|
272
|
-
if (installRuntimeExitCode !== 0) {
|
|
273
|
-
throw new Error(`Runtime environment installation failed with exit code: ${installRuntimeExitCode}`);
|
|
328
|
+
if (!platformOnly) {
|
|
329
|
+
await installRuntimeInCluster(argv, finalName);
|
|
274
330
|
}
|
|
275
331
|
|
|
276
332
|
if (attachRuntime) {
|
|
277
|
-
|
|
278
|
-
if (!agentKubeNamespace) {
|
|
279
|
-
agentKubeNamespace = kubeNamespace;
|
|
280
|
-
}
|
|
281
|
-
if (!agentKubeContextName) {
|
|
282
|
-
agentKubeContextName = kubeContextName;
|
|
283
|
-
}
|
|
284
|
-
if (!agentKubeConfigPath) {
|
|
285
|
-
agentKubeConfigPath = kubeConfigPath;
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
const attachRuntimeStatusCode = await attachRuntimeCmd.handler({
|
|
289
|
-
'agent-name': agentName,
|
|
290
|
-
'runtime-name': runtimeName,
|
|
291
|
-
'runtime-kube-context-name': kubeContextName,
|
|
292
|
-
'runtime-kube-namespace': kubeNamespace,
|
|
293
|
-
'runtime-kube-config-path': kubeConfigPath,
|
|
294
|
-
'agent-kube-context-name': agentKubeContextName,
|
|
295
|
-
'agent-kube-namespace': agentKubeNamespace,
|
|
296
|
-
'agent-kube-config-path': agentKubeConfigPath,
|
|
297
|
-
'restart-agent': true,
|
|
298
|
-
terminateProcess,
|
|
299
|
-
});
|
|
300
|
-
if (attachRuntimeStatusCode !== 0) {
|
|
301
|
-
throw new Error(`Attach runtime failed with exit code ${attachRuntimeStatusCode}`);
|
|
302
|
-
} else {
|
|
303
|
-
return runtimeName;
|
|
304
|
-
}
|
|
333
|
+
await attachRuntimeToAgent(argv, finalName);
|
|
305
334
|
} else {
|
|
306
335
|
console.log('Please run agent attach in order to link agent and runtime');
|
|
307
336
|
}
|
|
308
337
|
},
|
|
309
338
|
});
|
|
310
339
|
|
|
311
|
-
|
|
312
340
|
module.exports = installRuntimeCmd;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"codefresh":{"analyze":{},"completion":{},"completions":{"alias":"completion"},"tag":{},"untag":{},"offline-logs":{"ensure-index":{},"offload-to-collection":{},"offload-to-file":{}},"run":{"__optionHandlers":["../commands/pipeline/run.completion.js"]},"add":{"repository":{},"repo":{"alias":"repository"}},"annotate":{"image":{},"img":{"alias":"image"}},"patch":{"__optionHandlers":["../commands/root/apply.completion.js"],"agent":{"__optionHandlers":["../commands/root/apply.completion.js"]},"board":{"__optionHandlers":["../commands/root/apply.completion.js"]},"project":{"__optionHandlers":["../commands/root/apply.completion.js"]},"runtime-environments":{"__optionHandlers":["../commands/root/apply.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"section":{"__optionHandlers":["../commands/root/apply.completion.js"]},"system-runtime-environments":{"__optionHandlers":["../commands/root/apply.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/apply.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/apply.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/apply.completion.js"]},"context":{"__optionHandlers":["../commands/root/apply.completion.js"]},"ctx":{"alias":"context"}},"auth":{"create-context":{},"current-context":{},"get-contexts":{},"use-context":{}},"components":{"download":{},"update":{}},"create":{"__optionHandlers":["../commands/root/create.completion.js"],"agent":{"__optionHandlers":["../commands/root/create.completion.js"]},"clusters":{"__optionHandlers":["../commands/root/create.completion.js"]},"cluster":{"alias":"clusters"},"annotation":{"__optionHandlers":["../commands/root/create.completion.js"]},"board":{"__optionHandlers":["../commands/root/create.completion.js"]},"composition":{"__optionHandlers":["../commands/composition/create.completion.js","../commands/root/create.completion.js"]},"com":{"alias":"composition"},"project":{"__optionHandlers":["../commands/root/create.completion.js"]},"runtime-environments":{"__optionHandlers":["../commands/root/create.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"section":{"__optionHandlers":["../commands/root/create.completion.js"]},"teams":{"__optionHandlers":["../commands/root/create.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"token":{"__optionHandlers":["../commands/root/create.completion.js"]},"helm-repo":{"__optionHandlers":["../commands/root/create.completion.js"]},"registry":{"__optionHandlers":["../commands/root/create.completion.js"],"standard":{"__optionHandlers":["../commands/root/create.completion.js"]}},"workflow-data-item":{"__optionHandlers":["../commands/root/create.completion.js"]},"wdi":{"alias":"workflow-data-item"},"trigger":{"__optionHandlers":["../commands/root/create.completion.js"]},"t":{"alias":"trigger"},"trigger-event":{"__optionHandlers":["../commands/root/create.completion.js"]},"te":{"alias":"trigger-event"},"context":{"__optionHandlers":["../commands/root/create.completion.js"],"config":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret-yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"git":{"__optionHandlers":["../commands/root/create.completion.js"],"bitbucket":{"__optionHandlers":["../commands/root/create.completion.js"]},"github":{"__optionHandlers":["../commands/root/create.completion.js"]},"gitlab":{"__optionHandlers":["../commands/root/create.completion.js"]},"stash":{"__optionHandlers":["../commands/root/create.completion.js"]}},"helm-repository":{"__optionHandlers":["../commands/root/create.completion.js"],"http":{"__optionHandlers":["../commands/root/create.completion.js"]},"s3":{"__optionHandlers":["../commands/root/create.completion.js"]}},"secret-store":{"__optionHandlers":["../commands/root/create.completion.js"],"hashicorp-vault":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes-runtime":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes":{"__optionHandlers":["../commands/root/create.completion.js"]}}},"ctx":{"alias":"context","config":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret-yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"git":{"__optionHandlers":["../commands/root/create.completion.js"],"bitbucket":{"__optionHandlers":["../commands/root/create.completion.js"]},"github":{"__optionHandlers":["../commands/root/create.completion.js"]},"gitlab":{"__optionHandlers":["../commands/root/create.completion.js"]},"stash":{"__optionHandlers":["../commands/root/create.completion.js"]}},"helm-repository":{"__optionHandlers":["../commands/root/create.completion.js"],"http":{"__optionHandlers":["../commands/root/create.completion.js"]},"s3":{"__optionHandlers":["../commands/root/create.completion.js"]}},"secret-store":{"__optionHandlers":["../commands/root/create.completion.js"],"hashicorp-vault":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes-runtime":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes":{"__optionHandlers":["../commands/root/create.completion.js"]}}}},"delete":{"__optionHandlers":["../commands/root/delete.completion.js"],"agent":{"__optionHandlers":["../commands/root/delete.completion.js"]},"annotation":{"__optionHandlers":["../commands/root/delete.completion.js"]},"board":{"__optionHandlers":["../commands/root/delete.completion.js"]},"cluster":{"__optionHandlers":["../commands/root/delete.completion.js"]},"clusters":{"alias":"cluster"},"composition":{"__optionHandlers":["../commands/root/delete.completion.js"]},"com":{"alias":"composition"},"environment":{"__optionHandlers":["../commands/root/delete.completion.js"]},"env":{"alias":"environment"},"pipeline":{"__optionHandlers":["../commands/root/delete.completion.js"]},"pip":{"alias":"pipeline"},"project":{"__optionHandlers":["../commands/root/delete.completion.js"]},"repository":{"__optionHandlers":["../commands/root/delete.completion.js"]},"repo":{"alias":"repository"},"runtime-environments":{"__optionHandlers":["../commands/root/delete.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"step-type":{"__optionHandlers":["../commands/root/delete.completion.js"]},"section":{"__optionHandlers":["../commands/root/delete.completion.js"]},"system-runtime-environments":{"__optionHandlers":["../commands/root/delete.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/delete.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/delete.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/delete.completion.js"]},"registry":{"__optionHandlers":["../commands/root/delete.completion.js"]},"trigger":{"__optionHandlers":["../commands/root/delete.completion.js"]},"t":{"alias":"trigger"},"trigger-event":{"__optionHandlers":["../commands/root/delete.completion.js"]},"te":{"alias":"trigger-event"},"context":{"__optionHandlers":["../commands/root/delete.completion.js"]},"ctx":{"alias":"context"}},"diff":{"__optionHandlers":["../commands/root/diff.completion.js"],"runtime-environments":{"__optionHandlers":["../commands/root/diff.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"system-runtime-environments":{"__optionHandlers":["../commands/root/diff.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"}},"download":{"audit":{}},"generate":{"image-pull-secret":{}},"get":{"__optionHandlers":["../commands/root/get.completion.js"],"runtime-environment-base-images":{"__optionHandlers":["../commands/root/get.completion.js"]},"re-base-images":{"alias":"runtime-environment-base-images"},"agents":{"__optionHandlers":["../commands/root/get.completion.js"]},"agent":{"alias":"agents"},"annotation":{"__optionHandlers":["../commands/root/get.completion.js"]},"boards":{"__optionHandlers":["../commands/root/get.completion.js"]},"board":{"alias":"boards"},"clusters":{"__optionHandlers":["../commands/root/get.completion.js"]},"cluster":{"alias":"clusters"},"compositions":{"__optionHandlers":["../commands/root/get.completion.js"]},"com":{"alias":"compositions"},"composition":{"alias":"compositions"},"environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"env":{"alias":"environments"},"environment":{"alias":"environments"},"images":{"__optionHandlers":["../commands/root/get.completion.js"]},"img":{"alias":"images"},"image":{"alias":"images"},"pipelines":{"__positionalHandler":"../commands/pipeline/get.completion.js","__optionHandlers":["../commands/root/get.completion.js"]},"pip":{"alias":"pipelines"},"pipeline":{"alias":"pipelines"},"projects":{"__optionHandlers":["../commands/root/get.completion.js"]},"project":{"alias":"projects"},"repository":{"__optionHandlers":["../commands/root/get.completion.js"]},"repo":{"alias":"repository"},"runtime-environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"step-types":{"__positionalHandler":"../commands/step/get.completion.js","__optionHandlers":["../commands/root/get.completion.js"]},"step-type":{"alias":"step-types"},"sections":{"__optionHandlers":["../commands/root/get.completion.js"]},"section":{"alias":"sections"},"system-runtime-environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/get.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/get.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/get.completion.js"]},"registry":{"__optionHandlers":["../commands/root/get.completion.js"]},"builds":{"__optionHandlers":["../commands/root/get.completion.js"]},"build":{"alias":"builds"},"workflow-data-item":{"__optionHandlers":["../commands/root/get.completion.js"]},"wdi":{"alias":"workflow-data-item"},"triggers":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger":{"alias":"triggers"},"t":{"alias":"triggers"},"trigger-events":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger-event":{"alias":"trigger-events"},"te":{"alias":"trigger-events"},"trigger-types":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger-type":{"alias":"trigger-types"},"tt":{"alias":"trigger-types"},"contexts":{"__optionHandlers":["../commands/root/get.completion.js"]},"ctx":{"alias":"contexts"},"context":{"alias":"contexts"}},"install":{"runtime":{},"agent":{},"app-proxy":{},"monitor":{},"gitops":{}},"replace":{"__optionHandlers":["../commands/root/replace.completion.js"],"composition":{"__optionHandlers":["../commands/composition/replace.completion.js","../commands/root/replace.completion.js"]},"com":{"alias":"composition"}},"runner":{"delete":{},"execute-test-pipeline":{},"info":{},"init":{},"upgrade":{}},"synchronize":{"teams":{},"team":{"alias":"teams"},"tm":{"alias":"teams"}},"uninstall":{"agent":{},"app-proxy":{},"runtime":{},"monitor":{},"gitops":{}},"upgrade":{"app-proxy":{},"gitops":{}},"validate":{"__positionalHandler":"../commands/root/validate.completion.js"},"version":{},"attach":{},"cli-config":{"get":{},"help":{},"profile":{},"set":{}},"set-helm-config":{},"install-chart":{},"helm-promotion":{},"delete-release":{},"rollback-release":{},"test-release":{},"approve":{},"deny":{},"logs":{},"restart":{},"terminate":{},"wait":{}}}
|
|
1
|
+
{"codefresh":{"analyze":{},"completion":{},"completions":{"alias":"completion"},"tag":{},"untag":{},"offline-logs":{"ensure-index":{},"offload-to-collection":{},"offload-to-file":{}},"run":{"__optionHandlers":["../commands/pipeline/run.completion.js"]},"add":{"repository":{},"repo":{"alias":"repository"}},"annotate":{"image":{},"img":{"alias":"image"}},"patch":{"__optionHandlers":["../commands/root/apply.completion.js"],"agent":{"__optionHandlers":["../commands/root/apply.completion.js"]},"board":{"__optionHandlers":["../commands/root/apply.completion.js"]},"project":{"__optionHandlers":["../commands/root/apply.completion.js"]},"section":{"__optionHandlers":["../commands/root/apply.completion.js"]},"runtime-environments":{"__optionHandlers":["../commands/root/apply.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"system-runtime-environments":{"__optionHandlers":["../commands/root/apply.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/apply.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/apply.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/apply.completion.js"]},"context":{"__optionHandlers":["../commands/root/apply.completion.js"]},"ctx":{"alias":"context"}},"auth":{"create-context":{},"current-context":{},"get-contexts":{},"use-context":{}},"components":{"download":{},"update":{}},"create":{"__optionHandlers":["../commands/root/create.completion.js"],"agent":{"__optionHandlers":["../commands/root/create.completion.js"]},"clusters":{"__optionHandlers":["../commands/root/create.completion.js"]},"cluster":{"alias":"clusters"},"annotation":{"__optionHandlers":["../commands/root/create.completion.js"]},"board":{"__optionHandlers":["../commands/root/create.completion.js"]},"composition":{"__optionHandlers":["../commands/composition/create.completion.js","../commands/root/create.completion.js"]},"com":{"alias":"composition"},"project":{"__optionHandlers":["../commands/root/create.completion.js"]},"section":{"__optionHandlers":["../commands/root/create.completion.js"]},"runtime-environments":{"__optionHandlers":["../commands/root/create.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"teams":{"__optionHandlers":["../commands/root/create.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"token":{"__optionHandlers":["../commands/root/create.completion.js"]},"helm-repo":{"__optionHandlers":["../commands/root/create.completion.js"]},"registry":{"__optionHandlers":["../commands/root/create.completion.js"],"standard":{"__optionHandlers":["../commands/root/create.completion.js"]}},"trigger":{"__optionHandlers":["../commands/root/create.completion.js"]},"t":{"alias":"trigger"},"trigger-event":{"__optionHandlers":["../commands/root/create.completion.js"]},"te":{"alias":"trigger-event"},"workflow-data-item":{"__optionHandlers":["../commands/root/create.completion.js"]},"wdi":{"alias":"workflow-data-item"},"context":{"__optionHandlers":["../commands/root/create.completion.js"],"config":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret-yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"git":{"__optionHandlers":["../commands/root/create.completion.js"],"bitbucket":{"__optionHandlers":["../commands/root/create.completion.js"]},"github":{"__optionHandlers":["../commands/root/create.completion.js"]},"gitlab":{"__optionHandlers":["../commands/root/create.completion.js"]},"stash":{"__optionHandlers":["../commands/root/create.completion.js"]}},"helm-repository":{"__optionHandlers":["../commands/root/create.completion.js"],"http":{"__optionHandlers":["../commands/root/create.completion.js"]},"s3":{"__optionHandlers":["../commands/root/create.completion.js"]}},"secret-store":{"__optionHandlers":["../commands/root/create.completion.js"],"hashicorp-vault":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes-runtime":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes":{"__optionHandlers":["../commands/root/create.completion.js"]}}},"ctx":{"alias":"context","config":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret":{"__optionHandlers":["../commands/root/create.completion.js"]},"secret-yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"yaml":{"__optionHandlers":["../commands/root/create.completion.js"]},"git":{"__optionHandlers":["../commands/root/create.completion.js"],"bitbucket":{"__optionHandlers":["../commands/root/create.completion.js"]},"github":{"__optionHandlers":["../commands/root/create.completion.js"]},"gitlab":{"__optionHandlers":["../commands/root/create.completion.js"]},"stash":{"__optionHandlers":["../commands/root/create.completion.js"]}},"helm-repository":{"__optionHandlers":["../commands/root/create.completion.js"],"http":{"__optionHandlers":["../commands/root/create.completion.js"]},"s3":{"__optionHandlers":["../commands/root/create.completion.js"]}},"secret-store":{"__optionHandlers":["../commands/root/create.completion.js"],"hashicorp-vault":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes-runtime":{"__optionHandlers":["../commands/root/create.completion.js"]},"kubernetes":{"__optionHandlers":["../commands/root/create.completion.js"]}}}},"delete":{"__optionHandlers":["../commands/root/delete.completion.js"],"agent":{"__optionHandlers":["../commands/root/delete.completion.js"]},"annotation":{"__optionHandlers":["../commands/root/delete.completion.js"]},"board":{"__optionHandlers":["../commands/root/delete.completion.js"]},"cluster":{"__optionHandlers":["../commands/root/delete.completion.js"]},"clusters":{"alias":"cluster"},"composition":{"__optionHandlers":["../commands/root/delete.completion.js"]},"com":{"alias":"composition"},"environment":{"__optionHandlers":["../commands/root/delete.completion.js"]},"env":{"alias":"environment"},"pipeline":{"__optionHandlers":["../commands/root/delete.completion.js"]},"pip":{"alias":"pipeline"},"project":{"__optionHandlers":["../commands/root/delete.completion.js"]},"repository":{"__optionHandlers":["../commands/root/delete.completion.js"]},"repo":{"alias":"repository"},"section":{"__optionHandlers":["../commands/root/delete.completion.js"]},"step-type":{"__optionHandlers":["../commands/root/delete.completion.js"]},"runtime-environments":{"__optionHandlers":["../commands/root/delete.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"system-runtime-environments":{"__optionHandlers":["../commands/root/delete.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/delete.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/delete.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/delete.completion.js"]},"registry":{"__optionHandlers":["../commands/root/delete.completion.js"]},"trigger":{"__optionHandlers":["../commands/root/delete.completion.js"]},"t":{"alias":"trigger"},"trigger-event":{"__optionHandlers":["../commands/root/delete.completion.js"]},"te":{"alias":"trigger-event"},"context":{"__optionHandlers":["../commands/root/delete.completion.js"]},"ctx":{"alias":"context"}},"diff":{"__optionHandlers":["../commands/root/diff.completion.js"],"runtime-environments":{"__optionHandlers":["../commands/root/diff.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"system-runtime-environments":{"__optionHandlers":["../commands/root/diff.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"}},"download":{"audit":{}},"generate":{"image-pull-secret":{}},"get":{"__optionHandlers":["../commands/root/get.completion.js"],"runtime-environment-base-images":{"__optionHandlers":["../commands/root/get.completion.js"]},"re-base-images":{"alias":"runtime-environment-base-images"},"agents":{"__optionHandlers":["../commands/root/get.completion.js"]},"agent":{"alias":"agents"},"annotation":{"__optionHandlers":["../commands/root/get.completion.js"]},"boards":{"__optionHandlers":["../commands/root/get.completion.js"]},"board":{"alias":"boards"},"clusters":{"__optionHandlers":["../commands/root/get.completion.js"]},"cluster":{"alias":"clusters"},"compositions":{"__optionHandlers":["../commands/root/get.completion.js"]},"com":{"alias":"compositions"},"composition":{"alias":"compositions"},"environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"env":{"alias":"environments"},"environment":{"alias":"environments"},"images":{"__optionHandlers":["../commands/root/get.completion.js"]},"img":{"alias":"images"},"image":{"alias":"images"},"pipelines":{"__positionalHandler":"../commands/pipeline/get.completion.js","__optionHandlers":["../commands/root/get.completion.js"]},"pip":{"alias":"pipelines"},"pipeline":{"alias":"pipelines"},"projects":{"__optionHandlers":["../commands/root/get.completion.js"]},"project":{"alias":"projects"},"repository":{"__optionHandlers":["../commands/root/get.completion.js"]},"repo":{"alias":"repository"},"sections":{"__optionHandlers":["../commands/root/get.completion.js"]},"section":{"alias":"sections"},"step-types":{"__positionalHandler":"../commands/step/get.completion.js","__optionHandlers":["../commands/root/get.completion.js"]},"step-type":{"alias":"step-types"},"runtime-environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"re":{"alias":"runtime-environments"},"runtime-environment":{"alias":"runtime-environments"},"system-runtime-environments":{"__optionHandlers":["../commands/root/get.completion.js"]},"sys-re":{"alias":"system-runtime-environments"},"system-runtime-environment":{"alias":"system-runtime-environments"},"teams":{"__optionHandlers":["../commands/root/get.completion.js"]},"team":{"alias":"teams"},"tm":{"alias":"teams"},"tokens":{"__optionHandlers":["../commands/root/get.completion.js"]},"token":{"alias":"tokens"},"helm-repo":{"__optionHandlers":["../commands/root/get.completion.js"]},"registry":{"__optionHandlers":["../commands/root/get.completion.js"]},"triggers":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger":{"alias":"triggers"},"t":{"alias":"triggers"},"trigger-events":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger-event":{"alias":"trigger-events"},"te":{"alias":"trigger-events"},"trigger-types":{"__optionHandlers":["../commands/root/get.completion.js"]},"trigger-type":{"alias":"trigger-types"},"tt":{"alias":"trigger-types"},"builds":{"__optionHandlers":["../commands/root/get.completion.js"]},"build":{"alias":"builds"},"workflow-data-item":{"__optionHandlers":["../commands/root/get.completion.js"]},"wdi":{"alias":"workflow-data-item"},"contexts":{"__optionHandlers":["../commands/root/get.completion.js"]},"ctx":{"alias":"contexts"},"context":{"alias":"contexts"}},"install":{"runtime":{},"agent":{},"app-proxy":{},"monitor":{},"gitops":{}},"replace":{"__optionHandlers":["../commands/root/replace.completion.js"],"composition":{"__optionHandlers":["../commands/composition/replace.completion.js","../commands/root/replace.completion.js"]},"com":{"alias":"composition"}},"runner":{"delete":{},"execute-test-pipeline":{},"info":{},"init":{},"upgrade":{}},"synchronize":{"teams":{},"team":{"alias":"teams"},"tm":{"alias":"teams"}},"uninstall":{"agent":{},"app-proxy":{},"runtime":{},"monitor":{},"gitops":{}},"upgrade":{"app-proxy":{},"gitops":{}},"validate":{"__positionalHandler":"../commands/root/validate.completion.js"},"version":{},"attach":{},"cli-config":{"get":{},"help":{},"profile":{},"set":{}},"set-helm-config":{},"install-chart":{},"helm-promotion":{},"delete-release":{},"rollback-release":{},"test-release":{},"approve":{},"deny":{},"logs":{},"restart":{},"terminate":{},"wait":{}}}
|