@catladder/pipeline 3.13.0 → 3.14.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/bash/bashEscape.d.ts +2 -0
- package/dist/bash/bashEscape.js +9 -1
- package/dist/constants.js +1 -1
- package/dist/pipeline/agent/createAgentContext.d.ts +6 -0
- package/dist/pipeline/agent/createAgentContext.js +141 -0
- package/dist/pipeline/agent/createAgentEventJob.d.ts +2 -0
- package/dist/pipeline/agent/createAgentEventJob.js +74 -0
- package/dist/pipeline/agent/createAgentReviewJob.d.ts +2 -0
- package/dist/pipeline/agent/createAgentReviewJob.js +69 -0
- package/dist/pipeline/agent/createJobsForAgentContext.d.ts +2 -0
- package/dist/pipeline/agent/createJobsForAgentContext.js +12 -0
- package/dist/pipeline/agent/prompts.d.ts +10 -0
- package/dist/pipeline/agent/prompts.js +66 -0
- package/dist/pipeline/agent/shared.d.ts +8 -0
- package/dist/pipeline/agent/shared.js +29 -0
- package/dist/pipeline/agent/utils.d.ts +3 -0
- package/dist/pipeline/agent/utils.js +16 -0
- package/dist/pipeline/createAllJobs.d.ts +5 -1
- package/dist/pipeline/createAllJobs.js +32 -6
- package/dist/pipeline/createMainPipeline.js +10 -5
- package/dist/pipeline/gitlab/createGitlabJobs.d.ts +3 -3
- package/dist/pipeline/gitlab/createGitlabJobs.js +13 -11
- package/dist/pipeline/gitlab/createGitlabPipeline.js +7 -1
- package/dist/rules/index.d.ts +1 -0
- package/dist/rules/index.js +8 -3
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/agent.d.ts +7 -0
- package/dist/types/agent.js +5 -0
- package/dist/types/config.d.ts +2 -0
- package/dist/types/context.d.ts +7 -0
- package/dist/types/index.d.ts +2 -1
- package/dist/types/index.js +2 -1
- package/dist/types/jobs.d.ts +5 -1
- package/dist/types/jobs.js +1 -1
- package/examples/__snapshots__/cloud-run-health-check-defaults.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-health-check-only-startup.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-health-check.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-http2.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-llama.test.ts.snap +30 -1
- package/examples/__snapshots__/cloud-run-memory-limit.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-meteor-with-worker.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-nextjs.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-no-cpu-throttling.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-no-service.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-non-public.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-post-stop-job.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-service-custom-vpc-connector.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-service-custom-vpc.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-service-gen2.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-service-increase-timout.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-service-with-volumes.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-storybook.test.ts.snap +54 -1
- package/examples/__snapshots__/cloud-run-with-agents.test.ts.snap +1576 -0
- package/examples/__snapshots__/cloud-run-with-gpu.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-with-ngnix.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-with-sql-legacy-jobs.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-with-sql-multiple-dbs.test.ts.snap +170 -1
- package/examples/__snapshots__/cloud-run-with-sql-reuse-db.test.ts.snap +118 -1
- package/examples/__snapshots__/cloud-run-with-sql.test.ts.snap +66 -1
- package/examples/__snapshots__/cloud-run-with-worker.test.ts.snap +66 -1
- package/examples/__snapshots__/custom-build-job-with-tests.test.ts.snap +66 -1
- package/examples/__snapshots__/custom-build-job.test.ts.snap +54 -1
- package/examples/__snapshots__/custom-deploy.test.ts.snap +60 -1
- package/examples/__snapshots__/custom-envs.test.ts.snap +64 -1
- package/examples/__snapshots__/custom-sbom-java.test.ts.snap +54 -1
- package/examples/__snapshots__/custom-verify-job.test.ts.snap +74 -1
- package/examples/__snapshots__/git-submodule.test.ts.snap +66 -1
- package/examples/__snapshots__/kubernetes-application-customization.test.ts.snap +74 -1
- package/examples/__snapshots__/kubernetes-with-cloud-sql.test.ts.snap +74 -1
- package/examples/__snapshots__/kubernetes-with-jobs.test.ts.snap +134 -1
- package/examples/__snapshots__/kubernetes-with-mongodb.test.ts.snap +74 -1
- package/examples/__snapshots__/local-dot-env.test.ts.snap +66 -1
- package/examples/__snapshots__/meteor-kubernetes.test.ts.snap +74 -1
- package/examples/__snapshots__/multiline-var.test.ts.snap +178 -1
- package/examples/__snapshots__/native-app.test.ts.snap +102 -1
- package/examples/__snapshots__/node-build-with-custom-image.test.ts.snap +66 -1
- package/examples/__snapshots__/node-build-with-docker-additions.test.ts.snap +66 -1
- package/examples/__snapshots__/override-secrets.test.ts.snap +66 -1
- package/examples/__snapshots__/rails-k8s-with-worker-dockerfile.test.ts.snap +66 -1
- package/examples/__snapshots__/rails-k8s-with-worker.test.ts.snap +66 -1
- package/examples/__snapshots__/referencing-other-vars.test.ts.snap +178 -1
- package/examples/__snapshots__/wait-for-other-deploy.test.ts.snap +86 -1
- package/examples/__snapshots__/workspace-api-www-turbo-cache.test.ts.snap +98 -1
- package/examples/__snapshots__/workspace-api-www.test.ts.snap +98 -1
- package/examples/cloud-run-with-agents.test.ts +11 -0
- package/examples/cloud-run-with-agents.ts +36 -0
- package/package.json +1 -1
- package/src/bash/bashEscape.ts +6 -0
- package/src/pipeline/__tests__/__snapshots__/getPipelineStages.test.ts.snap +9 -0
- package/src/pipeline/agent/createAgentContext.ts +19 -0
- package/src/pipeline/agent/createAgentEventJob.ts +35 -0
- package/src/pipeline/agent/createAgentReviewJob.ts +33 -0
- package/src/pipeline/agent/createJobsForAgentContext.ts +7 -0
- package/src/pipeline/agent/prompts.ts +233 -0
- package/src/pipeline/agent/shared.ts +36 -0
- package/src/pipeline/agent/utils.ts +9 -0
- package/src/pipeline/createAllJobs.ts +20 -1
- package/src/pipeline/createJobsForComponent.ts +1 -0
- package/src/pipeline/createMainPipeline.ts +19 -4
- package/src/pipeline/gitlab/createGitlabJobs.ts +39 -30
- package/src/pipeline/gitlab/createGitlabPipeline.ts +9 -1
- package/src/rules/index.ts +7 -0
- package/src/types/agent.ts +7 -0
- package/src/types/config.ts +3 -0
- package/src/types/context.ts +8 -0
- package/src/types/index.ts +1 -0
- package/src/types/jobs.ts +6 -0
|
@@ -28,6 +28,11 @@ stages:
|
|
|
28
28
|
- verify review
|
|
29
29
|
- verify stage
|
|
30
30
|
- verify prod
|
|
31
|
+
- agents
|
|
32
|
+
- agents dev
|
|
33
|
+
- agents review
|
|
34
|
+
- agents stage
|
|
35
|
+
- agents prod
|
|
31
36
|
- rollback
|
|
32
37
|
- rollback dev
|
|
33
38
|
- rollback review
|
|
@@ -48,6 +53,10 @@ variables:
|
|
|
48
53
|
workflow:
|
|
49
54
|
name: $PIPELINE_ICON $PIPELINE_NAME
|
|
50
55
|
rules:
|
|
56
|
+
- if: $CI_PIPELINE_SOURCE == "trigger"
|
|
57
|
+
variables:
|
|
58
|
+
PIPELINE_ICON: 🤖
|
|
59
|
+
PIPELINE_NAME: Thinking...
|
|
51
60
|
- if: $CI_MERGE_REQUEST_ID
|
|
52
61
|
variables:
|
|
53
62
|
PIPELINE_ICON: 🐱🔨
|
|
@@ -59,7 +68,7 @@ workflow:
|
|
|
59
68
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
60
69
|
variables:
|
|
61
70
|
PIPELINE_ICON: 🐱🔨
|
|
62
|
-
PIPELINE_NAME: Main
|
|
71
|
+
PIPELINE_NAME: Main
|
|
63
72
|
- when: always
|
|
64
73
|
variables:
|
|
65
74
|
PIPELINE_ICON: 🐱❓
|
|
@@ -108,7 +117,11 @@ api 🛡 audit:
|
|
|
108
117
|
- cd api
|
|
109
118
|
- yarn npm audit --environment production
|
|
110
119
|
rules:
|
|
120
|
+
- when: never
|
|
121
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
111
122
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
123
|
+
- when: never
|
|
124
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
112
125
|
- if: $CI_MERGE_REQUEST_ID
|
|
113
126
|
needs: []
|
|
114
127
|
retry: &a1
|
|
@@ -152,7 +165,11 @@ api 👮 lint:
|
|
|
152
165
|
paths:
|
|
153
166
|
- api/node_modules
|
|
154
167
|
rules:
|
|
168
|
+
- when: never
|
|
169
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
155
170
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
171
|
+
- when: never
|
|
172
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
156
173
|
- if: $CI_MERGE_REQUEST_ID
|
|
157
174
|
needs: []
|
|
158
175
|
retry: *a1
|
|
@@ -191,7 +208,11 @@ api 🧪 test:
|
|
|
191
208
|
paths:
|
|
192
209
|
- api/node_modules
|
|
193
210
|
rules:
|
|
211
|
+
- when: never
|
|
212
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
194
213
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
214
|
+
- when: never
|
|
215
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
195
216
|
- if: $CI_MERGE_REQUEST_ID
|
|
196
217
|
needs: []
|
|
197
218
|
retry: *a1
|
|
@@ -288,6 +309,8 @@ api 🧪 test:
|
|
|
288
309
|
when: always
|
|
289
310
|
reports: {}
|
|
290
311
|
rules:
|
|
312
|
+
- when: never
|
|
313
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
291
314
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
292
315
|
needs: []
|
|
293
316
|
retry: *a1
|
|
@@ -345,6 +368,8 @@ api 🧪 test:
|
|
|
345
368
|
paths:
|
|
346
369
|
- api/.yarn
|
|
347
370
|
rules:
|
|
371
|
+
- when: never
|
|
372
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
348
373
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
349
374
|
needs:
|
|
350
375
|
- 'api 🔨 app | dev '
|
|
@@ -365,6 +390,8 @@ api 🧪 test:
|
|
|
365
390
|
paths:
|
|
366
391
|
- __sbom.json
|
|
367
392
|
rules:
|
|
393
|
+
- when: never
|
|
394
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
368
395
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
369
396
|
needs: []
|
|
370
397
|
retry: *a1
|
|
@@ -518,6 +545,8 @@ api 🧪 test:
|
|
|
518
545
|
reports:
|
|
519
546
|
dotenv: gitlab_environment.env
|
|
520
547
|
rules:
|
|
548
|
+
- when: never
|
|
549
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
521
550
|
- when: on_success
|
|
522
551
|
if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
523
552
|
needs:
|
|
@@ -567,6 +596,8 @@ api 🧪 test:
|
|
|
567
596
|
rules:
|
|
568
597
|
- if: $CI_COMMIT_BRANCH =~ /^[0-9]+\\.([0-9]+|x)\\.x$/
|
|
569
598
|
when: on_success
|
|
599
|
+
- when: never
|
|
600
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
570
601
|
- when: manual
|
|
571
602
|
if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
|
|
572
603
|
needs: []
|
|
@@ -665,6 +696,8 @@ api 🧪 test:
|
|
|
665
696
|
when: always
|
|
666
697
|
reports: {}
|
|
667
698
|
rules:
|
|
699
|
+
- when: never
|
|
700
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
668
701
|
- if: $CI_MERGE_REQUEST_ID
|
|
669
702
|
needs: []
|
|
670
703
|
retry: *a1
|
|
@@ -722,6 +755,8 @@ api 🧪 test:
|
|
|
722
755
|
paths:
|
|
723
756
|
- api/.yarn
|
|
724
757
|
rules:
|
|
758
|
+
- when: never
|
|
759
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
725
760
|
- if: $CI_MERGE_REQUEST_ID
|
|
726
761
|
needs:
|
|
727
762
|
- 'api 🔨 app | review '
|
|
@@ -742,6 +777,8 @@ api 🧪 test:
|
|
|
742
777
|
paths:
|
|
743
778
|
- __sbom.json
|
|
744
779
|
rules:
|
|
780
|
+
- when: never
|
|
781
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
745
782
|
- if: $CI_MERGE_REQUEST_ID
|
|
746
783
|
needs: []
|
|
747
784
|
retry: *a1
|
|
@@ -898,6 +935,8 @@ api 🧪 test:
|
|
|
898
935
|
reports:
|
|
899
936
|
dotenv: gitlab_environment.env
|
|
900
937
|
rules:
|
|
938
|
+
- when: never
|
|
939
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
901
940
|
- when: on_success
|
|
902
941
|
if: $CI_MERGE_REQUEST_ID
|
|
903
942
|
needs:
|
|
@@ -953,6 +992,8 @@ api 🧪 test:
|
|
|
953
992
|
rules:
|
|
954
993
|
- if: $CI_COMMIT_BRANCH =~ /^[0-9]+\\.([0-9]+|x)\\.x$/
|
|
955
994
|
when: on_success
|
|
995
|
+
- when: never
|
|
996
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
956
997
|
- when: manual
|
|
957
998
|
if: $CI_MERGE_REQUEST_ID
|
|
958
999
|
needs: []
|
|
@@ -1051,6 +1092,8 @@ api 🧪 test:
|
|
|
1051
1092
|
when: always
|
|
1052
1093
|
reports: {}
|
|
1053
1094
|
rules:
|
|
1095
|
+
- when: never
|
|
1096
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1054
1097
|
- if: $CI_COMMIT_TAG
|
|
1055
1098
|
needs: []
|
|
1056
1099
|
retry: *a1
|
|
@@ -1108,6 +1151,8 @@ api 🧪 test:
|
|
|
1108
1151
|
paths:
|
|
1109
1152
|
- api/.yarn
|
|
1110
1153
|
rules:
|
|
1154
|
+
- when: never
|
|
1155
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1111
1156
|
- if: $CI_COMMIT_TAG
|
|
1112
1157
|
needs:
|
|
1113
1158
|
- 'api 🔨 app | stage '
|
|
@@ -1128,6 +1173,8 @@ api 🧪 test:
|
|
|
1128
1173
|
paths:
|
|
1129
1174
|
- __sbom.json
|
|
1130
1175
|
rules:
|
|
1176
|
+
- when: never
|
|
1177
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1131
1178
|
- if: $CI_COMMIT_TAG
|
|
1132
1179
|
needs: []
|
|
1133
1180
|
retry: *a1
|
|
@@ -1280,6 +1327,8 @@ api 🧪 test:
|
|
|
1280
1327
|
reports:
|
|
1281
1328
|
dotenv: gitlab_environment.env
|
|
1282
1329
|
rules:
|
|
1330
|
+
- when: never
|
|
1331
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1283
1332
|
- when: on_success
|
|
1284
1333
|
if: $CI_COMMIT_TAG
|
|
1285
1334
|
needs:
|
|
@@ -1323,6 +1372,8 @@ api 🧪 test:
|
|
|
1323
1372
|
rules:
|
|
1324
1373
|
- if: $CI_COMMIT_BRANCH =~ /^[0-9]+\\.([0-9]+|x)\\.x$/
|
|
1325
1374
|
when: on_success
|
|
1375
|
+
- when: never
|
|
1376
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1326
1377
|
- when: manual
|
|
1327
1378
|
if: $CI_COMMIT_TAG
|
|
1328
1379
|
needs: []
|
|
@@ -1421,6 +1472,8 @@ api 🧪 test:
|
|
|
1421
1472
|
when: always
|
|
1422
1473
|
reports: {}
|
|
1423
1474
|
rules:
|
|
1475
|
+
- when: never
|
|
1476
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1424
1477
|
- if: $CI_COMMIT_TAG
|
|
1425
1478
|
needs: []
|
|
1426
1479
|
retry: *a1
|
|
@@ -1478,6 +1531,8 @@ api 🧪 test:
|
|
|
1478
1531
|
paths:
|
|
1479
1532
|
- api/.yarn
|
|
1480
1533
|
rules:
|
|
1534
|
+
- when: never
|
|
1535
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1481
1536
|
- if: $CI_COMMIT_TAG
|
|
1482
1537
|
needs:
|
|
1483
1538
|
- 'api 🔨 app | prod '
|
|
@@ -1498,6 +1553,8 @@ api 🧪 test:
|
|
|
1498
1553
|
paths:
|
|
1499
1554
|
- __sbom.json
|
|
1500
1555
|
rules:
|
|
1556
|
+
- when: never
|
|
1557
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1501
1558
|
- if: $CI_COMMIT_TAG
|
|
1502
1559
|
needs: []
|
|
1503
1560
|
retry: *a1
|
|
@@ -1650,6 +1707,8 @@ api 🧪 test:
|
|
|
1650
1707
|
reports:
|
|
1651
1708
|
dotenv: gitlab_environment.env
|
|
1652
1709
|
rules:
|
|
1710
|
+
- when: never
|
|
1711
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1653
1712
|
- when: manual
|
|
1654
1713
|
if: $CI_COMMIT_TAG
|
|
1655
1714
|
needs:
|
|
@@ -1693,6 +1752,8 @@ api 🧪 test:
|
|
|
1693
1752
|
rules:
|
|
1694
1753
|
- if: $CI_COMMIT_BRANCH =~ /^[0-9]+\\.([0-9]+|x)\\.x$/
|
|
1695
1754
|
when: on_success
|
|
1755
|
+
- when: never
|
|
1756
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1696
1757
|
- when: manual
|
|
1697
1758
|
if: $CI_COMMIT_TAG
|
|
1698
1759
|
needs: []
|
|
@@ -1710,6 +1771,9 @@ create release:
|
|
|
1710
1771
|
if: $CI_COMMIT_MESSAGE =~ /^chore\\(release\\).*/
|
|
1711
1772
|
when: never
|
|
1712
1773
|
- &a3
|
|
1774
|
+
if: $CI_PIPELINE_SOURCE == "trigger"
|
|
1775
|
+
when: never
|
|
1776
|
+
- &a4
|
|
1713
1777
|
if: $CI_PIPELINE_SOURCE == "schedule"
|
|
1714
1778
|
when: never
|
|
1715
1779
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $AUTO_RELEASE == "true"
|
|
@@ -1727,6 +1791,7 @@ create release:
|
|
|
1727
1791
|
rules:
|
|
1728
1792
|
- *a2
|
|
1729
1793
|
- *a3
|
|
1794
|
+
- *a4
|
|
1730
1795
|
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
|
|
1731
1796
|
when: manual
|
|
1732
1797
|
- if: $CI_COMMIT_BRANCH =~ /^[0-9]+.([0-9]+|x).x$/
|