@catladder/pipeline 3.25.0 → 3.27.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.
Files changed (77) hide show
  1. package/dist/build/custom/testJob.js +1 -2
  2. package/dist/build/node/testJob.js +1 -2
  3. package/dist/build/node/yarn.js +3 -2
  4. package/dist/build/rails/test.js +1 -2
  5. package/dist/constants.js +1 -1
  6. package/dist/deploy/types/googleCloudRun.d.ts +1 -1
  7. package/dist/pipeline/agent/createAgentReviewJob.js +1 -0
  8. package/dist/pipeline/agent/shared.d.ts +1 -1
  9. package/dist/pipeline/agent/shared.js +0 -1
  10. package/dist/pipeline/createMainPipeline.js +1 -0
  11. package/dist/pipeline/gitlab/cache.d.ts +9 -0
  12. package/dist/pipeline/gitlab/cache.js +47 -0
  13. package/dist/pipeline/gitlab/createGitlabJobs.js +7 -7
  14. package/dist/tsconfig.tsbuildinfo +1 -1
  15. package/dist/types/jobs.d.ts +2 -3
  16. package/examples/__snapshots__/automatic-releases.test.ts.snap +141 -31
  17. package/examples/__snapshots__/cloud-run-health-check-defaults.test.ts.snap +141 -31
  18. package/examples/__snapshots__/cloud-run-health-check-only-startup.test.ts.snap +141 -31
  19. package/examples/__snapshots__/cloud-run-health-check.test.ts.snap +141 -31
  20. package/examples/__snapshots__/cloud-run-http2.test.ts.snap +141 -31
  21. package/examples/__snapshots__/cloud-run-memory-limit.test.ts.snap +141 -31
  22. package/examples/__snapshots__/cloud-run-meteor-with-worker.test.ts.snap +133 -27
  23. package/examples/__snapshots__/cloud-run-nextjs.test.ts.snap +144 -32
  24. package/examples/__snapshots__/cloud-run-no-cpu-throttling.test.ts.snap +141 -31
  25. package/examples/__snapshots__/cloud-run-no-service.test.ts.snap +141 -31
  26. package/examples/__snapshots__/cloud-run-non-public.test.ts.snap +141 -31
  27. package/examples/__snapshots__/cloud-run-post-stop-job.test.ts.snap +141 -31
  28. package/examples/__snapshots__/cloud-run-service-custom-vpc-connector.test.ts.snap +141 -31
  29. package/examples/__snapshots__/cloud-run-service-custom-vpc.test.ts.snap +141 -31
  30. package/examples/__snapshots__/cloud-run-service-gen2.test.ts.snap +141 -31
  31. package/examples/__snapshots__/cloud-run-service-increase-timout.test.ts.snap +141 -31
  32. package/examples/__snapshots__/cloud-run-service-with-volumes.test.ts.snap +141 -31
  33. package/examples/__snapshots__/cloud-run-storybook.test.ts.snap +21 -11
  34. package/examples/__snapshots__/cloud-run-with-agents.test.ts.snap +144 -32
  35. package/examples/__snapshots__/cloud-run-with-gpu.test.ts.snap +141 -31
  36. package/examples/__snapshots__/cloud-run-with-ngnix.test.ts.snap +141 -31
  37. package/examples/__snapshots__/cloud-run-with-sql-legacy-jobs.test.ts.snap +141 -31
  38. package/examples/__snapshots__/cloud-run-with-sql-multiple-dbs.test.ts.snap +423 -93
  39. package/examples/__snapshots__/cloud-run-with-sql-reuse-db.test.ts.snap +282 -62
  40. package/examples/__snapshots__/cloud-run-with-sql.test.ts.snap +141 -31
  41. package/examples/__snapshots__/cloud-run-with-worker.test.ts.snap +141 -31
  42. package/examples/__snapshots__/custom-build-job-with-tests.test.ts.snap +93 -22
  43. package/examples/__snapshots__/custom-deploy.test.ts.snap +141 -31
  44. package/examples/__snapshots__/custom-envs.test.ts.snap +328 -40
  45. package/examples/__snapshots__/custom-verify-job.test.ts.snap +144 -32
  46. package/examples/__snapshots__/git-submodule.test.ts.snap +141 -31
  47. package/examples/__snapshots__/kubernetes-application-customization.test.ts.snap +141 -31
  48. package/examples/__snapshots__/kubernetes-with-cloud-sql.test.ts.snap +141 -31
  49. package/examples/__snapshots__/kubernetes-with-jobs.test.ts.snap +282 -62
  50. package/examples/__snapshots__/kubernetes-with-mongodb.test.ts.snap +141 -31
  51. package/examples/__snapshots__/local-dot-env.test.ts.snap +141 -31
  52. package/examples/__snapshots__/meteor-kubernetes.test.ts.snap +133 -27
  53. package/examples/__snapshots__/modify-generated-files.test.ts.snap +124 -20
  54. package/examples/__snapshots__/modify-generated-yaml.test.ts.snap +124 -20
  55. package/examples/__snapshots__/multiline-var.test.ts.snap +423 -93
  56. package/examples/__snapshots__/native-app.test.ts.snap +277 -57
  57. package/examples/__snapshots__/node-build-with-custom-image.test.ts.snap +141 -31
  58. package/examples/__snapshots__/node-build-with-docker-additions.test.ts.snap +141 -31
  59. package/examples/__snapshots__/override-secrets.test.ts.snap +141 -31
  60. package/examples/__snapshots__/rails-k8s-with-worker-dockerfile.test.ts.snap +84 -22
  61. package/examples/__snapshots__/rails-k8s-with-worker.test.ts.snap +84 -22
  62. package/examples/__snapshots__/referencing-other-vars.test.ts.snap +423 -93
  63. package/examples/__snapshots__/wait-for-other-deploy.test.ts.snap +260 -52
  64. package/examples/__snapshots__/workspace-api-www-turbo-cache.test.ts.snap +161 -43
  65. package/examples/__snapshots__/workspace-api-www.test.ts.snap +161 -43
  66. package/package.json +1 -1
  67. package/src/build/custom/testJob.ts +0 -1
  68. package/src/build/node/testJob.ts +0 -1
  69. package/src/build/node/yarn.ts +3 -2
  70. package/src/build/rails/test.ts +0 -1
  71. package/src/deploy/types/googleCloudRun.ts +1 -1
  72. package/src/pipeline/agent/createAgentReviewJob.ts +1 -0
  73. package/src/pipeline/agent/shared.ts +2 -2
  74. package/src/pipeline/createMainPipeline.ts +1 -0
  75. package/src/pipeline/gitlab/cache.ts +49 -0
  76. package/src/pipeline/gitlab/createGitlabJobs.ts +7 -9
  77. package/src/types/jobs.ts +2 -3
