diff --git a/packages/_infra/src/cogify/index.ts b/packages/_infra/src/cogify/index.ts index d9f6f68ca..a8fa6da71 100644 --- a/packages/_infra/src/cogify/index.ts +++ b/packages/_infra/src/cogify/index.ts @@ -8,6 +8,7 @@ import { createHash } from 'crypto'; import { TileMetadataTableArn } from '../serve/db.js'; import { ScratchData } from './mount.folder.js'; import { Construct } from 'constructs'; +import { getConfig } from '../config.js'; /** * Cogification infrastructure @@ -126,6 +127,8 @@ export class CogBuilderStack extends cdk.Stack { }, }); + const config = getConfig(); + new batch.CfnJobDefinition(this, 'CogBatchJobDef', { jobDefinitionName: 'CogBatchJob', type: 'container', @@ -145,7 +148,7 @@ export class CogBuilderStack extends cdk.Stack { * Eg a instance with 8192MB allocates 7953MB usable */ memory: 3900, - environment: [{ name: Env.TempFolder, value: ScratchData.Folder }], + environment: [{ name: Env.TempFolder, value: ScratchData.Folder, [Env.PublicUrlBase]: config.PublicUrlBase }], mountPoints: [{ containerPath: ScratchData.Folder, sourceVolume: 'scratch' }], volumes: [{ name: 'scratch', host: { sourcePath: ScratchData.Folder } }], }, diff --git a/packages/config/src/dynamo/dynamo.config.ts b/packages/config/src/dynamo/dynamo.config.ts index bbe8b6029..01afa87a3 100644 --- a/packages/config/src/dynamo/dynamo.config.ts +++ b/packages/config/src/dynamo/dynamo.config.ts @@ -24,7 +24,7 @@ export class ConfigProviderDynamo extends BasemapsConfigProvider { constructor(tableName: string) { super(); - this.dynamo = new DynamoDB({}); + this.dynamo = new DynamoDB({ region: 'ap-southeast-2' }); this.tableName = tableName; }