@kitsy/cnos-webpack 1.5.1 → 1.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.
package/dist/index.d.cts CHANGED
@@ -12,7 +12,7 @@ interface SchemaRule {
12
12
  default?: unknown;
13
13
  }
14
14
 
15
- type WorkspaceSource = 'cli' | 'workspace-file' | 'manifest-default' | 'implicit';
15
+ type WorkspaceSource = 'cli' | 'workspace-file' | 'anchor-file' | 'manifest-default' | 'implicit' | 'directory-inferred';
16
16
  type GlobalRootSource = 'cli' | 'workspace-file' | 'manifest' | 'CNOS_HOME';
17
17
  interface NormalizedWorkspaceItem {
18
18
  extends: string[];
@@ -107,6 +107,12 @@ interface NormalizedManifest {
107
107
  schema: Record<LogicalKey, SchemaRule>;
108
108
  }
109
109
 
110
+ interface SecretReference {
111
+ provider: string;
112
+ ref: string;
113
+ vault?: string;
114
+ }
115
+
110
116
  type LogicalKey = string;
111
117
  type NamespaceName = string;
112
118
  interface ConfigOrigin {
@@ -187,6 +193,25 @@ interface CnosRuntime {
187
193
  toNamespace(namespace: NamespaceName): Record<string, unknown>;
188
194
  toEnv(options?: ToEnvOptions): Record<string, string>;
189
195
  toPublicEnv(options?: ToPublicEnvOptions): Record<string, string>;
196
+ toServerProjection(): ServerProjection;
197
+ refreshSecrets(): Promise<void>;
198
+ refreshSecret(key: LogicalKey): Promise<void>;
199
+ }
200
+ interface ServerProjection {
201
+ version: 1;
202
+ workspace: string;
203
+ profile: string;
204
+ resolvedAt: string;
205
+ configHash: string;
206
+ values: Record<string, unknown>;
207
+ secretRefs: Record<string, SecretReference>;
208
+ publicKeys: string[];
209
+ meta: {
210
+ workspace: string;
211
+ profile: string;
212
+ cnos_version: string;
213
+ namespaces?: string[];
214
+ };
190
215
  }
191
216
 
192
217
  type CnosPluginKind = 'loader' | 'resolver' | 'validator' | 'exporter' | 'inspector';
package/dist/index.d.ts CHANGED
@@ -12,7 +12,7 @@ interface SchemaRule {
12
12
  default?: unknown;
13
13
  }
14
14
 
15
- type WorkspaceSource = 'cli' | 'workspace-file' | 'manifest-default' | 'implicit';
15
+ type WorkspaceSource = 'cli' | 'workspace-file' | 'anchor-file' | 'manifest-default' | 'implicit' | 'directory-inferred';
16
16
  type GlobalRootSource = 'cli' | 'workspace-file' | 'manifest' | 'CNOS_HOME';
17
17
  interface NormalizedWorkspaceItem {
18
18
  extends: string[];
@@ -107,6 +107,12 @@ interface NormalizedManifest {
107
107
  schema: Record<LogicalKey, SchemaRule>;
108
108
  }
109
109
 
110
+ interface SecretReference {
111
+ provider: string;
112
+ ref: string;
113
+ vault?: string;
114
+ }
115
+
110
116
  type LogicalKey = string;
111
117
  type NamespaceName = string;
112
118
  interface ConfigOrigin {
@@ -187,6 +193,25 @@ interface CnosRuntime {
187
193
  toNamespace(namespace: NamespaceName): Record<string, unknown>;
188
194
  toEnv(options?: ToEnvOptions): Record<string, string>;
189
195
  toPublicEnv(options?: ToPublicEnvOptions): Record<string, string>;
196
+ toServerProjection(): ServerProjection;
197
+ refreshSecrets(): Promise<void>;
198
+ refreshSecret(key: LogicalKey): Promise<void>;
199
+ }
200
+ interface ServerProjection {
201
+ version: 1;
202
+ workspace: string;
203
+ profile: string;
204
+ resolvedAt: string;
205
+ configHash: string;
206
+ values: Record<string, unknown>;
207
+ secretRefs: Record<string, SecretReference>;
208
+ publicKeys: string[];
209
+ meta: {
210
+ workspace: string;
211
+ profile: string;
212
+ cnos_version: string;
213
+ namespaces?: string[];
214
+ };
190
215
  }
191
216
 
192
217
  type CnosPluginKind = 'loader' | 'resolver' | 'validator' | 'exporter' | 'inspector';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kitsy/cnos-webpack",
3
- "version": "1.5.1",
3
+ "version": "1.6.0",
4
4
  "description": "Webpack integration for CNOS public config injection.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -35,7 +35,7 @@
35
35
  "access": "public"
36
36
  },
37
37
  "dependencies": {
38
- "@kitsy/cnos": "1.5.1"
38
+ "@kitsy/cnos": "1.6.0"
39
39
  },
40
40
  "peerDependencies": {
41
41
  "webpack": ">=5"