@@ -103,7 +103,7 @@ before_script:
103
103
  local section_title="\${1}"
104
104
  echo -e "section_end:\`date +%s\`:\${section_title}\\r\\e[0K"
105
105
  }
106
- www 🛡 audit:
106
+ 'www 🛡 audit | dev ':
107
107
  stage: test
108
108
  image: path/to/docker/jobs-default:the-version
109
109
  variables:
@@ -120,9 +120,6 @@ www 🛡 audit:
120
120
  - when: never
121
121
  if: $CI_PIPELINE_SOURCE == "trigger"
122
122
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
123
- - when: never
124
- if: $CI_PIPELINE_SOURCE == "trigger"
125
- - if: $CI_MERGE_REQUEST_ID
126
123
  needs: []
127
124
  retry: &a1
128
125
  max: 2
@@ -131,7 +128,7 @@ www 🛡 audit:
131
128
  - stuck_or_timeout_failure
132
129
  interruptible: true
133
130
  allow_failure: true
134
- www 👮 lint:
131
+ 'www 👮 lint | dev ':
135
132
  stage: test
136
133
  image: path/to/docker/jobs-default:the-version
137
134
  variables:
@@ -152,7 +149,7 @@ www 👮 lint:
152
149
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
153
150
  - collapseable_section_end "nodeinstall"
154
151
  - collapseable_section_start "yarninstall" "Yarn install"
155
- - yarn install --immutable
152
+ - yarn install --immutable --inline-builds
156
153
  - collapseable_section_end "yarninstall"
157
154
  - yarn lint
158
155
  cache:
@@ -168,13 +165,10 @@ www 👮 lint:
168
165
  - when: never
169
166
  if: $CI_PIPELINE_SOURCE == "trigger"
