@adobe/helix-config 2.16.1 → 2.18.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/CHANGELOG.md +14 -0
- package/package.json +1 -1
- package/src/config-view.js +9 -11
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
# [2.18.0](https://github.com/adobe/helix-config/compare/v2.17.0...v2.18.0) (2024-05-09)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* delivery token hashes for pipeline scope ([#79](https://github.com/adobe/helix-config/issues/79)) ([371c771](https://github.com/adobe/helix-config/commit/371c7718fb9592e526fcef2f76efbd0ed6a209f6))
|
|
7
|
+
|
|
8
|
+
# [2.17.0](https://github.com/adobe/helix-config/compare/v2.16.1...v2.17.0) (2024-05-08)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* remove old access config ([#77](https://github.com/adobe/helix-config/issues/77)) ([20d9a25](https://github.com/adobe/helix-config/commit/20d9a252eb5b399f2f6dc324830748cbacbae5c3))
|
|
14
|
+
|
|
1
15
|
## [2.16.1](https://github.com/adobe/helix-config/compare/v2.16.0...v2.16.1) (2024-05-08)
|
|
2
16
|
|
|
3
17
|
|
package/package.json
CHANGED
package/src/config-view.js
CHANGED
|
@@ -117,10 +117,6 @@ export function getAccessConfig(ctx, config, partition, rso) {
|
|
|
117
117
|
}
|
|
118
118
|
}
|
|
119
119
|
|
|
120
|
-
// todo: remove after auth rewrite
|
|
121
|
-
if (allow) {
|
|
122
|
-
cfg.allow = allow;
|
|
123
|
-
}
|
|
124
120
|
return cfg;
|
|
125
121
|
}
|
|
126
122
|
|
|
@@ -310,22 +306,23 @@ export async function getConfigResponse(ctx, opts) {
|
|
|
310
306
|
'x-hlx-contentbus-id': config.content.contentBusId,
|
|
311
307
|
'x-hlx-owner': config.code.owner,
|
|
312
308
|
'x-hlx-repo': config.code.repo,
|
|
313
|
-
'x-hlx-auth-allow-preview': canonicalArrayString(config.access, 'preview', 'allow'),
|
|
314
|
-
'x-hlx-auth-apikey-preview': canonicalArrayString(config.access, 'preview', 'apiKeyId'),
|
|
315
309
|
'x-hlx-auth-clientdn-preview': canonicalArrayString(config.access, 'preview', 'clientCertDN'),
|
|
316
310
|
'x-hlx-auth-hash-preview': canonicalArrayString(config.access, 'preview', 'tokenHash'),
|
|
317
|
-
'x-hlx-auth-allow-live': canonicalArrayString(config.access, 'live', 'allow'),
|
|
318
|
-
'x-hlx-auth-apikey-live': canonicalArrayString(config.access, 'live', 'apiKeyId'),
|
|
319
311
|
'x-hlx-auth-clientdn-live': canonicalArrayString(config.access, 'live', 'clientCertDN'),
|
|
320
312
|
'x-hlx-auth-hash-live': canonicalArrayString(config.access, 'live', 'tokenHash'),
|
|
321
313
|
},
|
|
322
314
|
});
|
|
323
315
|
}
|
|
324
316
|
|
|
325
|
-
// delete token hashes
|
|
317
|
+
// delete token hashes but keep for pipeline because the cloudflare worker still needs them
|
|
326
318
|
delete config.tokens;
|
|
327
|
-
|
|
328
|
-
|
|
319
|
+
if (opts.scope !== SCOPE_PIPELINE) {
|
|
320
|
+
delete config.access?.preview?.tokenHash;
|
|
321
|
+
delete config.access?.live?.tokenHash;
|
|
322
|
+
} else {
|
|
323
|
+
delete config.access?.preview?.apiKeyId;
|
|
324
|
+
delete config.access?.live?.apiKeyId;
|
|
325
|
+
}
|
|
329
326
|
|
|
330
327
|
if (opts.scope === SCOPE_ADMIN) {
|
|
331
328
|
const adminConfig = {
|
|
@@ -372,6 +369,7 @@ export async function getConfigResponse(ctx, opts) {
|
|
|
372
369
|
folders: config.folders,
|
|
373
370
|
public: config.public,
|
|
374
371
|
robots: config.robots,
|
|
372
|
+
access: config.access,
|
|
375
373
|
};
|
|
376
374
|
return new PipelineResponse(JSON.stringify(pipelineConfig, null, 2), {
|
|
377
375
|
headers: {
|