@ship.zone/ci-spec 2.0.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 (116) hide show
  1. package/.smartconfig.json +46 -0
  2. package/changelog.md +190 -0
  3. package/conformance/archive-cases.json +446 -0
  4. package/conformance/ci-actions/compile-invalid/build-arg-secret-collision.yml +31 -0
  5. package/conformance/ci-actions/compile-invalid/candidate-without-needs.yml +36 -0
  6. package/conformance/ci-actions/compile-invalid/needs-wider-triggers.yml +42 -0
  7. package/conformance/ci-actions/compile-invalid/npm-read-registry-not-allowlisted.yml +34 -0
  8. package/conformance/ci-actions/compile-invalid/publish-job-excludes-tag.yml +57 -0
  9. package/conformance/ci-actions/compile-invalid/shared-memory-above-memory.yml +28 -0
  10. package/conformance/ci-actions/compile-invalid/trigger-kind-without-job.yml +30 -0
  11. package/conformance/ci-actions/invalid/alias-affix-invalid.yml +33 -0
  12. package/conformance/ci-actions/invalid/alias.yml +32 -0
  13. package/conformance/ci-actions/invalid/bridge-network.yml +27 -0
  14. package/conformance/ci-actions/invalid/build-darwin-platform.yml +24 -0
  15. package/conformance/ci-actions/invalid/build-with-steps.yml +27 -0
  16. package/conformance/ci-actions/invalid/concurrency-empty-group.yml +28 -0
  17. package/conformance/ci-actions/invalid/concurrency-without-cancel-in-progress.yml +27 -0
  18. package/conformance/ci-actions/invalid/container-job-build-profile.yml +25 -0
  19. package/conformance/ci-actions/invalid/custom-tag.txt +23 -0
  20. package/conformance/ci-actions/invalid/duplicate-key.txt +24 -0
  21. package/conformance/ci-actions/invalid/egress-bare-wildcard.yml +29 -0
  22. package/conformance/ci-actions/invalid/egress-empty-allowlist.yml +28 -0
  23. package/conformance/ci-actions/invalid/egress-ip-literal.yml +29 -0
  24. package/conformance/ci-actions/invalid/egress-single-label-wildcard.yml +29 -0
  25. package/conformance/ci-actions/invalid/job-publish-permission.yml +28 -0
  26. package/conformance/ci-actions/invalid/job-trigger-undeclared-kind.yml +27 -0
  27. package/conformance/ci-actions/invalid/literal-alias-affix.yml +33 -0
  28. package/conformance/ci-actions/invalid/missing-spec.yml +24 -0
  29. package/conformance/ci-actions/invalid/multiple-documents.yml +25 -0
  30. package/conformance/ci-actions/invalid/npm-read-invalid-scope.yml +33 -0
  31. package/conformance/ci-actions/invalid/oci-darwin-platform.yml +25 -0
  32. package/conformance/ci-actions/invalid/permission-without-publication.yml +31 -0
  33. package/conformance/ci-actions/invalid/publish-order-duplicate.yml +50 -0
  34. package/conformance/ci-actions/invalid/publish-order-missing-kind.yml +48 -0
  35. package/conformance/ci-actions/invalid/publish-order-undeclared-kind.yml +45 -0
  36. package/conformance/ci-actions/invalid/publish-without-permission.yml +31 -0
  37. package/conformance/ci-actions/invalid/publish-without-tag-trigger.yml +31 -0
  38. package/conformance/ci-actions/invalid/release-notes-without-assets.yml +46 -0
  39. package/conformance/ci-actions/invalid/reserved-label-prefix.yml +25 -0
  40. package/conformance/ci-actions/invalid/reserved-label.yml +25 -0
  41. package/conformance/ci-actions/invalid/retention-above-maximum.yml +83 -0
  42. package/conformance/ci-actions/invalid/retention-below-minimum.yml +83 -0
  43. package/conformance/ci-actions/invalid/schema-version-field.yml +26 -0
  44. package/conformance/ci-actions/invalid/shared-memory-below-minimum.yml +28 -0
  45. package/conformance/ci-actions/invalid/shell-string.yml +21 -0
  46. package/conformance/ci-actions/invalid/spec-number.yml +25 -0
  47. package/conformance/ci-actions/invalid/spec-prerelease.yml +25 -0
  48. package/conformance/ci-actions/invalid/spec-range.yml +25 -0
  49. package/conformance/ci-actions/invalid/timeout-above-maximum.yml +26 -0
  50. package/conformance/ci-actions/invalid/timeout-below-minimum.yml +26 -0
  51. package/conformance/ci-actions/invalid/unknown-alias-kind.yml +31 -0
  52. package/conformance/ci-actions/invalid/unknown-key.yml +24 -0
  53. package/conformance/ci-actions/invalid/vm-darwin-candidate.yml +38 -0
  54. package/conformance/ci-actions/invalid/vm-darwin-shared-memory.yml +28 -0
  55. package/conformance/ci-actions/invalid/vm-oci-execution.yml +25 -0
  56. package/conformance/ci-actions/invalid/vm-unsupported-platform.yml +25 -0
  57. package/conformance/ci-actions/invalid/vm-without-platform.yml +24 -0
  58. package/conformance/ci-actions/valid/concurrency.yml +83 -0
  59. package/conformance/ci-actions/valid/egress.yml +40 -0
  60. package/conformance/ci-actions/valid/image-build.yml +80 -0
  61. package/conformance/ci-actions/valid/matrix.yml +45 -0
  62. package/conformance/ci-actions/valid/minimal.yml +25 -0
  63. package/conformance/ci-actions/valid/npm-read.yml +60 -0
  64. package/conformance/ci-actions/valid/release-assets.yml +114 -0
  65. package/conformance/ci-actions/valid/release-signing.yml +71 -0
  66. package/conformance/ci-actions/valid/release.yml +109 -0
  67. package/conformance/ci-actions/valid/resources.yml +79 -0
  68. package/conformance/ci-actions/valid/vm.yml +77 -0
  69. package/conformance/compile-cases.json +5885 -0
  70. package/conformance/compile-cases.schema.json +766 -0
  71. package/conformance/digest-cases.json +144 -0
  72. package/conformance/runner-cases.json +1238 -0
  73. package/conformance/runner-jobs/invalid/bridge-network.json +70 -0
  74. package/conformance/runner-jobs/invalid/build-darwin-platform.json +100 -0
  75. package/conformance/runner-jobs/invalid/build-with-steps.json +111 -0
  76. package/conformance/runner-jobs/invalid/build-without-microvm.json +100 -0
  77. package/conformance/runner-jobs/invalid/egress-empty-allowlist.json +71 -0
  78. package/conformance/runner-jobs/invalid/mutable-image.json +70 -0
  79. package/conformance/runner-jobs/invalid/npm-read-reserved-environment.json +82 -0
  80. package/conformance/runner-jobs/invalid/oci-darwin-platform.json +71 -0
  81. package/conformance/runner-jobs/invalid/push-permission-container.json +70 -0
  82. package/conformance/runner-jobs/invalid/shared-memory-below-minimum.json +71 -0
  83. package/conformance/runner-jobs/invalid/timeout-missing.json +69 -0
  84. package/conformance/runner-jobs/invalid/vm-without-microvm.json +82 -0
  85. package/conformance/runner-jobs/valid/candidate-test.json +72 -0
  86. package/conformance/runner-jobs/valid/egress.json +80 -0
  87. package/conformance/runner-jobs/valid/image-build.json +100 -0
  88. package/conformance/runner-jobs/valid/minimal.json +70 -0
  89. package/conformance/runner-jobs/valid/npm-read.json +81 -0
  90. package/conformance/runner-jobs/valid/resources.json +71 -0
  91. package/conformance/runner-jobs/valid/timeout-retention-defaults.json +91 -0
  92. package/conformance/runner-jobs/valid/vm-darwin.json +70 -0
  93. package/conformance/runner-jobs/valid/vm.json +82 -0
  94. package/conformance/runner-messages.json +2035 -0
  95. package/conformance/version-cases.json +125 -0
  96. package/dist_ts/00_commitinfo_data.d.ts +8 -0
  97. package/dist_ts/00_commitinfo_data.js +9 -0
  98. package/dist_ts/constants.d.ts +199 -0
  99. package/dist_ts/constants.js +106 -0
  100. package/dist_ts/index.d.ts +1 -0
  101. package/dist_ts/index.js +2 -0
  102. package/dist_ts/plugins.d.ts +1 -0
  103. package/dist_ts/plugins.js +3 -0
  104. package/examples/ci_actions.yml +64 -0
  105. package/license.md +21 -0
  106. package/package.json +72 -0
  107. package/readme.md +146 -0
  108. package/schemas/ci_actions.schema.json +1664 -0
  109. package/schemas/runner-job.schema.json +1172 -0
  110. package/spec/ci-actions.md +433 -0
  111. package/spec/runner-protocol.md +378 -0
  112. package/spec/runner.openapi.json +2182 -0
  113. package/ts/00_commitinfo_data.ts +8 -0
  114. package/ts/constants.ts +112 -0
  115. package/ts/index.ts +1 -0
  116. package/ts/plugins.ts +1 -0