170
167
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
171
- - when: never
172
- if: $CI_PIPELINE_SOURCE == "trigger"
173
- - if: $CI_MERGE_REQUEST_ID
174
168
  needs: []
175
169
  retry: *a1
176
170
  interruptible: true
177
- www 🧪 test:
171
+ 'www 🧪 test | dev ':
178
172
  stage: test
179
173
  image: path/to/docker/jobs-testing-chrome:the-version
180
174
  variables:
@@ -195,7 +189,7 @@ www 🧪 test:
195
189
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
196
190
  - collapseable_section_end "nodeinstall"
197
191
  - collapseable_section_start "yarninstall" "Yarn install"
198
- - yarn install --immutable
192
+ - yarn install --immutable --inline-builds
199
193
  - collapseable_section_end "yarninstall"
200
194
  - yarn test
201
195
  cache:
@@ -211,9 +205,6 @@ www 🧪 test:
211
205
  - when: never
212
206
  if: $CI_PIPELINE_SOURCE == "trigger"
213
207
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
214
- - when: never
215
- if: $CI_PIPELINE_SOURCE == "trigger"
216
- - if: $CI_MERGE_REQUEST_ID
217
208
  needs: []
218
209
  retry: *a1
219
210
  interruptible: true
@@ -270,7 +261,7 @@ www 🧪 test:
270
261
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
271
262
  - collapseable_section_end "nodeinstall"
272
263
  - collapseable_section_start "yarninstall" "Yarn install"
273
- - yarn install --immutable
264
+ - yarn install --immutable --inline-builds
274
265
  - collapseable_section_end "yarninstall"
275
266
  - yarn build
276
267
  cache:
@@ -325,7 +316,8 @@ www 🧪 test:
325
316
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
326
317
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
327
318
  - |-
328
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
319
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
320
+ COPY --chown=node:node $APP_DIR .
329
321
  RUN yarn plugin import workspace-tools
330
322
  RUN yarn workspaces focus --production && yarn rebuild"
331
323
  - |-
@@ -478,17 +470,17 @@ www 🧪 test:
478
470
  - when: on_success
479
471
  if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
480
472
  needs:
481
- - job: www 👮 lint
473
+ - job: 'www 👮 lint | dev '
482
474
  artifacts: false
483
475
  - job: 'www 🔨 app | dev '
484
476
  artifacts: false
485
477
  - job: 'www 🔨 docker | dev '
486
478
  artifacts: false
487
- - job: www 🧪 test
479
+ - job: 'www 🧪 test | dev '
488
480
  artifacts: false
489
481
  - job: 'www 🧾 sbom | dev '
490
482
  artifacts: true
491
- - job: www 🛡 audit
483
+ - job: 'www 🛡 audit | dev '
492
484
  artifacts: false
493
485
  retry: *a1
494
486
  interruptible: true
@@ -527,6 +519,115 @@ www 🧪 test:
527
519
  retry: *a1
528
520
  interruptible: true
529
521
  allow_failure: true
