@catladder/pipeline 1.115.0 → 1.116.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/dist/bundles/catladder-gitlab/index.js +1 -1
- package/dist/constants.js +1 -1
- package/dist/deploy/cloudRun/deployJob.js +3 -3
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/examples/__snapshots__/cloud-run-memory-limit.ts.snap +20 -4
- package/examples/__snapshots__/cloud-run-no-cpu-throttling.ts.snap +20 -4
- package/examples/__snapshots__/cloud-run-non-public.ts.snap +20 -4
- package/examples/__snapshots__/cloud-run-with-sql-reuse-db.ts.snap +40 -8
- package/examples/__snapshots__/cloud-run-with-sql.ts.snap +40 -8
- package/examples/__snapshots__/custom-build-job-with-tests.ts.snap +20 -4
- package/examples/__snapshots__/custom-build-job.ts.snap +20 -4
- package/examples/__snapshots__/custom-sbom-java.ts.snap +20 -4
- package/examples/__snapshots__/native-app.ts.snap +20 -4
- package/examples/__snapshots__/node-build-with-custom-image.ts.snap +20 -4
- package/package.json +1 -1
- package/src/deploy/cloudRun/deployJob.ts +32 -23
|
@@ -57,16 +57,13 @@ export const createGoogleCloudRunDeployJobs = (
|
|
|
57
57
|
];
|
|
58
58
|
const gcloudImageName = `${gcloudImagePath.join("/")}:$DOCKER_IMAGE_TAG`;
|
|
59
59
|
|
|
60
|
-
const pushImageToArtifactsRegistry =
|
|
61
|
-
"pushToArtifactRegistry",
|
|
62
|
-
"pushing image to artifacts registry"
|
|
63
|
-
)([
|
|
60
|
+
const pushImageToArtifactsRegistry = [
|
|
64
61
|
gitlabDockerLogin,
|
|
65
62
|
`gcloud auth configure-docker ${deployConfig.region}-docker.pkg.dev`,
|
|
66
63
|
`docker pull $DOCKER_IMAGE:$DOCKER_IMAGE_TAG`,
|
|
67
64
|
`docker tag $DOCKER_IMAGE:$DOCKER_IMAGE_TAG ${gcloudImageName}`,
|
|
68
65
|
`docker push ${gcloudImageName}`,
|
|
69
|
-
]
|
|
66
|
+
];
|
|
70
67
|
const allEnvVars = omit(
|
|
71
68
|
context.environment.envVars,
|
|
72
69
|
GCLOUD_DEPLOY_CREDENTIALS_KEY
|
|
@@ -228,25 +225,37 @@ export const createGoogleCloudRunDeployJobs = (
|
|
|
228
225
|
]);
|
|
229
226
|
|
|
230
227
|
const deployScripts = [
|
|
231
|
-
...
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
...
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
...(
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
228
|
+
...collapseableSection(
|
|
229
|
+
"prepare",
|
|
230
|
+
"Prepare..."
|
|
231
|
+
)([
|
|
232
|
+
...gcloudServiceAccountLoginCommands(context),
|
|
233
|
+
...setExtraVarsScripts(deployConfig),
|
|
234
|
+
]),
|
|
235
|
+
...collapseableSection(
|
|
236
|
+
"pushToArtifactRegistry",
|
|
237
|
+
"Pushing image to artifacts registry"
|
|
238
|
+
)(pushImageToArtifactsRegistry),
|
|
239
|
+
...collapseableSection(
|
|
240
|
+
"deploy",
|
|
241
|
+
"Deploy to cloud run"
|
|
242
|
+
)([
|
|
243
|
+
`echo "$ENV_VARS" > ____envvars.yaml`, // TODO: split secrets out
|
|
244
|
+
...(deployConfig.cloudSql
|
|
245
|
+
? getDatabaseCreateScript(context, deployConfig) // we create the db, so that we can also delete it afterwards
|
|
246
|
+
: []),
|
|
247
|
+
...getCreateScheduleScripts(),
|
|
248
|
+
...getJobCreateScripts(),
|
|
249
|
+
...getJobRunScripts("preDeploy"),
|
|
249
250
|
|
|
251
|
+
...(deployConfig.service !== false
|
|
252
|
+
? [getServiceDeployScript(deployConfig.service)]
|
|
253
|
+
: []),
|
|
254
|
+
...Object.entries(deployConfig.additionalServices ?? {}).map(
|
|
255
|
+
([name, service]) => getServiceDeployScript(service, "-" + name)
|
|
256
|
+
),
|
|
257
|
+
...getJobRunScripts("postDeploy"),
|
|
258
|
+
]),
|
|
250
259
|
`docker image rm ${gcloudImageName}`,
|
|
251
260
|
...getDependencyTrackUploadScript(context),
|
|
252
261
|
];
|