indraq_cli 2.4.0 → 2.6.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 (154) hide show
  1. package/CHANGELOG_v2.5.0.md +67 -0
  2. package/CHANGELOG_v2.6.0.md +9 -0
  3. package/LICENSE +21 -21
  4. package/README.md +422 -605
  5. package/RELEASE_CHECKS_v2.5.0.md +93 -0
  6. package/TEST_RESULTS_v2.5.0.txt +46 -0
  7. package/TEST_RESULTS_v2.6.0.txt +16 -0
  8. package/cloud-api/.dockerignore +18 -18
  9. package/cloud-api/.env.example +14 -14
  10. package/cloud-api/.indraq/project.json +4 -0
  11. package/cloud-api/Dockerfile +19 -19
  12. package/cloud-api/README.md +3 -3
  13. package/cloud-api/dist/index.js +57 -7
  14. package/cloud-api/dist/index.js.map +1 -0
  15. package/cloud-api/package.json +1 -1
  16. package/cloud-api/sql/001_init.sql +8 -8
  17. package/cloud-api/sql/002_user_providers_and_project_resources.sql +40 -40
  18. package/cloud-api/sql/003_environment_infrastructure.sql +19 -19
  19. package/cloud-api/sql/004_managed_aws_credentials.sql +20 -20
  20. package/cloud-api/sql/005_project_members_and_resource_grants.sql +22 -22
  21. package/cloud-api/sql/006_catalog_identity_password_security.sql +96 -96
  22. package/cloud-api/sql/007_aws_access_key_rotation.sql +16 -16
  23. package/cloud-api/sql/008_provider_scopes.sql +91 -91
  24. package/cloud-api/src/index.ts +50 -6
  25. package/cloud-api/tsconfig.json +18 -18
  26. package/dist/cli/doctor.command.js +1 -1
  27. package/dist/cli/doctor.command.js.map +1 -1
  28. package/dist/cli/help-content.d.ts.map +1 -1
  29. package/dist/cli/help-content.js +19 -18
  30. package/dist/cli/help-content.js.map +1 -1
  31. package/dist/modules/access/commands/access.command.js +34 -34
  32. package/dist/modules/access/commands/access.command.js.map +1 -1
  33. package/dist/modules/aws/commands/dns.command.d.ts.map +1 -1
  34. package/dist/modules/aws/commands/dns.command.js +3 -2
  35. package/dist/modules/aws/commands/dns.command.js.map +1 -1
  36. package/dist/modules/cloud/commands/cloud.command.d.ts +3 -0
  37. package/dist/modules/cloud/commands/cloud.command.d.ts.map +1 -1
  38. package/dist/modules/cloud/commands/cloud.command.js +121 -34
  39. package/dist/modules/cloud/commands/cloud.command.js.map +1 -1
  40. package/dist/modules/cloud/commands/environment.command.js +1 -1
  41. package/dist/modules/cloud/commands/environment.command.js.map +1 -1
  42. package/dist/modules/cloud/commands/provider.command.js +1 -1
  43. package/dist/modules/cloud/commands/provider.command.js.map +1 -1
  44. package/dist/modules/cloud/index.js +2 -2
  45. package/dist/modules/cloud/index.js.map +1 -1
  46. package/dist/modules/cloud/services/cloud-aws.service.d.ts +1 -1
  47. package/dist/modules/cloud/services/cloud-aws.service.d.ts.map +1 -1
  48. package/dist/modules/cloud/services/cloud-aws.service.js +2 -2
  49. package/dist/modules/cloud/services/cloud-aws.service.js.map +1 -1
  50. package/dist/modules/cloud/services/cloud-ghcr.service.js +2 -2
  51. package/dist/modules/cloud/services/cloud-ghcr.service.js.map +1 -1
  52. package/dist/modules/cloud/services/cloud-jenkins.service.d.ts +1 -1
  53. package/dist/modules/cloud/services/cloud-jenkins.service.d.ts.map +1 -1
  54. package/dist/modules/cloud/services/cloud-jenkins.service.js +157 -33
  55. package/dist/modules/cloud/services/cloud-jenkins.service.js.map +1 -1
  56. package/dist/modules/cloud/services/cloud-npm.service.d.ts +1 -1
  57. package/dist/modules/cloud/services/cloud-npm.service.d.ts.map +1 -1
  58. package/dist/modules/cloud/services/cloud-npm.service.js +2 -2
  59. package/dist/modules/cloud/services/cloud-npm.service.js.map +1 -1
  60. package/dist/modules/cloud/services/project-cleanup.service.d.ts +24 -0
  61. package/dist/modules/cloud/services/project-cleanup.service.d.ts.map +1 -0
  62. package/dist/modules/cloud/services/project-cleanup.service.js +141 -0
  63. package/dist/modules/cloud/services/project-cleanup.service.js.map +1 -0
  64. package/dist/modules/cloud/services/user-provider.service.d.ts +1 -1
  65. package/dist/modules/cloud/services/user-provider.service.d.ts.map +1 -1
  66. package/dist/modules/cloud/services/user-provider.service.js +3 -3
  67. package/dist/modules/cloud/services/user-provider.service.js.map +1 -1
  68. package/dist/modules/configure/configure.command.js +6 -4
  69. package/dist/modules/configure/configure.command.js.map +1 -1
  70. package/dist/modules/deploy/commands/build.command.d.ts.map +1 -1
  71. package/dist/modules/deploy/commands/build.command.js +23 -12
  72. package/dist/modules/deploy/commands/build.command.js.map +1 -1
  73. package/dist/modules/deploy/commands/configure-docker.command.js +6 -6
  74. package/dist/modules/deploy/commands/configure-docker.command.js.map +1 -1
  75. package/dist/modules/deploy/config/docker-config.js +1 -1
  76. package/dist/modules/deploy/config/docker-config.js.map +1 -1
  77. package/dist/modules/deploy/index.js +1 -1
  78. package/dist/modules/deploy/index.js.map +1 -1
  79. package/dist/modules/deploy/services/docker.service.js +1 -1
  80. package/dist/modules/deploy/services/docker.service.js.map +1 -1
  81. package/dist/modules/dockerfile/services/project-docker.service.d.ts +9 -0
  82. package/dist/modules/dockerfile/services/project-docker.service.d.ts.map +1 -0
  83. package/dist/modules/dockerfile/services/project-docker.service.js +122 -0
  84. package/dist/modules/dockerfile/services/project-docker.service.js.map +1 -0
  85. package/dist/modules/jenkins/commands/create-deployment.command.js +4 -4
  86. package/dist/modules/jenkins/commands/create-deployment.command.js.map +1 -1
  87. package/dist/modules/jenkins/index.js +1 -1
  88. package/dist/modules/jenkins/index.js.map +1 -1
  89. package/dist/modules/mobile/commands/mobile-environment.command.js +1 -1
  90. package/dist/modules/mobile/commands/mobile-environment.command.js.map +1 -1
  91. package/dist/modules/mobile/commands/mobile-prebuild.command.js +1 -1
  92. package/dist/modules/mobile/commands/mobile-prebuild.command.js.map +1 -1
  93. package/dist/modules/mobile/commands/ota.command.js +3 -3
  94. package/dist/modules/mobile/commands/ota.command.js.map +1 -1
  95. package/dist/modules/mobile/index.d.ts.map +1 -1
  96. package/dist/modules/mobile/index.js +8 -7
  97. package/dist/modules/mobile/index.js.map +1 -1
  98. package/dist/modules/mobile/services/mobile-project-directory.d.ts +3 -0
  99. package/dist/modules/mobile/services/mobile-project-directory.d.ts.map +1 -0
  100. package/dist/modules/mobile/services/mobile-project-directory.js +31 -0
  101. package/dist/modules/mobile/services/mobile-project-directory.js.map +1 -0
  102. package/dist/modules/mobile/services/ota-setup.service.d.ts.map +1 -1
  103. package/dist/modules/mobile/services/ota-setup.service.js +5 -3
  104. package/dist/modules/mobile/services/ota-setup.service.js.map +1 -1
  105. package/dist/modules/prebuild/commands/prebuild.command.d.ts +4 -0
  106. package/dist/modules/prebuild/commands/prebuild.command.d.ts.map +1 -1
  107. package/dist/modules/prebuild/commands/prebuild.command.js +155 -100
  108. package/dist/modules/prebuild/commands/prebuild.command.js.map +1 -1
  109. package/dist/modules/prebuild/index.js +2 -2
  110. package/dist/modules/prebuild/index.js.map +1 -1
  111. package/dist/modules/prebuild/setup-plan.d.ts +11 -0
  112. package/dist/modules/prebuild/setup-plan.d.ts.map +1 -0
  113. package/dist/modules/prebuild/setup-plan.js +58 -0
  114. package/dist/modules/prebuild/setup-plan.js.map +1 -0
  115. package/dist/modules/proxy/services/npm-api.service.d.ts +1 -0
  116. package/dist/modules/proxy/services/npm-api.service.d.ts.map +1 -1
  117. package/dist/modules/proxy/services/npm-api.service.js +1 -0
  118. package/dist/modules/proxy/services/npm-api.service.js.map +1 -1
  119. package/dist/modules/scaffold/commands/init.command.d.ts.map +1 -1
  120. package/dist/modules/scaffold/commands/init.command.js +33 -18
  121. package/dist/modules/scaffold/commands/init.command.js.map +1 -1
  122. package/dist/modules/scaffold/types.d.ts +3 -1
  123. package/dist/modules/scaffold/types.d.ts.map +1 -1
  124. package/dist/modules/scopes/commands/scope.command.d.ts +3 -1
  125. package/dist/modules/scopes/commands/scope.command.d.ts.map +1 -1
  126. package/dist/modules/scopes/commands/scope.command.js +15 -8
  127. package/dist/modules/scopes/commands/scope.command.js.map +1 -1
  128. package/dist/modules/scopes/index.js +1 -1
  129. package/dist/modules/scopes/index.js.map +1 -1
  130. package/dist/modules/scopes/services/scope-native.service.d.ts.map +1 -1
  131. package/dist/modules/scopes/services/scope-native.service.js +16 -5
  132. package/dist/modules/scopes/services/scope-native.service.js.map +1 -1
  133. package/dist/modules/setup/commands/setup.command.d.ts.map +1 -1
  134. package/dist/modules/setup/commands/setup.command.js +41 -24
  135. package/dist/modules/setup/commands/setup.command.js.map +1 -1
  136. package/dist/modules/users/commands/user.command.d.ts.map +1 -1
  137. package/dist/modules/users/commands/user.command.js +10 -2
  138. package/dist/modules/users/commands/user.command.js.map +1 -1
  139. package/dist/modules/users/providers/jenkins-user.provider.js +95 -95
  140. package/dist/modules/users/providers/npm-user.provider.d.ts.map +1 -1
  141. package/dist/modules/users/providers/npm-user.provider.js +31 -2
  142. package/dist/modules/users/providers/npm-user.provider.js.map +1 -1
  143. package/dist/shared/config/config-files.js +7 -7
  144. package/dist/shared/jenkins/role-strategy-groovy.js +84 -84
  145. package/dist/shared/process/run-npx.d.ts +4 -0
  146. package/dist/shared/process/run-npx.d.ts.map +1 -0
  147. package/dist/shared/process/run-npx.js +31 -0
  148. package/dist/shared/process/run-npx.js.map +1 -0
  149. package/docs/ARCHITECTURE.md +7 -7
  150. package/docs/CREATE-DEPLOYMENT-reference.groovy +8 -8
  151. package/docs/README_v2.6.0_DETAILED.md +1021 -0
  152. package/package.json +12 -5
  153. package/templates/jenkins/CREATE-DEPLOYMENT.groovy +8 -8
  154. package/templates/jenkins/Jenkinsfile-Mobile-App +759 -759