522
+ 'www 🛡 audit | review ':
523
+ stage: test
524
+ image: path/to/docker/jobs-default:the-version
525
+ variables:
526
+ KUBERNETES_CPU_REQUEST: '0.45'
527
+ KUBERNETES_MEMORY_REQUEST: 1Gi
528
+ KUBERNETES_MEMORY_LIMIT: 4Gi
529
+ script:
530
+ - collapseable_section_start "injectvars" "Injecting variables"
531
+ - export APP_PATH="www"
532
+ - collapseable_section_end "injectvars"
533
+ - cd www
534
+ - yarn npm audit --environment production
535
+ rules:
536
+ - when: never
537
+ if: $CI_PIPELINE_SOURCE == "trigger"
538
+ - if: $CI_MERGE_REQUEST_ID
539
+ needs: []
540
+ retry: *a1
541
+ interruptible: true
542
+ allow_failure: true
543
+ 'www 👮 lint | review ':
544
+ stage: test
545
+ image: path/to/docker/jobs-default:the-version
546
+ variables:
547
+ KUBERNETES_CPU_REQUEST: '0.45'
548
+ KUBERNETES_MEMORY_REQUEST: 1Gi
549
+ KUBERNETES_MEMORY_LIMIT: 4Gi
550
+ script:
551
+ - collapseable_section_start "injectvars" "Injecting variables"
552
+ - export APP_PATH="www"
553
+ - collapseable_section_end "injectvars"
554
+ - collapseable_section_start "nodeinstall" "Ensure node version"
555
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
556
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
557
+ - collapseable_section_end "nodeinstall"
558
+ - cd www
559
+ - collapseable_section_start "nodeinstall" "Ensure node version"
560
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
561
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
562
+ - collapseable_section_end "nodeinstall"
563
+ - collapseable_section_start "yarninstall" "Yarn install"
564
+ - yarn install --immutable --inline-builds
565
+ - collapseable_section_end "yarninstall"
566
+ - yarn lint
567
+ cache:
568
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
569
+ policy: pull-push
570
+ paths:
571
+ - www/.yarn
572
+ fallback_keys:
573
+ - www-yarn
574
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
575
+ policy: pull-push
576
+ paths:
577
+ - www/node_modules
578
+ fallback_keys:
579
+ - www-node-modules
580
+ rules:
581
+ - when: never
582
+ if: $CI_PIPELINE_SOURCE == "trigger"
583
+ - if: $CI_MERGE_REQUEST_ID
584
+ needs: []
585
+ retry: *a1
586
+ interruptible: true
587
+ 'www 🧪 test | review ':
588
+ stage: test
589
+ image: path/to/docker/jobs-testing-chrome:the-version
590
+ variables:
591
+ KUBERNETES_CPU_REQUEST: '0.45'
592
+ KUBERNETES_MEMORY_REQUEST: 1Gi
593
+ KUBERNETES_MEMORY_LIMIT: 4Gi
594
+ script:
595
+ - collapseable_section_start "injectvars" "Injecting variables"
596
+ - export APP_PATH="www"
597
+ - collapseable_section_end "injectvars"
598
+ - collapseable_section_start "nodeinstall" "Ensure node version"
599
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
600
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
601
+ - collapseable_section_end "nodeinstall"
602
+ - cd www
603
+ - collapseable_section_start "nodeinstall" "Ensure node version"
604
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
605
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
606
+ - collapseable_section_end "nodeinstall"
607
+ - collapseable_section_start "yarninstall" "Yarn install"
608
+ - yarn install --immutable --inline-builds
609
+ - collapseable_section_end "yarninstall"
610
+ - yarn test
611
+ cache:
612
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
613
+ policy: pull-push
614
+ paths:
615
+ - www/.yarn
616
+ fallback_keys:
617
+ - www-yarn
618
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
619
+ policy: pull-push
620
+ paths:
621
+ - www/node_modules
622
+ fallback_keys:
623
+ - www-node-modules
624
+ rules:
625
+ - when: never
626
+ if: $CI_PIPELINE_SOURCE == "trigger"
627
+ - if: $CI_MERGE_REQUEST_ID
628
+ needs: []
629
+ retry: *a1
630
+ interruptible: true
530
631
  'www 🔨 app | review ':
531
632
  stage: build
532
633
  image: my-custom-image
@@ -580,18 +681,22 @@ www 🧪 test:
580
681
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
581
682
  - collapseable_section_end "nodeinstall"
582
683
  - collapseable_section_start "yarninstall" "Yarn install"
583
- - yarn install --immutable
684
+ - yarn install --immutable --inline-builds
584
685
  - collapseable_section_end "yarninstall"
585
686
  - yarn build
586
687
  cache:
587
- - key: www-yarn
688
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
588
689
  policy: pull-push
589
690
  paths:
590
691
  - www/.yarn
591
- - key: www-node-modules
692
+ fallback_keys:
693
+ - www-yarn
694
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
592
695
  policy: pull-push
593
696
  paths:
594
697
  - www/node_modules
698
+ fallback_keys:
699
+ - www-node-modules
595
700
  artifacts:
596
701
  paths:
597
702
  - www/__build_info.json
@@ -635,7 +740,8 @@ www 🧪 test:
635
740
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
636
741
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
637
742
  - |-
638
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
743
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
744
+ COPY --chown=node:node $APP_DIR .
639
745
  RUN yarn plugin import workspace-tools
640
746
  RUN yarn workspaces focus --production && yarn rebuild"
641
747
  - |-