@@ -0,0 +1,125 @@
1
+ {
2
+ "spec": "2.0.0",
3
+ "outcomes": [
4
+ "accepted",
5
+ "malformed",
6
+ "major-mismatch",
7
+ "newer"
8
+ ],
9
+ "cases": [
10
+ {
11
+ "id": "equal",
12
+ "implemented": "1.0.0",
13
+ "declared": "1.0.0",
14
+ "outcome": "accepted"
15
+ },
16
+ {
17
+ "id": "older-patch",
18
+ "implemented": "1.4.2",
19
+ "declared": "1.4.1",
20
+ "outcome": "accepted"
21
+ },
22
+ {
23
+ "id": "older-minor",
24
+ "implemented": "1.4.0",
25
+ "declared": "1.2.9",
26
+ "outcome": "accepted"
27
+ },
28
+ {
29
+ "id": "numeric-minor-order-accepted",
30
+ "implemented": "1.10.0",
31
+ "declared": "1.9.0",
32
+ "outcome": "accepted"
33
+ },
34
+ {
35
+ "id": "zero-major-older-minor",
36
+ "implemented": "0.3.0",
37
+ "declared": "0.2.5",
38
+ "outcome": "accepted"
39
+ },
40
+ {
41
+ "id": "newer-patch",
42
+ "implemented": "1.4.1",
43
+ "declared": "1.4.2",
44
+ "outcome": "newer"
45
+ },
46
+ {
47
+ "id": "newer-minor",
48
+ "implemented": "1.4.0",
49
+ "declared": "1.5.0",
50
+ "outcome": "newer"
51
+ },
52
+ {
53
+ "id": "numeric-minor-order-newer",
54
+ "implemented": "1.9.0",
55
+ "declared": "1.10.0",
56
+ "outcome": "newer"
57
+ },
58
+ {
59
+ "id": "older-major",
60
+ "implemented": "2.0.0",
61
+ "declared": "1.9.9",
62
+ "outcome": "major-mismatch"
63
+ },
64
+ {
65
+ "id": "newer-major",
66
+ "implemented": "1.9.9",
67
+ "declared": "2.0.0",
68
+ "outcome": "major-mismatch"
69
+ },
70
+ {
71
+ "id": "zero-major-against-one",
72
+ "implemented": "1.0.0",
73
+ "declared": "0.2.0",
74
+ "outcome": "major-mismatch"
75
+ },
76
+ {
77
+ "id": "two-components",
78
+ "implemented": "1.0.0",
79
+ "declared": "1.0",
80
+ "outcome": "malformed"
81
+ },
82
+ {
83
+ "id": "prefix",
84
+ "implemented": "1.0.0",
85
+ "declared": "v1.0.0",
86
+ "outcome": "malformed"
87
+ },
88
+ {
89
+ "id": "prerelease",
90
+ "implemented": "1.0.0",
91
+ "declared": "1.0.0-rc.1",
92
+ "outcome": "malformed"
93
+ },
94
+ {
95
+ "id": "build-metadata",
96
+ "implemented": "1.0.0",
97
+ "declared": "1.0.0+build.1",
98
+ "outcome": "malformed"
99
+ },
100
+ {
101
+ "id": "leading-zero",
102
+ "implemented": "1.1.0",
103
+ "declared": "1.01.0",
104
+ "outcome": "malformed"
105
+ },
106
+ {
107
+ "id": "range",
108
+ "implemented": "1.0.0",
109
+ "declared": "^1.0.0",
110
+ "outcome": "malformed"
111
+ },
112
+ {
113
+ "id": "unsafe-component",
114
+ "implemented": "1.0.0",
115
+ "declared": "1.1000000000000000.0",
116
+ "outcome": "malformed"
117
+ },
118
+ {
119
+ "id": "empty",
120
+ "implemented": "1.0.0",
121
+ "declared": "",
122
+ "outcome": "malformed"
123
+ }
124
+ ]
125
+ }
@@ -0,0 +1,8 @@
1
+ /**
2
+ * autocreated commitinfo by @push.rocks/commitinfo
3
+ */
4
+ export declare const commitinfo: {
5
+ name: string;
6
+ version: string;
7
+ description: string;
8
+ };
@@ -0,0 +1,9 @@
1
+ /**
2
+ * autocreated commitinfo by @push.rocks/commitinfo
3
+ */
4
+ export const commitinfo = {
5
+ name: '@ship.zone/ci-spec',
6
+ version: '2.0.0',
7
+ description: 'The ship.zone CI standard: language-neutral CI workflow and runner protocol specifications.'
8
+ };
9
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSxvQkFBb0I7SUFDMUIsT0FBTyxFQUFFLE9BQU87SUFDaEIsV0FBVyxFQUFFLDZGQUE2RjtDQUMzRyxDQUFBIn0=
@@ -0,0 +1,199 @@
1
+ /**
2
+ * The specification version: the published `@ship.zone/ci-spec` package version. It is the
3
+ * version an implementation built against this package implements, and the only version a
4
+ * workflow, compiled job, or runner protocol message carries (as `spec`).
5
+ */
6
+ export declare const ciSpecVersion: string;
7
+ export declare const ciSpecStatus: "draft";
8
+ export declare const runnerProtocolBasePath: "/api/runner";
9
+ export declare const maximumArchivePathMetadataBytes: 134217728;
10
+ /**
11
+ * Execution profile identifiers. The normative schemas define each identifier once
12
+ * (`containerProfile`, `imageBuildProfile`, and `vmProfile`); the conformance tests assert both
13
+ * sources agree.
14
+ */
15
+ export declare const executionProfileIdentifiers: {
16
+ readonly container: "oci";
17
+ readonly imageBuild: "oci-image";
18
+ readonly virtualMachine: "vm";
19
+ };
20
+ /**
21
+ * Runner feature identifiers, mirrored from the runner job schema `feature` definition.
22
+ */
23
+ export declare const runnerFeatureIdentifiers: readonly ["source.tar-gz", "artifacts", "caches"];
24
+ /**
25
+ * Lease feature identifiers a runner may advertise in `RunnerCapabilities.leaseFeatures`, mirrored
26
+ * from the OpenAPI `LeaseFeature` component.
27
+ */
28
+ export declare const leaseFeatureIdentifiers: readonly ["image-pull-grants", "candidate-bindings", "npm-read-grants"];
29
+ /**
30
+ * The layers of `ci_actions.yml` compilation, in evaluation order (spec/ci-actions.md, Compilation
31
+ * Failures).
32
+ */
33
+ export declare const compilationFailureLayers: readonly ["source", "yaml", "version", "schema", "workflow", "policy", "run"];
34
+ /**
35
+ * Every compilation failure code with its layer, in precedence order, mirrored from
36
+ * `conformance/compile-cases.json` `failureCodes`; the conformance tests assert both sources and the
37
+ * prose table agree.
38
+ */
39
+ export declare const compilationFailureCodes: readonly [{
40
+ readonly code: "workflow_too_large";
41
+ readonly layer: "source";
42
+ }, {
43
+ readonly code: "workflow_encoding_invalid";
44
+ readonly layer: "source";
45
+ }, {
46
+ readonly code: "workflow_yaml_syntax";
47
+ readonly layer: "yaml";
48
+ }, {
49
+ readonly code: "workflow_yaml_document_count";
50
+ readonly layer: "yaml";
51
+ }, {
52
+ readonly code: "workflow_yaml_directive";
53
+ readonly layer: "yaml";
54
+ }, {
55
+ readonly code: "workflow_yaml_duplicate_key";
56
+ readonly layer: "yaml";
57
+ }, {
58
+ readonly code: "workflow_yaml_key_type";
59
+ readonly layer: "yaml";
60
+ }, {
61
+ readonly code: "workflow_yaml_anchor";
62
+ readonly layer: "yaml";
63
+ }, {
64
+ readonly code: "workflow_yaml_merge_key";
65
+ readonly layer: "yaml";
66
+ }, {
67
+ readonly code: "workflow_yaml_tag";
68
+ readonly layer: "yaml";
69
+ }, {
70
+ readonly code: "workflow_number_invalid";
71
+ readonly layer: "yaml";
72
+ }, {
73
+ readonly code: "spec_incompatible";
74
+ readonly layer: "version";
75
+ }, {
76
+ readonly code: "workflow_schema_invalid";
77
+ readonly layer: "schema";
78
+ }, {
79
+ readonly code: "trigger_pattern_invalid";
80
+ readonly layer: "workflow";
81
+ }, {
82
+ readonly code: "needs_unknown";
83
+ readonly layer: "workflow";
84
+ }, {
85
+ readonly code: "needs_cycle";
86
+ readonly layer: "workflow";
87
+ }, {
88
+ readonly code: "expansion_limit_exceeded";
89
+ readonly layer: "workflow";
90
+ }, {
91
+ readonly code: "needs_trigger_wider";
92
+ readonly layer: "workflow";
93
+ }, {
94
+ readonly code: "trigger_kind_unused";
95
+ readonly layer: "workflow";
96
+ }, {
97
+ readonly code: "permission_escalation";
98
+ readonly layer: "workflow";
99
+ }, {
100
+ readonly code: "permission_insufficient";
101
+ readonly layer: "workflow";
102
+ }, {
103
+ readonly code: "environment_conflict";
104
+ readonly layer: "workflow";
105
+ }, {
106
+ readonly code: "environment_limit_exceeded";
107
+ readonly layer: "workflow";
108
+ }, {
109
+ readonly code: "command_limit_exceeded";
110
+ readonly layer: "workflow";
111
+ }, {
112
+ readonly code: "transfer_name_duplicate";
113
+ readonly layer: "workflow";
114
+ }, {
115
+ readonly code: "cache_path_overlap";
116
+ readonly layer: "workflow";
117
+ }, {
118
+ readonly code: "resources_invalid";
119
+ readonly layer: "workflow";
120
+ }, {
121
+ readonly code: "network_host_duplicate";
122
+ readonly layer: "workflow";
123
+ }, {
124
+ readonly code: "npm_read_invalid";
125
+ readonly layer: "workflow";
126
+ }, {
127
+ readonly code: "build_input_conflict";
128
+ readonly layer: "workflow";
129
+ }, {
130
+ readonly code: "candidate_reference_invalid";
131
+ readonly layer: "workflow";
132
+ }, {
133
+ readonly code: "candidate_platform_missing";
134
+ readonly layer: "workflow";
135
+ }, {
136
+ readonly code: "publish_reference_invalid";
137
+ readonly layer: "workflow";
138
+ }, {
139
+ readonly code: "policy_limit_exceeded";
140
+ readonly layer: "policy";
141
+ }, {
142
+ readonly code: "policy_timeout_exceeded";
143
+ readonly layer: "policy";
144
+ }, {
145
+ readonly code: "policy_retention_exceeded";
146
+ readonly layer: "policy";
147
+ }, {
148
+ readonly code: "policy_egress_denied";
149
+ readonly layer: "policy";
150
+ }, {
151
+ readonly code: "policy_npm_registry_denied";
152
+ readonly layer: "policy";
153
+ }, {
154
+ readonly code: "policy_denied";
155
+ readonly layer: "policy";
156
+ }, {
157
+ readonly code: "manual_input_invalid";
158
+ readonly layer: "run";
159
+ }, {
160
+ readonly code: "tag_version_required";
161
+ readonly layer: "run";
162
+ }, {
163
+ readonly code: "alias_invalid";
164
+ readonly layer: "run";
165
+ }, {
166
+ readonly code: "alias_duplicate";
167
+ readonly layer: "run";
168
+ }, {
169
+ readonly code: "secret_untrusted";
170
+ readonly layer: "run";
171
+ }, {
172
+ readonly code: "npm_read_untrusted";
173
+ readonly layer: "run";
174
+ }, {
175
+ readonly code: "secret_unknown";
176
+ readonly layer: "run";
177
+ }, {
178
+ readonly code: "protected_secret_denied";
179
+ readonly layer: "run";
180
+ }, {
181
+ readonly code: "secret_too_short";
182
+ readonly layer: "run";
183
+ }];
184
+ export declare const ciSpecAssetPaths: {
185
+ readonly runnerOpenApi: "spec/runner.openapi.json";
186
+ readonly runnerProtocol: "spec/runner-protocol.md";
187
+ readonly ciActionsProtocol: "spec/ci-actions.md";
188
+ readonly runnerJobSchema: "schemas/runner-job.schema.json";
189
+ readonly ciActionsSchema: "schemas/ci_actions.schema.json";
190
+ readonly runnerConformanceCases: "conformance/runner-cases.json";
191
+ readonly runnerMessageCases: "conformance/runner-messages.json";
192
+ readonly digestCases: "conformance/digest-cases.json";
193
+ readonly archiveCases: "conformance/archive-cases.json";
194
+ readonly versionCases: "conformance/version-cases.json";
195
+ readonly compileCases: "conformance/compile-cases.json";
196
+ readonly compileCasesSchema: "conformance/compile-cases.schema.json";
197
+ readonly ciActionsConformanceDirectory: "conformance/ci-actions";
198
+ readonly runnerJobConformanceDirectory: "conformance/runner-jobs";
199
+ };
@@ -0,0 +1,106 @@
1
+ import { commitinfo } from './00_commitinfo_data.js';
2
+ /**
3
+ * The specification version: the published `@ship.zone/ci-spec` package version. It is the
4
+ * version an implementation built against this package implements, and the only version a
5
+ * workflow, compiled job, or runner protocol message carries (as `spec`).
6
+ */
7
+ export const ciSpecVersion = commitinfo.version;
8
+ export const ciSpecStatus = 'draft';
9
+ export const runnerProtocolBasePath = '/api/runner';
10
+ export const maximumArchivePathMetadataBytes = 134_217_728;
11
+ /**
12
+ * Execution profile identifiers. The normative schemas define each identifier once
13
+ * (`containerProfile`, `imageBuildProfile`, and `vmProfile`); the conformance tests assert both
14
+ * sources agree.
15
+ */
16
+ export const executionProfileIdentifiers = {
17
+ container: 'oci',
18
+ imageBuild: 'oci-image',
19
+ virtualMachine: 'vm',
20
+ };
21
+ /**
22
+ * Runner feature identifiers, mirrored from the runner job schema `feature` definition.
23
+ */
24
+ export const runnerFeatureIdentifiers = ['source.tar-gz', 'artifacts', 'caches'];
25
+ /**
26
+ * Lease feature identifiers a runner may advertise in `RunnerCapabilities.leaseFeatures`, mirrored
27
+ * from the OpenAPI `LeaseFeature` component.
28
+ */
29
+ export const leaseFeatureIdentifiers = ['image-pull-grants', 'candidate-bindings', 'npm-read-grants'];
30
+ /**
31
+ * The layers of `ci_actions.yml` compilation, in evaluation order (spec/ci-actions.md, Compilation
32
+ * Failures).
33
+ */
34
+ export const compilationFailureLayers = ['source', 'yaml', 'version', 'schema', 'workflow', 'policy', 'run'];
35
+ /**
36
+ * Every compilation failure code with its layer, in precedence order, mirrored from
37
+ * `conformance/compile-cases.json` `failureCodes`; the conformance tests assert both sources and the
38
+ * prose table agree.
39
+ */
40
+ export const compilationFailureCodes = [
41
+ { code: 'workflow_too_large', layer: 'source' },
42
+ { code: 'workflow_encoding_invalid', layer: 'source' },
43
+ { code: 'workflow_yaml_syntax', layer: 'yaml' },
44
+ { code: 'workflow_yaml_document_count', layer: 'yaml' },
45
+ { code: 'workflow_yaml_directive', layer: 'yaml' },
46
+ { code: 'workflow_yaml_duplicate_key', layer: 'yaml' },
47
+ { code: 'workflow_yaml_key_type', layer: 'yaml' },
48
+ { code: 'workflow_yaml_anchor', layer: 'yaml' },
49
+ { code: 'workflow_yaml_merge_key', layer: 'yaml' },
50
+ { code: 'workflow_yaml_tag', layer: 'yaml' },
51
+ { code: 'workflow_number_invalid', layer: 'yaml' },
52
+ { code: 'spec_incompatible', layer: 'version' },
53
+ { code: 'workflow_schema_invalid', layer: 'schema' },
54
+ { code: 'trigger_pattern_invalid', layer: 'workflow' },
55
+ { code: 'needs_unknown', layer: 'workflow' },
56
+ { code: 'needs_cycle', layer: 'workflow' },
57
+ { code: 'expansion_limit_exceeded', layer: 'workflow' },
58
+ { code: 'needs_trigger_wider', layer: 'workflow' },
59
+ { code: 'trigger_kind_unused', layer: 'workflow' },
60
+ { code: 'permission_escalation', layer: 'workflow' },
61
+ { code: 'permission_insufficient', layer: 'workflow' },
62
+ { code: 'environment_conflict', layer: 'workflow' },
63
+ { code: 'environment_limit_exceeded', layer: 'workflow' },
64
+ { code: 'command_limit_exceeded', layer: 'workflow' },
65
+ { code: 'transfer_name_duplicate', layer: 'workflow' },
66
+ { code: 'cache_path_overlap', layer: 'workflow' },
67
+ { code: 'resources_invalid', layer: 'workflow' },
68
+ { code: 'network_host_duplicate', layer: 'workflow' },
69
+ { code: 'npm_read_invalid', layer: 'workflow' },
70
+ { code: 'build_input_conflict', layer: 'workflow' },
71
+ { code: 'candidate_reference_invalid', layer: 'workflow' },
72
+ { code: 'candidate_platform_missing', layer: 'workflow' },
73
+ { code: 'publish_reference_invalid', layer: 'workflow' },
74
+ { code: 'policy_limit_exceeded', layer: 'policy' },
75
+ { code: 'policy_timeout_exceeded', layer: 'policy' },
76
+ { code: 'policy_retention_exceeded', layer: 'policy' },
77
+ { code: 'policy_egress_denied', layer: 'policy' },
78
+ { code: 'policy_npm_registry_denied', layer: 'policy' },
79
+ { code: 'policy_denied', layer: 'policy' },
80
+ { code: 'manual_input_invalid', layer: 'run' },
81
+ { code: 'tag_version_required', layer: 'run' },
82
+ { code: 'alias_invalid', layer: 'run' },
83
+ { code: 'alias_duplicate', layer: 'run' },
84
+ { code: 'secret_untrusted', layer: 'run' },
85
+ { code: 'npm_read_untrusted', layer: 'run' },
86
+ { code: 'secret_unknown', layer: 'run' },
87
+ { code: 'protected_secret_denied', layer: 'run' },
88
+ { code: 'secret_too_short', layer: 'run' },
89
+ ];
90
+ export const ciSpecAssetPaths = {
91
+ runnerOpenApi: 'spec/runner.openapi.json',
92
+ runnerProtocol: 'spec/runner-protocol.md',
93
+ ciActionsProtocol: 'spec/ci-actions.md',
94
+ runnerJobSchema: 'schemas/runner-job.schema.json',
95
+ ciActionsSchema: 'schemas/ci_actions.schema.json',
96
+ runnerConformanceCases: 'conformance/runner-cases.json',
97
+ runnerMessageCases: 'conformance/runner-messages.json',
98
+ digestCases: 'conformance/digest-cases.json',
99
+ archiveCases: 'conformance/archive-cases.json',
100
+ versionCases: 'conformance/version-cases.json',
101
+ compileCases: 'conformance/compile-cases.json',
102
+ compileCasesSchema: 'conformance/compile-cases.schema.json',
103
+ ciActionsConformanceDirectory: 'conformance/ci-actions',
104
+ runnerJobConformanceDirectory: 'conformance/runner-jobs',
105
+ };
106
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uc3RhbnRzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvY29uc3RhbnRzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSx5QkFBeUIsQ0FBQztBQUVyRDs7Ozt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xFQUFFLElBQUksRUFBRSxrQkFBa0IsRUFBRSxLQUFLLEVBQUUsS0FBSyxFQUFFO0NBQ2xDLENBQUM7QUFFWCxNQUFNLENBQUMsTUFBTSxnQkFBZ0IsR0FBRztJQUM5QixhQUFhLEVBQUUsMEJBQTBCO0lBQ3pDLGNBQWMsRUFBRSx5QkFBeUI7SUFDekMsaUJBQWlCLEVBQUUsb0JBQW9CO0lBQ3ZDLGVBQWUsRUFBRSxnQ0FBZ0M7SUFDakQsZUFBZSxFQUFFLGdDQUFnQztJQUNqRCxzQkFBc0IsRUFBRSwrQkFBK0I7SUFDdkQsa0JBQWtCLEVBQUUsa0NBQWtDO0lBQ3RELFdBQVcsRUFBRSwrQkFBK0I7SUFDNUMsWUFBWSxFQUFFLGdDQUFnQztJQUM5QyxZQUFZLEVBQUUsZ0NBQWdDO0lBQzlDLFlBQVksRUFBRSxnQ0FBZ0M7SUFDOUMsa0JBQWtCLEVBQUUsdUNBQXVDO0lBQzNELDZCQUE2QixFQUFFLHdCQUF3QjtJQUN2RCw2QkFBNkIsRUFBRSx5QkFBeUI7Q0FDaEQsQ0FBQyJ9
@@ -0,0 +1 @@
1
+ export * from './constants.js';
@@ -0,0 +1,2 @@
1
+ export * from './constants.js';
2
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi90cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxjQUFjLGdCQUFnQixDQUFDIn0=
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,3 @@
1
+ export {};
2
+ // This package intentionally has no runtime dependencies.
3
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGx1Z2lucy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uL3RzL3BsdWdpbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLDBEQUEwRCJ9
@@ -0,0 +1,64 @@
1
+ spec: 2.0.0
2
+ on:
3
+ push:
4
+ branches:
5
+ - main
6
+ pullRequest:
7
+ targetBranches:
8
+ - main
9
+ manual: {}
10
+ permissions:
11
+ source: read
12
+ artifacts: write
13
+ caches: read-write
14
+ images: none
15
+ npm: none
16
+ releaseAssets: none
17
+ concurrency:
18
+ group: build-main
19
+ cancelInProgress: true
20
+ jobs:
21
+ test:
22
+ name: Test
23
+ runner:
24
+ profile: oci
25
+ labels:
26
+ - linux
27
+ - amd64
28
+ execution:
29
+ profile: oci
30
+ image: registry.example/ci/node@sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
31
+ network:
32
+ mode: egress
33
+ allow:
34
+ - host: registry.npmjs.org
35
+ timeoutMs: 900000
36
+ steps:
37
+ - name: Install
38
+ run:
39
+ - pnpm
40
+ - install
41
+ - --frozen-lockfile
42
+ - name: Test
43
+ run:
44
+ - pnpm
45
+ - test
46
+ artifacts:
47
+ - name: test-results
48
+ path: .nogit/testlogs
49
+ when: always
50
+ required: false
51
+ maximumBytes: 104857600
52
+ maximumExtractedBytes: 524288000
53
+ maximumEntries: 10000
54
+ retentionDays: 14
55
+ caches:
56
+ - name: pnpm
57
+ key: pnpm-store
58
+ paths:
59
+ - .pnpm-store
60
+ access: read-write
61
+ maximumBytes: 1073741824
62
+ maximumExtractedBytes: 4294967296
63
+ maximumEntries: 100000
64
+ retentionDays: 30
package/license.md ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) Task Venture Capital GmbH
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/package.json ADDED
@@ -0,0 +1,72 @@
1
+ {
2
+ "name": "@ship.zone/ci-spec",
3
+ "version": "2.0.0",
4
+ "private": false,
5
+ "description": "The ship.zone CI standard: language-neutral CI workflow and runner protocol specifications.",
6
+ "main": "dist_ts/index.js",
7
+ "typings": "dist_ts/index.d.ts",
8
+ "type": "module",
9
+ "author": "Task Venture Capital GmbH",
10
+ "license": "MIT",
11
+ "exports": {
12
+ ".": "./dist_ts/index.js",
13
+ "./runner.openapi.json": "./spec/runner.openapi.json",
14
+ "./runner-protocol.md": "./spec/runner-protocol.md",
15
+ "./ci-actions.md": "./spec/ci-actions.md",
16
+ "./runner-job.schema.json": "./schemas/runner-job.schema.json",
17
+ "./ci_actions.schema.json": "./schemas/ci_actions.schema.json",
18
+ "./runner-cases.json": "./conformance/runner-cases.json",
19
+ "./runner-messages.json": "./conformance/runner-messages.json",
20
+ "./digest-cases.json": "./conformance/digest-cases.json",
21
+ "./archive-cases.json": "./conformance/archive-cases.json",
22
+ "./version-cases.json": "./conformance/version-cases.json",
23
+ "./compile-cases.json": "./conformance/compile-cases.json",
24
+ "./compile-cases.schema.json": "./conformance/compile-cases.schema.json",
25
+ "./conformance/ci-actions/*": "./conformance/ci-actions/*",
26
+ "./conformance/runner-jobs/*": "./conformance/runner-jobs/*"
27
+ },
28
+ "devDependencies": {
29
+ "@git.zone/tsbuild": "^5.0.0",
30
+ "@git.zone/tsrun": "^3.0.1",
31
+ "@git.zone/tstest": "^6.3.2",
32
+ "@redocly/cli": "2.40.0",
33
+ "@types/node": "26.6.2",
34
+ "ajv": "^8.20.0",
35
+ "ajv-formats": "^3.0.1",
36
+ "yaml": "^2.9.0"
37
+ },
38
+ "files": [
39
+ "ts/**/*",
40
+ "dist_ts/**/*",
41
+ "spec/**/*",
42
+ "schemas/**/*",
43
+ "conformance/**/*",
44
+ "examples/**/*",
45
+ ".smartconfig.json",
46
+ "changelog.md",
47
+ "license.md",
48
+ "readme.md"
49
+ ],
50
+ "repository": {
51
+ "type": "git",
52
+ "url": "git+ssh://git@code.foss.global:29419/ship.zone/ci-spec.git"
53
+ },
54
+ "bugs": {
55
+ "url": "https://code.foss.global/ship.zone/ci-spec/issues"
56
+ },
57
+ "homepage": "https://code.foss.global/ship.zone/ci-spec#readme",
58
+ "keywords": [
59
+ "ci",
60
+ "continuous-integration",
61
+ "ship.zone",
62
+ "openapi",
63
+ "runner",
64
+ "workflow"
65
+ ],
66
+ "scripts": {
67
+ "test": "tstest test/ --verbose",
68
+ "test:types": "tsbuild check test/**/*",
69
+ "lint:openapi": "redocly lint spec/runner.openapi.json --extends=spec",
70
+ "build": "tsbuild tsfolders"
71
+ }
72
+ }