@@ -16,7 +16,7 @@ Supported presets include:
16
16
  - user frontend + admin frontend + backend (`multiweb`)
17
17
  - mobile
18
18
 
19
- Each web component has its own path, framework, image name, ports and health endpoint. GHCR/Jenkins resources are keyed by component and environment.
19
+ Each web component has its own path, framework, image name, ports and health endpoint. GitHub Packages/Jenkins resources are keyed by component and environment.
20
20
 
21
21
  ## Deployment topology — where it runs
22
22
 
@@ -32,7 +32,7 @@ The Jenkins stage is explicit so a production backup named `backup-server` canno
32
32
 
33
33
  ## Provider scopes and credentials
34
34
 
35
- AWS, NPM, Jenkins and GHCR are organization provider scopes. Users see/use only assigned scopes. Their native/provider credentials are resolved only when required and are not copied into project folders.
35
+ AWS, NPM, Jenkins and GitHub Packages are organization provider scopes. Users see/use only assigned scopes. Their native/provider credentials are resolved only when required and are not copied into project folders.
36
36
 
37
37
  A project can bind different provider scopes for each environment. This allows the same component/pipeline name to exist on Jenkins A for the primary server and Jenkins B for the backup server, with separate NPM instances as well.
38
38
 
@@ -51,9 +51,9 @@ Route53 PRIMARY/SECONDARY remains a DNS-resource decision. Project topology prim
51
51
  For one or more selected components, IndraQ:
52
52
 
53
53
  1. builds the component image once
54
- 2. pushes the selected tag(s) once to GHCR
54
+ 2. pushes the selected tag(s) once to GitHub Packages
55
55
  3. resolves the immutable image digest
56
- 4. verifies all selected environments point at the same logical GHCR image
56
+ 4. verifies all selected environments point at the same logical GitHub Packages image
57
57
  5. triggers each environment's own Jenkins controller sequentially with the same tag + digest
58
58
  6. stops on the first failed target and reports that environment
59
59
 
@@ -61,15 +61,15 @@ This prevents primary/backup servers from receiving different image bytes during
61
61
 
62
62
  ## Project resources
63
63
 
64
- Projects keep intent and external-resource associations, including GHCR image repositories, Jenkins jobs, Route53 routing/health checks, and NPM proxy hosts. Project membership controls who can discover/re-link a project. Resource grants record access to individual AWS, NPM, and Jenkins resources and are audited.
64
+ Projects keep intent and external-resource associations, including GitHub Packages image repositories, Jenkins jobs, Route53 routing/health checks, and NPM proxy hosts. Project membership controls who can discover/re-link a project. Resource grants record access to individual AWS, NPM, and Jenkins resources and are audited.
65
65
 
66
66
  ## Prebuild
67
67
 