@@ -658,10 +764,12 @@ www 🧪 test:
658
764
  - docker push $DOCKER_CACHE_IMAGE
659
765
  - collapseable_section_end "docker-push"
660
766
  cache:
661
- - key: www-yarn
767
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
662
768
  policy: pull
663
769
  paths:
664
770
  - www/.yarn
771
+ fallback_keys:
772
+ - www-yarn
665
773
  rules:
666
774
  - when: never
667
775
  if: $CI_PIPELINE_SOURCE == "trigger"
@@ -791,17 +899,17 @@ www 🧪 test:
791
899
  - when: on_success
792
900
  if: $CI_MERGE_REQUEST_ID
793
901
  needs:
794
- - job: www 👮 lint
902
+ - job: 'www 👮 lint | review '
795
903
  artifacts: false
796
904
  - job: 'www 🔨 app | review '
797
905
  artifacts: false
798
906
  - job: 'www 🔨 docker | review '
799
907
  artifacts: false
800
- - job: www 🧪 test
908
+ - job: 'www 🧪 test | review '
801
909
  artifacts: false
802
910
  - job: 'www 🧾 sbom | review '
803
911
  artifacts: true
804
- - job: www 🛡 audit
912
+ - job: 'www 🛡 audit | review '
805
913
  artifacts: false
806
914
  retry: *a1
807
915
  interruptible: true
@@ -896,7 +1004,7 @@ www 🧪 test:
896
1004
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
897
1005
  - collapseable_section_end "nodeinstall"
898
1006
  - collapseable_section_start "yarninstall" "Yarn install"
899
- - yarn install --immutable
1007
+ - yarn install --immutable --inline-builds
900
1008
  - collapseable_section_end "yarninstall"
901
1009
  - yarn build
902
1010
  cache:
@@ -951,7 +1059,8 @@ www 🧪 test:
951
1059
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
952
1060
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
953
1061
  - |-
954
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
1062
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
1063
+ COPY --chown=node:node $APP_DIR .
955
1064
  RUN yarn plugin import workspace-tools
956
1065
  RUN yarn workspaces focus --production && yarn rebuild"
957
1066
  - |-
@@ -1199,7 +1308,7 @@ www 🧪 test:
1199
1308
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
1200
1309
  - collapseable_section_end "nodeinstall"
1201
1310
  - collapseable_section_start "yarninstall" "Yarn install"
1202
- - yarn install --immutable
1311
+ - yarn install --immutable --inline-builds
1203
1312
  - collapseable_section_end "yarninstall"
1204
1313
  - yarn build
1205
1314
  cache:
@@ -1254,7 +1363,8 @@ www 🧪 test:
1254
1363
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
1255
1364
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
1256
1365
  - |-
1257
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
1366
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
1367
+ COPY --chown=node:node $APP_DIR .
1258
1368
  RUN yarn plugin import workspace-tools
1259
1369
  RUN yarn workspaces focus --production && yarn rebuild"
1260
1370
  - |-
@@ -103,7 +103,7 @@ before_script:
103
103
  local section_title="\${1}"
104
104
  echo -e "section_end:\`date +%s\`:\${section_title}\\r\\e[0K"
105
105
  }
106
- www 🛡 audit:
106
+ 'www 🛡 audit | dev ':
107
107
  stage: test
108
108
  image: path/to/docker/jobs-default:the-version
109
109
  variables:
@@ -120,9 +120,6 @@ www 🛡 audit:
120
120
  - when: never
121
121
  if: $CI_PIPELINE_SOURCE == "trigger"
122
122
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
123
- - when: never
124
- if: $CI_PIPELINE_SOURCE == "trigger"
125
- - if: $CI_MERGE_REQUEST_ID
126
123
  needs: []
127
124
  retry: &a1
128
125
  max: 2
@@ -131,7 +128,7 @@ www 🛡 audit:
131
128
  - stuck_or_timeout_failure
132
129
  interruptible: true
133
130
  allow_failure: true
134
- www 👮 lint:
131
+ 'www 👮 lint | dev ':
135
132
  stage: test
136
133
  image: path/to/docker/jobs-default:the-version
137
134
  variables:
@@ -152,7 +149,7 @@ www 👮 lint:
152
149
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
153
150
  - collapseable_section_end "nodeinstall"
