mirror of
https://github.com/protomaps/PMTiles.git
synced 2026-02-04 10:51:07 +00:00
AWS Lambda: add dev/staging CORS configuration variable.
This commit is contained in:
@@ -155,6 +155,10 @@ export const handler = async (
|
||||
var headers: Headers = {};
|
||||
// TODO: metadata and TileJSON
|
||||
|
||||
if (process.env.CORS) {
|
||||
headers['Access-Control-Allow-Origin'] = process.env.CORS;
|
||||
}
|
||||
|
||||
const source = new S3Source(name);
|
||||
const p = new PMTiles(source, CACHE, nativeDecompress);
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user