68
- Prebuild reconciles rather than blindly creates. Required infrastructure is GHCR + Jenkins. Route53/NPM remain optional.
68
+ Prebuild reconciles rather than blindly creates. Required infrastructure is GitHub Packages + Jenkins. Route53/NPM remain optional.
69
69
 
70
70
  v2.3 adds:
71
71
 
72
- - `--required-only` — reconcile GHCR/Jenkins only
72
+ - `--required-only` — reconcile GitHub Packages/Jenkins only
73
73
  - `--all-targets` — reconcile every configured project deployment environment
74
74
 
75
75
  Provider scope selection is environment-specific. If there is one unambiguous eligible missing scope, it can be linked directly; real choices are still presented interactively.
@@ -18,7 +18,7 @@ properties([
18
18
  string(
19
19
  name: 'IMAGE_NAME',
20
20
  defaultValue: '',
21
- description: 'GHCR package name and generated Jenkins job name. Example: wholesum-order-service',
21
+ description: 'GitHub Packages image name and generated Jenkins job name. Example: wholesum-order-service',
22
22
  trim: true
23
23
  ),
24
24
  string(
@@ -678,7 +678,7 @@ pipeline {
678
678
  [key: 'PACKAGE_DIGEST', value: '$.package.package_version.container_metadata.tag.digest'],
679
679
  [key: 'EVENT_ACTION', value: '$.action']
680
680
  ],
681
- causeString: 'GHCR: $PACKAGE_NAME:$PACKAGE_TAG',
681
+ causeString: 'GitHub Packages: $PACKAGE_NAME:$PACKAGE_TAG',
682
682
  token: 'wholesum-order-webhook',
683
683
  printContributedVariables: true,
684
684
  printPostContent: false,
@@ -704,7 +704,7 @@ pipeline {
704
704
  env.DEPLOY_TAG = env.PACKAGE_TAG.trim()
705
705
  env.DEPLOY_SOURCE = 'GITHUB_WEBHOOK'
706
706
  env.DEPLOY_ACTION = 'DEPLOY'
707
- echo 'GHCR webhook deployment detected.'
707
+ echo 'GitHub Packages webhook deployment detected.'
708
708
  } else {
709
709
  if (!params.IMAGE_TAG?.trim()) {
710
710
  error 'IMAGE_TAG is required for manual deployment.'
@@ -762,7 +762,7 @@ pipeline {
762
762
  }
763
763
  }
764
764
 
765
- stage('Login to GHCR') {
765
+ stage('Login to GitHub Packages') {
766
766
  steps {
767
767
  withCredentials([
768
768
  usernamePassword(
@@ -988,8 +988,8 @@ pipelineJob(JOB_NAME) {
988
988
  Automatically generated Docker deployment pipeline.
989
989
 
990
990
  Service: ${JOB_NAME}
991
- GHCR Image: ${GHCR_IMAGE}
992
- GHCR Credential: ${GHCR_CREDENTIAL_ID}
991
+ GitHub Packages Image: ${GHCR_IMAGE}
992
+ GitHub Packages Credential: ${GHCR_CREDENTIAL_ID}
993
993
  Container: ${DOCKER_CONTAINER}
994
994
  Host Port: ${DOCKER_HOST_PORT}
995
995
  Container Port: ${DOCKER_CONTAINER_PORT}
@@ -1073,7 +1073,7 @@ Generated by: CREATE-DEPLOYMENT
1073
1073
  echo '=============================================='
1074
1074
  echo ''
1075
1075
  echo "Jenkins Job: ${jobName}"
1076
- echo "GHCR Image: ${imageName}"
1076
+ echo "GitHub Packages Image: ${imageName}"
1077
1077
  echo "Container: ${containerName}"
1078
1078
  echo "Application: ${appType}"
1079
1079
  if (appType == 'FRONTEND') {
@@ -1090,7 +1090,7 @@ Generated by: CREATE-DEPLOYMENT
1090
1090
  echo "Health Endpoint: ${healthEndpoint}"
1091
1091
  }
1092
1092
 
1093
- echo 'Automatic GHCR deployment: ENABLED'
1093
+ echo 'Automatic GitHub Packages deployment: ENABLED'
1094
1094
  echo 'Manual deployment: ENABLED'
1095
1095
  echo 'Manual rollback: ENABLED'
1096
1096
  echo 'Slack notifications: ENABLED'