154
151
  - collapseable_section_start "yarninstall" "Yarn install"
155
- - yarn install --immutable
152
+ - yarn install --immutable --inline-builds
156
153
  - collapseable_section_end "yarninstall"
157
154
  - yarn lint
158
155
  cache:
@@ -168,13 +165,10 @@ www 👮 lint:
168
165
  - when: never
169
166
  if: $CI_PIPELINE_SOURCE == "trigger"
170
167
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
171
- - when: never
172
- if: $CI_PIPELINE_SOURCE == "trigger"
173
- - if: $CI_MERGE_REQUEST_ID
174
168
  needs: []
175
169
  retry: *a1
176
170
  interruptible: true
177
- www 🧪 test:
171
+ 'www 🧪 test | dev ':
178
172
  stage: test
179
173
  image: path/to/docker/jobs-testing-chrome:the-version
180
174
  variables:
@@ -195,7 +189,7 @@ www 🧪 test:
195
189
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
196
190
  - collapseable_section_end "nodeinstall"
197
191
  - collapseable_section_start "yarninstall" "Yarn install"
198
- - yarn install --immutable
192
+ - yarn install --immutable --inline-builds
199
193
  - collapseable_section_end "yarninstall"
200
194
  - yarn test
201
195
  cache:
@@ -211,9 +205,6 @@ www 🧪 test:
211
205
  - when: never
212
206
  if: $CI_PIPELINE_SOURCE == "trigger"
213
207
  - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
214
- - when: never
215
- if: $CI_PIPELINE_SOURCE == "trigger"
216
- - if: $CI_MERGE_REQUEST_ID
217
208
  needs: []
218
209
  retry: *a1
219
210
  interruptible: true
@@ -270,7 +261,7 @@ www 🧪 test:
270
261
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
271
262
  - collapseable_section_end "nodeinstall"
272
263
  - collapseable_section_start "yarninstall" "Yarn install"
273
- - yarn install --immutable
264
+ - yarn install --immutable --inline-builds
274
265
  - collapseable_section_end "yarninstall"
275
266
  - yarn build
276
267
  cache:
@@ -327,7 +318,8 @@ www 🧪 test:
327
318
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
328
319
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
329
320
  - |-
330
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
321
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
322
+ COPY --chown=node:node $APP_DIR .
331
323
  RUN yarn plugin import workspace-tools
332
324
  RUN yarn workspaces focus --production && yarn rebuild"
333
325
  - |-
@@ -480,17 +472,17 @@ www 🧪 test:
480
472
  - when: on_success
481
473
  if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_COMMIT_MESSAGE !~ /^chore\\(release\\).*/
482
474
  needs:
483
- - job: www 👮 lint
475
+ - job: 'www 👮 lint | dev '
484
476
  artifacts: false
485
477
  - job: 'www 🔨 app | dev '
486
478
  artifacts: false
487
479
  - job: 'www 🔨 docker | dev '
488
480
  artifacts: false
489
- - job: www 🧪 test
481
+ - job: 'www 🧪 test | dev '
490
482
  artifacts: false
491
483
  - job: 'www 🧾 sbom | dev '
492
484
  artifacts: true
493
- - job: www 🛡 audit
485
+ - job: 'www 🛡 audit | dev '
494
486
  artifacts: false
495
487
  retry: *a1
496
488
  interruptible: true
@@ -529,6 +521,115 @@ www 🧪 test:
529
521
  retry: *a1
530
522
  interruptible: true
531
523
  allow_failure: true
