From 09bf2b0018d51763a4a0c51cfc9df5f42802368c Mon Sep 17 00:00:00 2001 From: Mikko Siukola Date: Wed, 4 Dec 2024 13:58:15 +0200 Subject: [PATCH 1/3] Run dbt on weekdays, 7-17 --- cdk/lib/ecs-stack.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cdk/lib/ecs-stack.ts b/cdk/lib/ecs-stack.ts index 2d0f6f1..6538455 100644 --- a/cdk/lib/ecs-stack.ts +++ b/cdk/lib/ecs-stack.ts @@ -100,7 +100,8 @@ export class EcsStack extends cdk.Stack { const schedule = appscaling.Schedule.cron({ minute: '30', - hour: '0-23/1', + hour: '7-17/1', + day: '2-6/1', }); const scheduledFargateTask = new ecsPatterns.ScheduledFargateTask( this, From 70374a3825ac9c4266efb40c13647d9e00758f51 Mon Sep 17 00:00:00 2001 From: Mikko Siukola Date: Thu, 5 Dec 2024 09:52:04 +0200 Subject: [PATCH 2/3] Adjust times for UTC --- cdk/lib/ecs-stack.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cdk/lib/ecs-stack.ts b/cdk/lib/ecs-stack.ts index 6538455..7ba6780 100644 --- a/cdk/lib/ecs-stack.ts +++ b/cdk/lib/ecs-stack.ts @@ -100,7 +100,7 @@ export class EcsStack extends cdk.Stack { const schedule = appscaling.Schedule.cron({ minute: '30', - hour: '7-17/1', + hour: '5-15/1', //Tunnit UTC-ajassa day: '2-6/1', }); const scheduledFargateTask = new ecsPatterns.ScheduledFargateTask( From eb56dd2f4286092f0e2110ef6e9ce4d3b4f76855 Mon Sep 17 00:00:00 2001 From: Mikko Siukola Date: Mon, 9 Dec 2024 09:33:28 +0200 Subject: [PATCH 3/3] Set weekdays instead of days of month... --- cdk/lib/ecs-stack.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cdk/lib/ecs-stack.ts b/cdk/lib/ecs-stack.ts index 7ba6780..afdaf64 100644 --- a/cdk/lib/ecs-stack.ts +++ b/cdk/lib/ecs-stack.ts @@ -101,7 +101,7 @@ export class EcsStack extends cdk.Stack { const schedule = appscaling.Schedule.cron({ minute: '30', hour: '5-15/1', //Tunnit UTC-ajassa - day: '2-6/1', + weekDay: '2-6/1', }); const scheduledFargateTask = new ecsPatterns.ScheduledFargateTask( this,