@catladder/cli 0.0.0-main-864c4fe3 → 0.0.0-main-ee41ef85
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/dist/bundles/catenv/index.js +77 -36
- package/dist/bundles/cli/index.js +77 -36
- package/dist/pipeline/src/build/artifacts/createBuildJobArtifact.js +3 -1
- package/dist/pipeline/src/build/artifacts/createBuildJobArtifact.js.map +1 -1
- package/dist/pipeline/src/build/base/index.d.ts +2 -3
- package/dist/pipeline/src/build/base/index.js.map +1 -1
- package/dist/pipeline/src/build/cache/getAllCacheConfigsFromConfig.js +6 -4
- package/dist/pipeline/src/build/cache/getAllCacheConfigsFromConfig.js.map +1 -1
- package/dist/pipeline/src/build/custom/buildJob.d.ts +2 -2
- package/dist/pipeline/src/build/custom/buildJob.js.map +1 -1
- package/dist/pipeline/src/build/custom/index.d.ts +2 -2
- package/dist/pipeline/src/build/custom/index.js.map +1 -1
- package/dist/pipeline/src/build/custom/testJob.d.ts +2 -2
- package/dist/pipeline/src/build/custom/testJob.js.map +1 -1
- package/dist/pipeline/src/build/docker.d.ts +4 -4
- package/dist/pipeline/src/build/docker.js.map +1 -1
- package/dist/pipeline/src/build/index.d.ts +2 -2
- package/dist/pipeline/src/build/index.js.map +1 -1
- package/dist/pipeline/src/build/node/buildJob.d.ts +5 -3
- package/dist/pipeline/src/build/node/buildJob.js.map +1 -1
- package/dist/pipeline/src/build/node/index.d.ts +4 -4
- package/dist/pipeline/src/build/node/index.js.map +1 -1
- package/dist/pipeline/src/build/node/meteor.d.ts +2 -2
- package/dist/pipeline/src/build/node/meteor.js.map +1 -1
- package/dist/pipeline/src/build/node/yarn.d.ts +1 -1
- package/dist/pipeline/src/build/node/yarn.js +3 -1
- package/dist/pipeline/src/build/node/yarn.js.map +1 -1
- package/dist/pipeline/src/build/rails/build.d.ts +2 -2
- package/dist/pipeline/src/build/rails/build.js.map +1 -1
- package/dist/pipeline/src/build/rails/index.d.ts +2 -2
- package/dist/pipeline/src/build/rails/index.js.map +1 -1
- package/dist/pipeline/src/build/sbom.d.ts +2 -2
- package/dist/pipeline/src/build/sbom.js.map +1 -1
- package/dist/pipeline/src/context/createComponentContext.js +17 -6
- package/dist/pipeline/src/context/createComponentContext.js.map +1 -1
- package/dist/pipeline/src/context/getLabels.js +3 -1
- package/dist/pipeline/src/context/getLabels.js.map +1 -1
- package/dist/pipeline/src/deploy/cloudRun/createJobs/cloudRunJobs.js +2 -2
- package/dist/pipeline/src/deploy/cloudRun/createJobs/cloudRunJobs.js.map +1 -1
- package/dist/pipeline/src/deploy/cloudRun/createJobs/cloudRunServices.js +11 -6
- package/dist/pipeline/src/deploy/cloudRun/createJobs/cloudRunServices.js.map +1 -1
- package/dist/pipeline/src/deploy/cloudRun/createJobs/execute/onDeploy.d.ts +1 -2
- package/dist/pipeline/src/deploy/cloudRun/createJobs/execute/onDeploy.js +3 -10
- package/dist/pipeline/src/deploy/cloudRun/createJobs/execute/onDeploy.js.map +1 -1
- package/dist/pipeline/src/deploy/cloudRun/utils/getJobOrServiceArgs.d.ts +2 -0
- package/dist/pipeline/src/deploy/cloudRun/utils/getJobOrServiceArgs.js +12 -0
- package/dist/pipeline/src/deploy/cloudRun/utils/getJobOrServiceArgs.js.map +1 -0
- package/dist/pipeline/src/deploy/kubernetes/kubeValues.d.ts +2 -2
- package/dist/pipeline/src/deploy/kubernetes/kubeValues.js +3 -1
- package/dist/pipeline/src/deploy/kubernetes/kubeValues.js.map +1 -1
- package/dist/pipeline/src/deploy/sbom.js +4 -3
- package/dist/pipeline/src/deploy/sbom.js.map +1 -1
- package/dist/pipeline/src/deploy/types/googleCloudRun.d.ts +10 -0
- package/dist/pipeline/src/pipeline/createJobsForComponent.js +3 -1
- package/dist/pipeline/src/pipeline/createJobsForComponent.js.map +1 -1
- package/dist/pipeline/src/types/config.d.ts +1 -1
- package/dist/pipeline/src/types/context.d.ts +6 -1
- package/dist/pipeline/src/types/context.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1232,7 +1232,9 @@ exports.createBuildJobArtifacts = createBuildJobArtifacts;
|
|
|
1232
1232
|
const getArtifactsPathForComponent = (c, additionalPaths) => {
|
|
1233
1233
|
var _a, _b;
|
|
1234
1234
|
return (_b = [
|
|
1235
|
-
...(
|
|
1235
|
+
...(c.build.type !== "disabled"
|
|
1236
|
+
? ((_a = c.build.config.artifactsPaths) !== null && _a !== void 0 ? _a : [])
|
|
1237
|
+
: []),
|
|
1236
1238
|
...(additionalPaths !== null && additionalPaths !== void 0 ? additionalPaths : []),
|
|
1237
1239
|
]) === null || _b === void 0 ? void 0 : _b.flatMap((artifact) => c.build
|
|
1238
1240
|
// in theory, we only need "direct",
|
|
@@ -1608,10 +1610,12 @@ const getAllCacheConfigsFromConfig = (context, configWithCache) => {
|
|
|
1608
1610
|
// we would probably need to introduce a path to the right config property (build-->test or so)
|
|
1609
1611
|
context.components.flatMap((componentContext) => {
|
|
1610
1612
|
var _a;
|
|
1611
|
-
return
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1613
|
+
return componentContext.build.type !== "disabled"
|
|
1614
|
+
? ((_a = (0, index_1.ensureArray)(componentContext.build.config.cache).map((c) => ({
|
|
1615
|
+
...c,
|
|
1616
|
+
baseDir: componentContext.build.dir,
|
|
1617
|
+
}))) !== null && _a !== void 0 ? _a : [])
|
|
1618
|
+
: [];
|
|
1615
1619
|
})
|
|
1616
1620
|
: []),
|
|
1617
1621
|
];
|
|
@@ -2379,7 +2383,9 @@ const ensureNodeVersion = (context) => (0, gitlab_1.collapseableSection)("nodein
|
|
|
2379
2383
|
]);
|
|
2380
2384
|
exports.ensureNodeVersion = ensureNodeVersion;
|
|
2381
2385
|
const getYarnInstall = (context, options) => {
|
|
2382
|
-
const postInstall = context.type !== "workspace" &&
|
|
2386
|
+
const postInstall = context.type !== "workspace" &&
|
|
2387
|
+
context.build.type !== "disabled" &&
|
|
2388
|
+
"postInstall" in context.build.config
|
|
2383
2389
|
? context.build.config.postInstall
|
|
2384
2390
|
: null;
|
|
2385
2391
|
return [
|
|
@@ -2837,19 +2843,23 @@ const createComponentContext = async (ctx) => {
|
|
|
2837
2843
|
const packageManagerInfo = await (0, packageManager_1.getPackageManagerInfoForComponent)(ctx.config, ctx.componentName);
|
|
2838
2844
|
const envContext = (0, getEnvironmentContext_1.getEnvironmentContext)(ctx);
|
|
2839
2845
|
const componentConfigWithoutDefaults = envContext.envConfigRaw;
|
|
2840
|
-
const resolvedBuildType =
|
|
2841
|
-
?
|
|
2842
|
-
: (
|
|
2843
|
-
|
|
2846
|
+
const resolvedBuildType = componentConfigWithoutDefaults.build === false
|
|
2847
|
+
? false
|
|
2848
|
+
: (0, build_1.isStandaloneBuildConfig)(componentConfigWithoutDefaults.build)
|
|
2849
|
+
? componentConfigWithoutDefaults.build.type
|
|
2850
|
+
: (_a = ctx.config.builds) === null || _a === void 0 ? void 0 : _a[componentConfigWithoutDefaults.build.from].type;
|
|
2851
|
+
if (resolvedBuildType === undefined) {
|
|
2844
2852
|
throw new Error("build type not found, is the build config correct?");
|
|
2845
2853
|
}
|
|
2846
2854
|
const defaults = componentConfigWithoutDefaults.deploy
|
|
2847
2855
|
? {
|
|
2848
|
-
build:
|
|
2856
|
+
build: resolvedBuildType &&
|
|
2857
|
+
build_1.BUILD_TYPES[resolvedBuildType].defaults(envContext),
|
|
2849
2858
|
deploy: deploy_1.DEPLOY_TYPES[componentConfigWithoutDefaults.deploy.type].defaults(envContext),
|
|
2850
2859
|
}
|
|
2851
2860
|
: {
|
|
2852
|
-
build:
|
|
2861
|
+
build: resolvedBuildType &&
|
|
2862
|
+
build_1.BUILD_TYPES[resolvedBuildType].defaults(envContext),
|
|
2853
2863
|
deploy: {},
|
|
2854
2864
|
};
|
|
2855
2865
|
const componentConfig = (0, utils_1.mergeWithMergingArrays)(defaults, componentConfigWithoutDefaults);
|
|
@@ -2867,6 +2877,13 @@ const createComponentContext = async (ctx) => {
|
|
|
2867
2877
|
};
|
|
2868
2878
|
const _getBuildContext = () => {
|
|
2869
2879
|
var _a;
|
|
2880
|
+
if (build === false) {
|
|
2881
|
+
return {
|
|
2882
|
+
type: "disabled",
|
|
2883
|
+
getComponentDirs,
|
|
2884
|
+
dir,
|
|
2885
|
+
};
|
|
2886
|
+
}
|
|
2870
2887
|
if ((0, build_1.isStandaloneBuildConfig)(build)) {
|
|
2871
2888
|
return {
|
|
2872
2889
|
dir: dir,
|
|
@@ -3283,7 +3300,9 @@ const getLabels = (context) => {
|
|
|
3283
3300
|
"app-name": sanitize(context.fullConfig.appName),
|
|
3284
3301
|
"env-type": sanitize(context.environment.envType),
|
|
3285
3302
|
"env-name": sanitize(context.env),
|
|
3286
|
-
"build-type":
|
|
3303
|
+
"build-type": context.build.type === "disabled"
|
|
3304
|
+
? "disabled"
|
|
3305
|
+
: sanitize(context.build.buildType),
|
|
3287
3306
|
...((_b = (_a = context.fullConfig.meta) === null || _a === void 0 ? void 0 : _a.labels) !== null && _b !== void 0 ? _b : {}),
|
|
3288
3307
|
};
|
|
3289
3308
|
return labels;
|
|
@@ -3877,7 +3896,7 @@ const jobName_1 = __nccwpck_require__(9626);
|
|
|
3877
3896
|
const common_1 = __nccwpck_require__(3325);
|
|
3878
3897
|
const constants_1 = __nccwpck_require__(8865);
|
|
3879
3898
|
const volumes_1 = __nccwpck_require__(847);
|
|
3880
|
-
const
|
|
3899
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(1741);
|
|
3881
3900
|
const getDeleteJobsScripts = (context) => {
|
|
3882
3901
|
const commonArgs = (0, common_1.getCommonCloudRunArgs)(context);
|
|
3883
3902
|
const commonArgsString = (0, createArgsString_1.createArgsString)(commonArgs);
|
|
@@ -3897,7 +3916,7 @@ const getJobCreateScripts = (context) => (0, exports.getCloudRunJobsWithNames)(c
|
|
|
3897
3916
|
const { image: commonImage, project, region, ...deployArgs } = (0, common_1.getCommonDeployArgs)(context);
|
|
3898
3917
|
const commonDeployArgsString = (0, createArgsString_1.createArgsString)({
|
|
3899
3918
|
command: `"${commandArray.join(",")}"`,
|
|
3900
|
-
args: (0,
|
|
3919
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(job.args),
|
|
3901
3920
|
labels: `"${(0, common_1.makeLabelString)((0, getLabels_1.getLabels)(context))},cloud-run-job-name=$current_job_name"`,
|
|
3902
3921
|
image: `"${(_a = job.image) !== null && _a !== void 0 ? _a : commonImage}"`,
|
|
3903
3922
|
project,
|
|
@@ -3957,17 +3976,20 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
3957
3976
|
exports.getServiceDeleteScript = exports.getServiceDeployScript = void 0;
|
|
3958
3977
|
const getLabels_1 = __nccwpck_require__(920);
|
|
3959
3978
|
const createArgsString_1 = __nccwpck_require__(9598);
|
|
3979
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(1741);
|
|
3960
3980
|
const getServiceName_1 = __nccwpck_require__(8128);
|
|
3961
3981
|
const common_1 = __nccwpck_require__(3325);
|
|
3962
3982
|
const constants_1 = __nccwpck_require__(8865);
|
|
3963
3983
|
const volumes_1 = __nccwpck_require__(847);
|
|
3964
3984
|
const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
3965
|
-
var _a, _b, _c, _d, _e;
|
|
3985
|
+
var _a, _b, _c, _d, _e, _f;
|
|
3966
3986
|
const commonDeployArgs = (0, common_1.getCommonDeployArgs)(context);
|
|
3967
3987
|
const serviceName = (0, getServiceName_1.getServiceName)(context);
|
|
3968
3988
|
const customConfig = service !== true ? service : undefined;
|
|
3969
3989
|
const command = service !== true
|
|
3970
|
-
? ((_a = service === null || service === void 0 ? void 0 : service.command) !== null && _a !== void 0 ? _a : context.build.
|
|
3990
|
+
? ((_a = service === null || service === void 0 ? void 0 : service.command) !== null && _a !== void 0 ? _a : (context.build.type !== "disabled"
|
|
3991
|
+
? context.build.config.startCommand
|
|
3992
|
+
: undefined))
|
|
3971
3993
|
: undefined;
|
|
3972
3994
|
const commandArray = command
|
|
3973
3995
|
? Array.isArray(command)
|
|
@@ -3978,14 +4000,16 @@ const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
|
3978
4000
|
const argsString = (0, createArgsString_1.createArgsString)({
|
|
3979
4001
|
// command as empty string resets it to default (uses the image's entrypoint)
|
|
3980
4002
|
command: commandArray ? '"' + commandArray.join(",") + '"' : '""',
|
|
4003
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(customConfig === null || customConfig === void 0 ? void 0 : customConfig.args),
|
|
3981
4004
|
...commonDeployArgs,
|
|
4005
|
+
image: (_b = customConfig === null || customConfig === void 0 ? void 0 : customConfig.image) !== null && _b !== void 0 ? _b : commonDeployArgs.image,
|
|
3982
4006
|
labels: (0, common_1.makeLabelString)({
|
|
3983
4007
|
...(0, getLabels_1.getLabels)(context),
|
|
3984
4008
|
"cloud-run-service-name": fullServiceName,
|
|
3985
4009
|
}),
|
|
3986
4010
|
"env-vars-file": constants_1.ENV_VARS_FILENAME,
|
|
3987
|
-
"min-instances": (
|
|
3988
|
-
"max-instances": (
|
|
4011
|
+
"min-instances": (_c = customConfig === null || customConfig === void 0 ? void 0 : customConfig.minInstances) !== null && _c !== void 0 ? _c : 0,
|
|
4012
|
+
"max-instances": (_d = customConfig === null || customConfig === void 0 ? void 0 : customConfig.maxInstances) !== null && _d !== void 0 ? _d : 100,
|
|
3989
4013
|
"cpu-throttling": (customConfig === null || customConfig === void 0 ? void 0 : customConfig.noCpuThrottling) !== true,
|
|
3990
4014
|
cpu: customConfig === null || customConfig === void 0 ? void 0 : customConfig.cpu,
|
|
3991
4015
|
memory: customConfig === null || customConfig === void 0 ? void 0 : customConfig.memory,
|
|
@@ -3995,8 +4019,8 @@ const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
|
3995
4019
|
network: customConfig === null || customConfig === void 0 ? void 0 : customConfig.network,
|
|
3996
4020
|
subnet: customConfig === null || customConfig === void 0 ? void 0 : customConfig.subnet,
|
|
3997
4021
|
"use-http2": customConfig === null || customConfig === void 0 ? void 0 : customConfig.http2,
|
|
3998
|
-
"allow-unauthenticated": (
|
|
3999
|
-
ingress: (
|
|
4022
|
+
"allow-unauthenticated": (_e = customConfig === null || customConfig === void 0 ? void 0 : customConfig.allowUnauthenticated) !== null && _e !== void 0 ? _e : true,
|
|
4023
|
+
ingress: (_f = customConfig === null || customConfig === void 0 ? void 0 : customConfig.ingress) !== null && _f !== void 0 ? _f : "all",
|
|
4000
4024
|
"cpu-boost": true,
|
|
4001
4025
|
"execution-environment": customConfig === null || customConfig === void 0 ? void 0 : customConfig.executionEnvironment,
|
|
4002
4026
|
gpu: customConfig === null || customConfig === void 0 ? void 0 : customConfig.gpu,
|
|
@@ -4116,8 +4140,9 @@ exports.ENV_VARS_FILENAME = "____envvars.yaml";
|
|
|
4116
4140
|
"use strict";
|
|
4117
4141
|
|
|
4118
4142
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
4119
|
-
exports.
|
|
4143
|
+
exports.getOnDeployExecuteScript = void 0;
|
|
4120
4144
|
const createArgsString_1 = __nccwpck_require__(9598);
|
|
4145
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(1741);
|
|
4121
4146
|
const jobName_1 = __nccwpck_require__(9626);
|
|
4122
4147
|
const cloudRunJobs_1 = __nccwpck_require__(1224);
|
|
4123
4148
|
const common_1 = __nccwpck_require__(3325);
|
|
@@ -4185,19 +4210,11 @@ const getJobRunScriptForExecute = (context, { jobName, config }) => {
|
|
|
4185
4210
|
const argString = (0, createArgsString_1.createArgsString)({
|
|
4186
4211
|
...commonArgs,
|
|
4187
4212
|
wait: waitForCompletion === true ? true : undefined,
|
|
4188
|
-
args: (0,
|
|
4213
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(config.args),
|
|
4189
4214
|
});
|
|
4190
4215
|
const fullJobName = (0, jobName_1.getFullJobName)(context, jobName);
|
|
4191
4216
|
return `${(0, common_1.gcloudRunCmd)()} jobs execute ${fullJobName.toString()} ${argString}`;
|
|
4192
4217
|
};
|
|
4193
|
-
const getCloudRunJobArgsArg = (args) => {
|
|
4194
|
-
return args !== undefined
|
|
4195
|
-
? args.length > 0
|
|
4196
|
-
? args === null || args === void 0 ? void 0 : args.map((arg) => `"${arg}"`).join(",")
|
|
4197
|
-
: ""
|
|
4198
|
-
: undefined;
|
|
4199
|
-
};
|
|
4200
|
-
exports.getCloudRunJobArgsArg = getCloudRunJobArgsArg;
|
|
4201
4218
|
//# sourceMappingURL=onDeploy.js.map
|
|
4202
4219
|
|
|
4203
4220
|
/***/ }),
|
|
@@ -4742,6 +4759,25 @@ exports.gcloudServiceAccountLoginCommands = gcloudServiceAccountLoginCommands;
|
|
|
4742
4759
|
|
|
4743
4760
|
/***/ }),
|
|
4744
4761
|
|
|
4762
|
+
/***/ 1741:
|
|
4763
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
4764
|
+
|
|
4765
|
+
"use strict";
|
|
4766
|
+
|
|
4767
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
4768
|
+
exports.getCloudRunServiceOrJobArgsArg = void 0;
|
|
4769
|
+
const getCloudRunServiceOrJobArgsArg = (args) => {
|
|
4770
|
+
return args !== undefined
|
|
4771
|
+
? args.length > 0
|
|
4772
|
+
? args === null || args === void 0 ? void 0 : args.map((arg) => `"${arg}"`).join(",")
|
|
4773
|
+
: ""
|
|
4774
|
+
: undefined;
|
|
4775
|
+
};
|
|
4776
|
+
exports.getCloudRunServiceOrJobArgsArg = getCloudRunServiceOrJobArgsArg;
|
|
4777
|
+
//# sourceMappingURL=getJobOrServiceArgs.js.map
|
|
4778
|
+
|
|
4779
|
+
/***/ }),
|
|
4780
|
+
|
|
4745
4781
|
/***/ 8128:
|
|
4746
4782
|
/***/ ((__unused_webpack_module, exports) => {
|
|
4747
4783
|
|
|
@@ -5284,7 +5320,9 @@ const createAppConfig = (context, application) => {
|
|
|
5284
5320
|
const { healthRoute, command, ...rest } = application !== null && application !== void 0 ? application : {};
|
|
5285
5321
|
return (0, utils_1.mergeWithMergingArrays)({
|
|
5286
5322
|
host: context.environment.envVars.HOSTNAME,
|
|
5287
|
-
command: command !== null && command !== void 0 ? command : context.build.
|
|
5323
|
+
command: command !== null && command !== void 0 ? command : (context.build.type !== "disabled"
|
|
5324
|
+
? context.build.config.startCommand
|
|
5325
|
+
: undefined),
|
|
5288
5326
|
livenessProbe: {
|
|
5289
5327
|
httpGet: {
|
|
5290
5328
|
path: healthRoute !== null && healthRoute !== void 0 ? healthRoute : "__health",
|
|
@@ -5464,9 +5502,10 @@ exports.getDependencyTrackDeleteScript = exports.getDependencyTrackUploadScript
|
|
|
5464
5502
|
const BashExpression_1 = __nccwpck_require__(2376);
|
|
5465
5503
|
const sbom_1 = __nccwpck_require__(7038);
|
|
5466
5504
|
const context_1 = __nccwpck_require__(1724);
|
|
5467
|
-
const sbomDeactivated = (context) =>
|
|
5468
|
-
context
|
|
5469
|
-
|
|
5505
|
+
const sbomDeactivated = (context) => context.build.type === "disabled" ||
|
|
5506
|
+
((0, context_1.componentContextIsStandaloneBuild)(context) &&
|
|
5507
|
+
context.build.config.type === "custom" &&
|
|
5508
|
+
context.build.config.sbom === false);
|
|
5470
5509
|
exports.sbomDeactivated = sbomDeactivated;
|
|
5471
5510
|
const getDependencyTrackUploadScript = (context) => {
|
|
5472
5511
|
return (0, exports.sbomDeactivated)(context)
|
|
@@ -5759,7 +5798,9 @@ const getCustomJobs = (context) => {
|
|
|
5759
5798
|
return injectDefaultVarsInCustomJobs(context, rawJobs);
|
|
5760
5799
|
};
|
|
5761
5800
|
const createJobsForComponentContext = (context) => {
|
|
5762
|
-
const buildJobs =
|
|
5801
|
+
const buildJobs = context.build.type !== "disabled"
|
|
5802
|
+
? build_1.BUILD_TYPES[context.build.buildType].jobs(context)
|
|
5803
|
+
: [];
|
|
5763
5804
|
const deployJobs = context.componentConfig.deploy !== false
|
|
5764
5805
|
? deploy_1.DEPLOY_TYPES[context.componentConfig.deploy.type].jobs(context)
|
|
5765
5806
|
: [];
|
|
@@ -4250,7 +4250,9 @@ exports.createBuildJobArtifacts = createBuildJobArtifacts;
|
|
|
4250
4250
|
const getArtifactsPathForComponent = (c, additionalPaths) => {
|
|
4251
4251
|
var _a, _b;
|
|
4252
4252
|
return (_b = [
|
|
4253
|
-
...(
|
|
4253
|
+
...(c.build.type !== "disabled"
|
|
4254
|
+
? ((_a = c.build.config.artifactsPaths) !== null && _a !== void 0 ? _a : [])
|
|
4255
|
+
: []),
|
|
4254
4256
|
...(additionalPaths !== null && additionalPaths !== void 0 ? additionalPaths : []),
|
|
4255
4257
|
]) === null || _b === void 0 ? void 0 : _b.flatMap((artifact) => c.build
|
|
4256
4258
|
// in theory, we only need "direct",
|
|
@@ -4626,10 +4628,12 @@ const getAllCacheConfigsFromConfig = (context, configWithCache) => {
|
|
|
4626
4628
|
// we would probably need to introduce a path to the right config property (build-->test or so)
|
|
4627
4629
|
context.components.flatMap((componentContext) => {
|
|
4628
4630
|
var _a;
|
|
4629
|
-
return
|
|
4630
|
-
|
|
4631
|
-
|
|
4632
|
-
|
|
4631
|
+
return componentContext.build.type !== "disabled"
|
|
4632
|
+
? ((_a = (0, index_1.ensureArray)(componentContext.build.config.cache).map((c) => ({
|
|
4633
|
+
...c,
|
|
4634
|
+
baseDir: componentContext.build.dir,
|
|
4635
|
+
}))) !== null && _a !== void 0 ? _a : [])
|
|
4636
|
+
: [];
|
|
4633
4637
|
})
|
|
4634
4638
|
: []),
|
|
4635
4639
|
];
|
|
@@ -5397,7 +5401,9 @@ const ensureNodeVersion = (context) => (0, gitlab_1.collapseableSection)("nodein
|
|
|
5397
5401
|
]);
|
|
5398
5402
|
exports.ensureNodeVersion = ensureNodeVersion;
|
|
5399
5403
|
const getYarnInstall = (context, options) => {
|
|
5400
|
-
const postInstall = context.type !== "workspace" &&
|
|
5404
|
+
const postInstall = context.type !== "workspace" &&
|
|
5405
|
+
context.build.type !== "disabled" &&
|
|
5406
|
+
"postInstall" in context.build.config
|
|
5401
5407
|
? context.build.config.postInstall
|
|
5402
5408
|
: null;
|
|
5403
5409
|
return [
|
|
@@ -5855,19 +5861,23 @@ const createComponentContext = async (ctx) => {
|
|
|
5855
5861
|
const packageManagerInfo = await (0, packageManager_1.getPackageManagerInfoForComponent)(ctx.config, ctx.componentName);
|
|
5856
5862
|
const envContext = (0, getEnvironmentContext_1.getEnvironmentContext)(ctx);
|
|
5857
5863
|
const componentConfigWithoutDefaults = envContext.envConfigRaw;
|
|
5858
|
-
const resolvedBuildType =
|
|
5859
|
-
?
|
|
5860
|
-
: (
|
|
5861
|
-
|
|
5864
|
+
const resolvedBuildType = componentConfigWithoutDefaults.build === false
|
|
5865
|
+
? false
|
|
5866
|
+
: (0, build_1.isStandaloneBuildConfig)(componentConfigWithoutDefaults.build)
|
|
5867
|
+
? componentConfigWithoutDefaults.build.type
|
|
5868
|
+
: (_a = ctx.config.builds) === null || _a === void 0 ? void 0 : _a[componentConfigWithoutDefaults.build.from].type;
|
|
5869
|
+
if (resolvedBuildType === undefined) {
|
|
5862
5870
|
throw new Error("build type not found, is the build config correct?");
|
|
5863
5871
|
}
|
|
5864
5872
|
const defaults = componentConfigWithoutDefaults.deploy
|
|
5865
5873
|
? {
|
|
5866
|
-
build:
|
|
5874
|
+
build: resolvedBuildType &&
|
|
5875
|
+
build_1.BUILD_TYPES[resolvedBuildType].defaults(envContext),
|
|
5867
5876
|
deploy: deploy_1.DEPLOY_TYPES[componentConfigWithoutDefaults.deploy.type].defaults(envContext),
|
|
5868
5877
|
}
|
|
5869
5878
|
: {
|
|
5870
|
-
build:
|
|
5879
|
+
build: resolvedBuildType &&
|
|
5880
|
+
build_1.BUILD_TYPES[resolvedBuildType].defaults(envContext),
|
|
5871
5881
|
deploy: {},
|
|
5872
5882
|
};
|
|
5873
5883
|
const componentConfig = (0, utils_1.mergeWithMergingArrays)(defaults, componentConfigWithoutDefaults);
|
|
@@ -5885,6 +5895,13 @@ const createComponentContext = async (ctx) => {
|
|
|
5885
5895
|
};
|
|
5886
5896
|
const _getBuildContext = () => {
|
|
5887
5897
|
var _a;
|
|
5898
|
+
if (build === false) {
|
|
5899
|
+
return {
|
|
5900
|
+
type: "disabled",
|
|
5901
|
+
getComponentDirs,
|
|
5902
|
+
dir,
|
|
5903
|
+
};
|
|
5904
|
+
}
|
|
5888
5905
|
if ((0, build_1.isStandaloneBuildConfig)(build)) {
|
|
5889
5906
|
return {
|
|
5890
5907
|
dir: dir,
|
|
@@ -6301,7 +6318,9 @@ const getLabels = (context) => {
|
|
|
6301
6318
|
"app-name": sanitize(context.fullConfig.appName),
|
|
6302
6319
|
"env-type": sanitize(context.environment.envType),
|
|
6303
6320
|
"env-name": sanitize(context.env),
|
|
6304
|
-
"build-type":
|
|
6321
|
+
"build-type": context.build.type === "disabled"
|
|
6322
|
+
? "disabled"
|
|
6323
|
+
: sanitize(context.build.buildType),
|
|
6305
6324
|
...((_b = (_a = context.fullConfig.meta) === null || _a === void 0 ? void 0 : _a.labels) !== null && _b !== void 0 ? _b : {}),
|
|
6306
6325
|
};
|
|
6307
6326
|
return labels;
|
|
@@ -6895,7 +6914,7 @@ const jobName_1 = __nccwpck_require__(9626);
|
|
|
6895
6914
|
const common_1 = __nccwpck_require__(73325);
|
|
6896
6915
|
const constants_1 = __nccwpck_require__(38865);
|
|
6897
6916
|
const volumes_1 = __nccwpck_require__(60847);
|
|
6898
|
-
const
|
|
6917
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(61741);
|
|
6899
6918
|
const getDeleteJobsScripts = (context) => {
|
|
6900
6919
|
const commonArgs = (0, common_1.getCommonCloudRunArgs)(context);
|
|
6901
6920
|
const commonArgsString = (0, createArgsString_1.createArgsString)(commonArgs);
|
|
@@ -6915,7 +6934,7 @@ const getJobCreateScripts = (context) => (0, exports.getCloudRunJobsWithNames)(c
|
|
|
6915
6934
|
const { image: commonImage, project, region, ...deployArgs } = (0, common_1.getCommonDeployArgs)(context);
|
|
6916
6935
|
const commonDeployArgsString = (0, createArgsString_1.createArgsString)({
|
|
6917
6936
|
command: `"${commandArray.join(",")}"`,
|
|
6918
|
-
args: (0,
|
|
6937
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(job.args),
|
|
6919
6938
|
labels: `"${(0, common_1.makeLabelString)((0, getLabels_1.getLabels)(context))},cloud-run-job-name=$current_job_name"`,
|
|
6920
6939
|
image: `"${(_a = job.image) !== null && _a !== void 0 ? _a : commonImage}"`,
|
|
6921
6940
|
project,
|
|
@@ -6975,17 +6994,20 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
6975
6994
|
exports.getServiceDeleteScript = exports.getServiceDeployScript = void 0;
|
|
6976
6995
|
const getLabels_1 = __nccwpck_require__(30920);
|
|
6977
6996
|
const createArgsString_1 = __nccwpck_require__(49598);
|
|
6997
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(61741);
|
|
6978
6998
|
const getServiceName_1 = __nccwpck_require__(38128);
|
|
6979
6999
|
const common_1 = __nccwpck_require__(73325);
|
|
6980
7000
|
const constants_1 = __nccwpck_require__(38865);
|
|
6981
7001
|
const volumes_1 = __nccwpck_require__(60847);
|
|
6982
7002
|
const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
6983
|
-
var _a, _b, _c, _d, _e;
|
|
7003
|
+
var _a, _b, _c, _d, _e, _f;
|
|
6984
7004
|
const commonDeployArgs = (0, common_1.getCommonDeployArgs)(context);
|
|
6985
7005
|
const serviceName = (0, getServiceName_1.getServiceName)(context);
|
|
6986
7006
|
const customConfig = service !== true ? service : undefined;
|
|
6987
7007
|
const command = service !== true
|
|
6988
|
-
? ((_a = service === null || service === void 0 ? void 0 : service.command) !== null && _a !== void 0 ? _a : context.build.
|
|
7008
|
+
? ((_a = service === null || service === void 0 ? void 0 : service.command) !== null && _a !== void 0 ? _a : (context.build.type !== "disabled"
|
|
7009
|
+
? context.build.config.startCommand
|
|
7010
|
+
: undefined))
|
|
6989
7011
|
: undefined;
|
|
6990
7012
|
const commandArray = command
|
|
6991
7013
|
? Array.isArray(command)
|
|
@@ -6996,14 +7018,16 @@ const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
|
6996
7018
|
const argsString = (0, createArgsString_1.createArgsString)({
|
|
6997
7019
|
// command as empty string resets it to default (uses the image's entrypoint)
|
|
6998
7020
|
command: commandArray ? '"' + commandArray.join(",") + '"' : '""',
|
|
7021
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(customConfig === null || customConfig === void 0 ? void 0 : customConfig.args),
|
|
6999
7022
|
...commonDeployArgs,
|
|
7023
|
+
image: (_b = customConfig === null || customConfig === void 0 ? void 0 : customConfig.image) !== null && _b !== void 0 ? _b : commonDeployArgs.image,
|
|
7000
7024
|
labels: (0, common_1.makeLabelString)({
|
|
7001
7025
|
...(0, getLabels_1.getLabels)(context),
|
|
7002
7026
|
"cloud-run-service-name": fullServiceName,
|
|
7003
7027
|
}),
|
|
7004
7028
|
"env-vars-file": constants_1.ENV_VARS_FILENAME,
|
|
7005
|
-
"min-instances": (
|
|
7006
|
-
"max-instances": (
|
|
7029
|
+
"min-instances": (_c = customConfig === null || customConfig === void 0 ? void 0 : customConfig.minInstances) !== null && _c !== void 0 ? _c : 0,
|
|
7030
|
+
"max-instances": (_d = customConfig === null || customConfig === void 0 ? void 0 : customConfig.maxInstances) !== null && _d !== void 0 ? _d : 100,
|
|
7007
7031
|
"cpu-throttling": (customConfig === null || customConfig === void 0 ? void 0 : customConfig.noCpuThrottling) !== true,
|
|
7008
7032
|
cpu: customConfig === null || customConfig === void 0 ? void 0 : customConfig.cpu,
|
|
7009
7033
|
memory: customConfig === null || customConfig === void 0 ? void 0 : customConfig.memory,
|
|
@@ -7013,8 +7037,8 @@ const getServiceDeployScript = (context, service, nameSuffix) => {
|
|
|
7013
7037
|
network: customConfig === null || customConfig === void 0 ? void 0 : customConfig.network,
|
|
7014
7038
|
subnet: customConfig === null || customConfig === void 0 ? void 0 : customConfig.subnet,
|
|
7015
7039
|
"use-http2": customConfig === null || customConfig === void 0 ? void 0 : customConfig.http2,
|
|
7016
|
-
"allow-unauthenticated": (
|
|
7017
|
-
ingress: (
|
|
7040
|
+
"allow-unauthenticated": (_e = customConfig === null || customConfig === void 0 ? void 0 : customConfig.allowUnauthenticated) !== null && _e !== void 0 ? _e : true,
|
|
7041
|
+
ingress: (_f = customConfig === null || customConfig === void 0 ? void 0 : customConfig.ingress) !== null && _f !== void 0 ? _f : "all",
|
|
7018
7042
|
"cpu-boost": true,
|
|
7019
7043
|
"execution-environment": customConfig === null || customConfig === void 0 ? void 0 : customConfig.executionEnvironment,
|
|
7020
7044
|
gpu: customConfig === null || customConfig === void 0 ? void 0 : customConfig.gpu,
|
|
@@ -7134,8 +7158,9 @@ exports.ENV_VARS_FILENAME = "____envvars.yaml";
|
|
|
7134
7158
|
"use strict";
|
|
7135
7159
|
|
|
7136
7160
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
7137
|
-
exports.
|
|
7161
|
+
exports.getOnDeployExecuteScript = void 0;
|
|
7138
7162
|
const createArgsString_1 = __nccwpck_require__(49598);
|
|
7163
|
+
const getJobOrServiceArgs_1 = __nccwpck_require__(61741);
|
|
7139
7164
|
const jobName_1 = __nccwpck_require__(9626);
|
|
7140
7165
|
const cloudRunJobs_1 = __nccwpck_require__(61224);
|
|
7141
7166
|
const common_1 = __nccwpck_require__(73325);
|
|
@@ -7203,19 +7228,11 @@ const getJobRunScriptForExecute = (context, { jobName, config }) => {
|
|
|
7203
7228
|
const argString = (0, createArgsString_1.createArgsString)({
|
|
7204
7229
|
...commonArgs,
|
|
7205
7230
|
wait: waitForCompletion === true ? true : undefined,
|
|
7206
|
-
args: (0,
|
|
7231
|
+
args: (0, getJobOrServiceArgs_1.getCloudRunServiceOrJobArgsArg)(config.args),
|
|
7207
7232
|
});
|
|
7208
7233
|
const fullJobName = (0, jobName_1.getFullJobName)(context, jobName);
|
|
7209
7234
|
return `${(0, common_1.gcloudRunCmd)()} jobs execute ${fullJobName.toString()} ${argString}`;
|
|
7210
7235
|
};
|
|
7211
|
-
const getCloudRunJobArgsArg = (args) => {
|
|
7212
|
-
return args !== undefined
|
|
7213
|
-
? args.length > 0
|
|
7214
|
-
? args === null || args === void 0 ? void 0 : args.map((arg) => `"${arg}"`).join(",")
|
|
7215
|
-
: ""
|
|
7216
|
-
: undefined;
|
|
7217
|
-
};
|
|
7218
|
-
exports.getCloudRunJobArgsArg = getCloudRunJobArgsArg;
|
|
7219
7236
|
//# sourceMappingURL=onDeploy.js.map
|
|
7220
7237
|
|
|
7221
7238
|
/***/ }),
|
|
@@ -7760,6 +7777,25 @@ exports.gcloudServiceAccountLoginCommands = gcloudServiceAccountLoginCommands;
|
|
|
7760
7777
|
|
|
7761
7778
|
/***/ }),
|
|
7762
7779
|
|
|
7780
|
+
/***/ 61741:
|
|
7781
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
7782
|
+
|
|
7783
|
+
"use strict";
|
|
7784
|
+
|
|
7785
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
7786
|
+
exports.getCloudRunServiceOrJobArgsArg = void 0;
|
|
7787
|
+
const getCloudRunServiceOrJobArgsArg = (args) => {
|
|
7788
|
+
return args !== undefined
|
|
7789
|
+
? args.length > 0
|
|
7790
|
+
? args === null || args === void 0 ? void 0 : args.map((arg) => `"${arg}"`).join(",")
|
|
7791
|
+
: ""
|
|
7792
|
+
: undefined;
|
|
7793
|
+
};
|
|
7794
|
+
exports.getCloudRunServiceOrJobArgsArg = getCloudRunServiceOrJobArgsArg;
|
|
7795
|
+
//# sourceMappingURL=getJobOrServiceArgs.js.map
|
|
7796
|
+
|
|
7797
|
+
/***/ }),
|
|
7798
|
+
|
|
7763
7799
|
/***/ 38128:
|
|
7764
7800
|
/***/ ((__unused_webpack_module, exports) => {
|
|
7765
7801
|
|
|
@@ -8302,7 +8338,9 @@ const createAppConfig = (context, application) => {
|
|
|
8302
8338
|
const { healthRoute, command, ...rest } = application !== null && application !== void 0 ? application : {};
|
|
8303
8339
|
return (0, utils_1.mergeWithMergingArrays)({
|
|
8304
8340
|
host: context.environment.envVars.HOSTNAME,
|
|
8305
|
-
command: command !== null && command !== void 0 ? command : context.build.
|
|
8341
|
+
command: command !== null && command !== void 0 ? command : (context.build.type !== "disabled"
|
|
8342
|
+
? context.build.config.startCommand
|
|
8343
|
+
: undefined),
|
|
8306
8344
|
livenessProbe: {
|
|
8307
8345
|
httpGet: {
|
|
8308
8346
|
path: healthRoute !== null && healthRoute !== void 0 ? healthRoute : "__health",
|
|
@@ -8482,9 +8520,10 @@ exports.getDependencyTrackDeleteScript = exports.getDependencyTrackUploadScript
|
|
|
8482
8520
|
const BashExpression_1 = __nccwpck_require__(42376);
|
|
8483
8521
|
const sbom_1 = __nccwpck_require__(37038);
|
|
8484
8522
|
const context_1 = __nccwpck_require__(61724);
|
|
8485
|
-
const sbomDeactivated = (context) =>
|
|
8486
|
-
context
|
|
8487
|
-
|
|
8523
|
+
const sbomDeactivated = (context) => context.build.type === "disabled" ||
|
|
8524
|
+
((0, context_1.componentContextIsStandaloneBuild)(context) &&
|
|
8525
|
+
context.build.config.type === "custom" &&
|
|
8526
|
+
context.build.config.sbom === false);
|
|
8488
8527
|
exports.sbomDeactivated = sbomDeactivated;
|
|
8489
8528
|
const getDependencyTrackUploadScript = (context) => {
|
|
8490
8529
|
return (0, exports.sbomDeactivated)(context)
|
|
@@ -8777,7 +8816,9 @@ const getCustomJobs = (context) => {
|
|
|
8777
8816
|
return injectDefaultVarsInCustomJobs(context, rawJobs);
|
|
8778
8817
|
};
|
|
8779
8818
|
const createJobsForComponentContext = (context) => {
|
|
8780
|
-
const buildJobs =
|
|
8819
|
+
const buildJobs = context.build.type !== "disabled"
|
|
8820
|
+
? build_1.BUILD_TYPES[context.build.buildType].jobs(context)
|
|
8821
|
+
: [];
|
|
8781
8822
|
const deployJobs = context.componentConfig.deploy !== false
|
|
8782
8823
|
? deploy_1.DEPLOY_TYPES[context.componentConfig.deploy.type].jobs(context)
|
|
8783
8824
|
: [];
|
|
@@ -32,7 +32,9 @@ exports.createBuildJobArtifacts = createBuildJobArtifacts;
|
|
|
32
32
|
const getArtifactsPathForComponent = (c, additionalPaths) => {
|
|
33
33
|
var _a, _b;
|
|
34
34
|
return (_b = [
|
|
35
|
-
...(
|
|
35
|
+
...(c.build.type !== "disabled"
|
|
36
|
+
? ((_a = c.build.config.artifactsPaths) !== null && _a !== void 0 ? _a : [])
|
|
37
|
+
: []),
|
|
36
38
|
...(additionalPaths !== null && additionalPaths !== void 0 ? additionalPaths : []),
|
|
37
39
|
]) === null || _b === void 0 ? void 0 : _b.flatMap((artifact) => c.build
|
|
38
40
|
// in theory, we only need "direct",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createBuildJobArtifact.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/artifacts/createBuildJobArtifact.ts"],"names":[],"mappings":";;;AAAA,+BAA4B;AAC5B,uCAIqB;AAErB,mCAA8B;AAC9B,qDAA2E;AAEpE,MAAM,uBAAuB,GAAG,CACrC,OAAgB,EACW,EAAE;;IAC7B,MAAM,KAAK,GACT,OAAO,CAAC,IAAI,KAAK,WAAW;QAC1B,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,4BAA4B,CAAC,CAAC,CAAC,CAAC;QACpE,CAAC,CAAC,4BAA4B,CAAC,OAAO,EAAE,CAAC,mBAAmB,CAAC,CAAC,CAAC;IACnE,mCAAmC;IACnC,MAAM,OAAO,GACX,OAAO,CAAC,IAAI,KAAK,WAAW;QAC1B,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,0BAA0B,CAAC,CAAC,CAAC,CAAC;QAClE,CAAC,CAAC,0BAA0B,CAAC,OAAO,CAAC,CAAC;IAC1C,OAAO;QACL,KAAK,EAAE,IAAA,aAAI,EAAC,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QACrD,GAAG,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC1C,SAAS,EAAE,OAAO;QAClB,IAAI,EAAE,QAAQ;QACd,OAAO;QACL,kDAAkD;QAClD,OAAO,CAAC,IAAI,KAAK,WAAW,IAAI,IAAA,yCAAiC,EAAC,OAAO,CAAC;YACxE,CAAC,CAAC;gBACE,KAAK,EAAE,MAAA,MAAA,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,gBAAgB,0CAAE,KAAK,0CAAE,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAC7D,IAAA,WAAI,EAAC,OAAO,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,CAC3B;aACF;YACH,CAAC,CAAC,EAAE;KACT,CAAC;AACJ,CAAC,CAAC;AA3BW,QAAA,uBAAuB,2BA2BlC;AACF,MAAM,4BAA4B,GAAG,CACnC,CAAmB,EACnB,eAA0B,EAChB,EAAE;;IACZ,OAAO,MAAA;QACL,GAAG,CAAC,MAAA,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,cAAc,mCAAI,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"createBuildJobArtifact.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/artifacts/createBuildJobArtifact.ts"],"names":[],"mappings":";;;AAAA,+BAA4B;AAC5B,uCAIqB;AAErB,mCAA8B;AAC9B,qDAA2E;AAEpE,MAAM,uBAAuB,GAAG,CACrC,OAAgB,EACW,EAAE;;IAC7B,MAAM,KAAK,GACT,OAAO,CAAC,IAAI,KAAK,WAAW;QAC1B,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,4BAA4B,CAAC,CAAC,CAAC,CAAC;QACpE,CAAC,CAAC,4BAA4B,CAAC,OAAO,EAAE,CAAC,mBAAmB,CAAC,CAAC,CAAC;IACnE,mCAAmC;IACnC,MAAM,OAAO,GACX,OAAO,CAAC,IAAI,KAAK,WAAW;QAC1B,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,0BAA0B,CAAC,CAAC,CAAC,CAAC;QAClE,CAAC,CAAC,0BAA0B,CAAC,OAAO,CAAC,CAAC;IAC1C,OAAO;QACL,KAAK,EAAE,IAAA,aAAI,EAAC,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QACrD,GAAG,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAC1C,SAAS,EAAE,OAAO;QAClB,IAAI,EAAE,QAAQ;QACd,OAAO;QACL,kDAAkD;QAClD,OAAO,CAAC,IAAI,KAAK,WAAW,IAAI,IAAA,yCAAiC,EAAC,OAAO,CAAC;YACxE,CAAC,CAAC;gBACE,KAAK,EAAE,MAAA,MAAA,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,gBAAgB,0CAAE,KAAK,0CAAE,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAC7D,IAAA,WAAI,EAAC,OAAO,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,CAC3B;aACF;YACH,CAAC,CAAC,EAAE;KACT,CAAC;AACJ,CAAC,CAAC;AA3BW,QAAA,uBAAuB,2BA2BlC;AACF,MAAM,4BAA4B,GAAG,CACnC,CAAmB,EACnB,eAA0B,EAChB,EAAE;;IACZ,OAAO,MAAA;QACL,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,KAAK,UAAU;YAC7B,CAAC,CAAC,CAAC,MAAA,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,cAAc,mCAAI,EAAE,CAAC;YACvC,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,CAAC,eAAe,aAAf,eAAe,cAAf,eAAe,GAAI,EAAE,CAAC;KAC3B,0CAAE,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE,CACtB,CAAC,CAAC,KAAK;QACL,oCAAoC;QACpC,oHAAoH;QACpH,gEAAgE;SAC/D,gBAAgB,CAAC,KAAK,CAAC;SACvB,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAA,WAAI,EAAC,IAAI,EAAE,QAAQ,CAAC,CAAC,CAC3C,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,0BAA0B,GAAG,CAAC,CAAmB,EAAY,EAAE;IACnE,IAAI,IAAA,kDAAoC,EAAC,CAAC,CAAC,EAAE,CAAC;QAC5C,OAAO,CAAC,IAAA,WAAI,EAAC,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC;IACrC,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import type { WorkspaceContext } from "../../types/context";
|
|
2
|
-
import { type ComponentContext } from "../../types/context";
|
|
1
|
+
import type { ComponentContextWithBuild, WorkspaceContext } from "../../types/context";
|
|
3
2
|
import type { AppBuildJobDefinition, DockerBuildJobDefinition } from "../../types/jobDefinition";
|
|
4
3
|
import type { CatladderJob } from "../../types/jobs";
|
|
5
|
-
export declare const createComponentBuildJobs: (context:
|
|
4
|
+
export declare const createComponentBuildJobs: (context: ComponentContextWithBuild, definitions: {
|
|
6
5
|
appBuild?: AppBuildJobDefinition;
|
|
7
6
|
dockerBuild: DockerBuildJobDefinition;
|
|
8
7
|
}) => CatladderJob[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/base/index.ts"],"names":[],"mappings":";;;AAAA,4CAAoD;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/base/index.ts"],"names":[],"mappings":";;;AAAA,4CAAoD;AAKpD,iDAI6B;AAM7B,sCAA0E;AAC1E,kCAA6C;AAC7C,2CAAiD;AACjD,2DAAwD;AAEjD,MAAM,wBAAwB,GAAG,CACtC,OAAkC,EAClC,WAGC,EACe,EAAE;;IAClB,OAAO;QACL,GAAG,CAAC,WAAW,CAAC,QAAQ,IAAI,IAAA,2CAAiC,EAAC,OAAO,CAAC;YACpE,CAAC,CAAC,CAAC,IAAA,qCAAiB,EAAC,OAAO,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAC;YACpD,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,CAAC,IAAA,4BAAmB,EAAC,OAAO,CAAC;YAC9B,CAAC,CAAC;gBACE,IAAA,iCAAwB,EAAC,OAAO,EAAE;oBAChC,GAAG,WAAW,CAAC,WAAW;oBAC1B,KAAK,EAAE;wBACL,GAAG,CAAC,MAAA,WAAW,CAAC,WAAW,CAAC,KAAK,mCAAI,EAAE,CAAC;wBACxC,GAAG,CAAC,WAAW,CAAC,QAAQ;4BACxB,IAAA,2CAAiC,EAAC,OAAO,CAAC;4BACxC,CAAC,CAAC,CAAC,8BAAkB,CAAC;4BACtB,CAAC,CAAC,IAAA,2CAAiC,EAAC,OAAO,CAAC;gCAC1C,CAAC,CAAC;oCACE;wCACE,GAAG,EAAE,8BAAkB;wCACvB,SAAS,EAAE,IAAI;wCACf,aAAa,EAAE,OAAO,CAAC,KAAK,CAAC,aAAa;qCAC3C;iCACF;gCACH,CAAC,CAAC,EAAE,CAAC;qBACV;iBACF,CAAC;aACH;YACH,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,CAAC,IAAA,sBAAe,EAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,IAAA,yBAAkB,EAAC,OAAO,CAAC,CAAC,CAAC;KACnE,CAAC;AACJ,CAAC,CAAC;AAnCW,QAAA,wBAAwB,4BAmCnC;AAEK,MAAM,wBAAwB,GAAG,CACtC,OAAyB,EACzB,WAEC,EACe,EAAE;IAClB,OAAO,WAAW,CAAC,QAAQ;QACzB,CAAC,CAAC,CAAC,IAAA,qCAAiB,EAAC,OAAO,EAAE,WAAW,CAAC,QAAQ,CAAC,CAAC;QACpD,CAAC,CAAC,EAAE,CAAC;AACT,CAAC,CAAC;AATW,QAAA,wBAAwB,4BASnC"}
|
|
@@ -15,10 +15,12 @@ const getAllCacheConfigsFromConfig = (context, configWithCache) => {
|
|
|
15
15
|
// we would probably need to introduce a path to the right config property (build-->test or so)
|
|
16
16
|
context.components.flatMap((componentContext) => {
|
|
17
17
|
var _a;
|
|
18
|
-
return
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
18
|
+
return componentContext.build.type !== "disabled"
|
|
19
|
+
? ((_a = (0, index_1.ensureArray)(componentContext.build.config.cache).map((c) => ({
|
|
20
|
+
...c,
|
|
21
|
+
baseDir: componentContext.build.dir,
|
|
22
|
+
}))) !== null && _a !== void 0 ? _a : [])
|
|
23
|
+
: [];
|
|
22
24
|
})
|
|
23
25
|
: []),
|
|
24
26
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getAllCacheConfigsFromConfig.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/cache/getAllCacheConfigsFromConfig.ts"],"names":[],"mappings":";;;AACA,6CAAgD;AAEhD,uEAAoE;AAE7D,MAAM,4BAA4B,GAAG,CAC1C,OAAgB,EAChB,eAAgC,EACjB,EAAE;IACjB,OAAO;QACL,GAAG,CAAC,UAAU,IAAI,eAAe;YAC/B,CAAC,CAAC,IAAA,iDAAuB,EAAC,eAAe,CAAC,QAAQ,CAAC;YACnD,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,IAAA,mBAAW,EAAC,eAAe,CAAC,KAAK,CAAC;QACrC,GAAG,CAAC,OAAO,CAAC,IAAI,KAAK,WAAW;YAC9B,CAAC,CAAC,6DAA6D;gBAC7D,yDAAyD;gBACzD,+FAA+F;gBAC/F,OAAO,CAAC,UAAU,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"getAllCacheConfigsFromConfig.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/cache/getAllCacheConfigsFromConfig.ts"],"names":[],"mappings":";;;AACA,6CAAgD;AAEhD,uEAAoE;AAE7D,MAAM,4BAA4B,GAAG,CAC1C,OAAgB,EAChB,eAAgC,EACjB,EAAE;IACjB,OAAO;QACL,GAAG,CAAC,UAAU,IAAI,eAAe;YAC/B,CAAC,CAAC,IAAA,iDAAuB,EAAC,eAAe,CAAC,QAAQ,CAAC;YACnD,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,IAAA,mBAAW,EAAC,eAAe,CAAC,KAAK,CAAC;QACrC,GAAG,CAAC,OAAO,CAAC,IAAI,KAAK,WAAW;YAC9B,CAAC,CAAC,6DAA6D;gBAC7D,yDAAyD;gBACzD,+FAA+F;gBAC/F,OAAO,CAAC,UAAU,CAAC,OAAO,CAAc,CAAC,gBAAgB,EAAE,EAAE;;oBAC3D,OAAA,gBAAgB,CAAC,KAAK,CAAC,IAAI,KAAK,UAAU;wBACxC,CAAC,CAAC,CAAC,MAAA,IAAA,mBAAW,EAAC,gBAAgB,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;4BAC5D,GAAG,CAAC;4BACJ,OAAO,EAAE,gBAAgB,CAAC,KAAK,CAAC,GAAG;yBACpC,CAAC,CAAC,mCAAI,EAAE,CAAC;wBACZ,CAAC,CAAC,EAAE,CAAA;iBAAA,CACP;YACH,CAAC,CAAC,EAAE,CAAC;KACR,CAAC;AACJ,CAAC,CAAC;AAvBW,QAAA,4BAA4B,gCAuBvC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentContextWithBuild } from "../../types/context";
|
|
2
2
|
import type { CatladderJob } from "../../types/jobs";
|
|
3
|
-
export declare const createCustomBuildJobs: (context:
|
|
3
|
+
export declare const createCustomBuildJobs: (context: ComponentContextWithBuild) => CatladderJob[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildJob.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/custom/buildJob.ts"],"names":[],"mappings":";;;AACA,sCAAsE;AACtE,oCAAyC;AAGzC,kCAAmD;AACnD,+EAA4E;AAErE,MAAM,qBAAqB,GAAG,CACnC,
|
|
1
|
+
{"version":3,"file":"buildJob.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/custom/buildJob.ts"],"names":[],"mappings":";;;AACA,sCAAsE;AACtE,oCAAyC;AAGzC,kCAAmD;AACnD,+EAA4E;AAErE,MAAM,qBAAqB,GAAG,CACnC,OAAkC,EAClB,EAAE;IAClB,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC;IAEzC,IAAI,CAAC,IAAA,qBAAa,EAAC,WAAW,EAAE,QAAQ,CAAC,EAAE,CAAC;QAC1C,MAAM,IAAI,KAAK,CAAC,6BAA6B,CAAC,CAAC;IACjD,CAAC;IAED,OAAO,IAAA,+BAAwB,EAAC,OAAO,EAAE;QACvC,QAAQ,EACN,WAAW,CAAC,YAAY,KAAK,IAAI;YAC/B,CAAC,CAAC,IAAA,mDAAwB,EAAC,OAAO,EAAE,WAAW,CAAC;YAChD,CAAC,CAAC,SAAS;QACf,WAAW,EAAE;YACX,MAAM,EAAE,IAAA,kDAAyC,EAAC,OAAO,CAAC;YAE1D,SAAS,EAAE,EAAE;SACd;KACF,CAAC,CAAC;AACL,CAAC,CAAC;AApBW,QAAA,qBAAqB,yBAoBhC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ComponentContextWithBuild } from "../../types";
|
|
2
2
|
import type { CatladderJob } from "../../types/jobs";
|
|
3
|
-
export declare const createCustomJobs: (context:
|
|
3
|
+
export declare const createCustomJobs: (context: ComponentContextWithBuild) => CatladderJob[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/custom/index.ts"],"names":[],"mappings":";;;AAEA,yCAAmD;AACnD,uCAAiD;AAE1C,MAAM,gBAAgB,GAAG,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../pipeline/src/build/custom/index.ts"],"names":[],"mappings":";;;AAEA,yCAAmD;AACnD,uCAAiD;AAE1C,MAAM,gBAAgB,GAAG,CAC9B,OAAkC,EAClB,EAAE;IAClB,OAAO,CAAC,GAAG,IAAA,8BAAoB,EAAC,OAAO,CAAC,EAAE,GAAG,IAAA,gCAAqB,EAAC,OAAO,CAAC,CAAC,CAAC;AAC/E,CAAC,CAAC;AAJW,QAAA,gBAAgB,oBAI3B"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Artifacts } from "../../types";
|
|
2
|
-
import type {
|
|
2
|
+
import type { ComponentContextWithBuild } from "../../types/context";
|
|
3
3
|
import type { CatladderJob } from "../../types/jobs";
|
|
4
|
-
export declare const createCustomTestJobs: (context:
|
|
4
|
+
export declare const createCustomTestJobs: (context: ComponentContextWithBuild) => CatladderJob[];
|
|
5
5
|
export type OptionalArtifacts = {
|
|
6
6
|
artifacts: Artifacts;
|
|
7
7
|
} | undefined;
|