524
+ 'www 🛡 audit | review ':
525
+ stage: test
526
+ image: path/to/docker/jobs-default:the-version
527
+ variables:
528
+ KUBERNETES_CPU_REQUEST: '0.45'
529
+ KUBERNETES_MEMORY_REQUEST: 1Gi
530
+ KUBERNETES_MEMORY_LIMIT: 4Gi
531
+ script:
532
+ - collapseable_section_start "injectvars" "Injecting variables"
533
+ - export APP_PATH="www"
534
+ - collapseable_section_end "injectvars"
535
+ - cd www
536
+ - yarn npm audit --environment production
537
+ rules:
538
+ - when: never
539
+ if: $CI_PIPELINE_SOURCE == "trigger"
540
+ - if: $CI_MERGE_REQUEST_ID
541
+ needs: []
542
+ retry: *a1
543
+ interruptible: true
544
+ allow_failure: true
545
+ 'www 👮 lint | review ':
546
+ stage: test
547
+ image: path/to/docker/jobs-default:the-version
548
+ variables:
549
+ KUBERNETES_CPU_REQUEST: '0.45'
550
+ KUBERNETES_MEMORY_REQUEST: 1Gi
551
+ KUBERNETES_MEMORY_LIMIT: 4Gi
552
+ script:
553
+ - collapseable_section_start "injectvars" "Injecting variables"
554
+ - export APP_PATH="www"
555
+ - collapseable_section_end "injectvars"
556
+ - collapseable_section_start "nodeinstall" "Ensure node version"
557
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
558
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
559
+ - collapseable_section_end "nodeinstall"
560
+ - cd www
561
+ - collapseable_section_start "nodeinstall" "Ensure node version"
562
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
563
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
564
+ - collapseable_section_end "nodeinstall"
565
+ - collapseable_section_start "yarninstall" "Yarn install"
566
+ - yarn install --immutable --inline-builds
567
+ - collapseable_section_end "yarninstall"
568
+ - yarn lint
569
+ cache:
570
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
571
+ policy: pull-push
572
+ paths:
573
+ - www/.yarn
574
+ fallback_keys:
575
+ - www-yarn
576
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
577
+ policy: pull-push
578
+ paths:
579
+ - www/node_modules
580
+ fallback_keys:
581
+ - www-node-modules
582
+ rules:
583
+ - when: never
584
+ if: $CI_PIPELINE_SOURCE == "trigger"
585
+ - if: $CI_MERGE_REQUEST_ID
586
+ needs: []
587
+ retry: *a1
588
+ interruptible: true
589
+ 'www 🧪 test | review ':
590
+ stage: test
591
+ image: path/to/docker/jobs-testing-chrome:the-version
592
+ variables:
593
+ KUBERNETES_CPU_REQUEST: '0.45'
594
+ KUBERNETES_MEMORY_REQUEST: 1Gi
595
+ KUBERNETES_MEMORY_LIMIT: 4Gi
596
+ script:
597
+ - collapseable_section_start "injectvars" "Injecting variables"
598
+ - export APP_PATH="www"
599
+ - collapseable_section_end "injectvars"
600
+ - collapseable_section_start "nodeinstall" "Ensure node version"
601
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
602
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
603
+ - collapseable_section_end "nodeinstall"
604
+ - cd www
605
+ - collapseable_section_start "nodeinstall" "Ensure node version"
606
+ - if [ -f ~/.nvm/nvm.sh ]; then source ~/.nvm/nvm.sh; fi
607
+ - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
608
+ - collapseable_section_end "nodeinstall"
609
+ - collapseable_section_start "yarninstall" "Yarn install"
610
+ - yarn install --immutable --inline-builds
611
+ - collapseable_section_end "yarninstall"
612
+ - yarn test
613
+ cache:
614
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
615
+ policy: pull-push
616
+ paths:
617
+ - www/.yarn
618
+ fallback_keys:
619
+ - www-yarn
620
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
621
+ policy: pull-push
622
+ paths:
623
+ - www/node_modules
624
+ fallback_keys:
625
+ - www-node-modules
626
+ rules:
627
+ - when: never
628
+ if: $CI_PIPELINE_SOURCE == "trigger"
629
+ - if: $CI_MERGE_REQUEST_ID
630
+ needs: []
631
+ retry: *a1
632
+ interruptible: true
532
633
  'www 🔨 app | review ':
533
634
  stage: build
534
635
  image: path/to/docker/jobs-default:the-version
@@ -582,18 +683,22 @@ www 🧪 test:
582
683
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
583
684
  - collapseable_section_end "nodeinstall"
584
685
  - collapseable_section_start "yarninstall" "Yarn install"
585
- - yarn install --immutable
686
+ - yarn install --immutable --inline-builds
586
687
  - collapseable_section_end "yarninstall"
587
688
  - yarn build
588
689
  cache:
589
- - key: www-yarn
690
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
590
691
  policy: pull-push
591
692
  paths:
592
693
  - www/.yarn
593
- - key: www-node-modules
694
+ fallback_keys:
695
+ - www-yarn
696
+ - key: www-node-modules-mr$CI_MERGE_REQUEST_IID
594
697
  policy: pull-push
595
698
  paths:
596
699
  - www/node_modules
700
+ fallback_keys:
701
+ - www-node-modules
597
702
  artifacts:
598
703
  paths:
599
704
  - www/__build_info.json
@@ -639,7 +744,8 @@ www 🧪 test:
639
744
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
640
745
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
641
746
  - |-
642
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
747
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
748
+ COPY --chown=node:node $APP_DIR .
643
749
  RUN yarn plugin import workspace-tools
644
750
  RUN yarn workspaces focus --production && yarn rebuild"
645
751
  - |-
@@ -662,10 +768,12 @@ www 🧪 test:
662
768
  - docker push $DOCKER_CACHE_IMAGE
663
769
  - collapseable_section_end "docker-push"
664
770
  cache:
665
- - key: www-yarn
771
+ - key: www-yarn-mr$CI_MERGE_REQUEST_IID
666
772
  policy: pull
667
773
  paths:
668
774
  - www/.yarn
775
+ fallback_keys:
776
+ - www-yarn
669
777
  rules:
670
778
  - when: never
671
779
  if: $CI_PIPELINE_SOURCE == "trigger"
@@ -795,17 +903,17 @@ www 🧪 test:
795
903
  - when: on_success
796
904
  if: $CI_MERGE_REQUEST_ID
797
905
  needs:
798
- - job: www 👮 lint
906
+ - job: 'www 👮 lint | review '
799
907
  artifacts: false
800
908
  - job: 'www 🔨 app | review '
801
909
  artifacts: false
802
910
  - job: 'www 🔨 docker | review '
803
911
  artifacts: false
804
- - job: www 🧪 test
912
+ - job: 'www 🧪 test | review '
805
913
  artifacts: false
806
914
  - job: 'www 🧾 sbom | review '
807
915
  artifacts: true
808
- - job: www 🛡 audit
916
+ - job: 'www 🛡 audit | review '
809
917
  artifacts: false
810
918
  retry: *a1
811
919
  interruptible: true
@@ -900,7 +1008,7 @@ www 🧪 test:
900
1008
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
901
1009
  - collapseable_section_end "nodeinstall"
902
1010
  - collapseable_section_start "yarninstall" "Yarn install"
903
- - yarn install --immutable
1011
+ - yarn install --immutable --inline-builds
904
1012
  - collapseable_section_end "yarninstall"
905
1013
  - yarn build
906
1014
  cache:
@@ -957,7 +1065,8 @@ www 🧪 test:
957
1065
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
958
1066
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
959
1067
  - |-
960
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
1068
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
1069
+ COPY --chown=node:node $APP_DIR .
961
1070
  RUN yarn plugin import workspace-tools
962
1071
  RUN yarn workspaces focus --production && yarn rebuild"
963
1072
  - |-
@@ -1205,7 +1314,7 @@ www 🧪 test:
1205
1314
  - if command -v nvm &> /dev/null && [ -f ./.nvmrc ]; then nvm install; fi
1206
1315
  - collapseable_section_end "nodeinstall"
1207
1316
  - collapseable_section_start "yarninstall" "Yarn install"
1208
- - yarn install --immutable
1317
+ - yarn install --immutable --inline-builds
1209
1318
  - collapseable_section_end "yarninstall"
1210
1319
  - yarn build
1211
1320
  cache:
@@ -1262,7 +1371,8 @@ www 🧪 test:
1262
1371
  - export DOCKER_CACHE_IMAGE="asia-east1-docker.pkg.dev/asdf/catladder-deploy/pan-test-app/caches/www"
1263
1372
  - export DOCKER_IMAGE_TAG="$CI_COMMIT_SHA"
1264
1373
  - |-
1265
- export DOCKER_COPY_AND_INSTALL_APP="COPY --chown=node:node $APP_DIR .
1374
+ export DOCKER_COPY_AND_INSTALL_APP="ENV YARN_ENABLE_INLINE_BUILDS=1
1375
+ COPY --chown=node:node $APP_DIR .
1266
1376
  RUN yarn plugin import workspace-tools
1267
1377
  RUN yarn workspaces focus --production && yarn rebuild"
1268
1378
  - |-