Skip to content

Releases: philips-labs/terraform-aws-github-runner

v5.20.0

19 Nov 21:31
232818d
Compare
Choose a tag to compare

5.20.0 (2024-11-19)

Features

Bug Fixes

  • lambda: bump cross-spawn from 7.0.3 to 7.0.6 in /lambdas (#4273) (dcec236)
  • lambda: bump the aws group in /lambdas with 7 updates (#4266) (849549e)

v5.19.0

12 Nov 12:27
26ad5c1
Compare
Choose a tag to compare

5.19.0 (2024-11-12)

Features

  • remove deprecated bata feature workflow job queue (#4249) (4066c4e)

Bug Fixes

  • dispatch only queued events to runners (#4257) (a0a8322)
  • lambda: bump @octokit/auth-app from 6.1.2 to 6.1.3 in /lambdas in the octokit group (#4252) (25f3538)
  • lambda: bump the aws group in /lambdas with 7 updates (#4251) (6a98712)

Migration notes

This release removes experimental / beta feature enable_workflow_job_events_queue. When depending on the events on this queue you can migrate to using the EventBridgge.

Enable eventbridge

module "runners" {

  ...
  eventbridge {
    enable = true
  }
  ...

Add rule to forward events to a queue

resource "aws_cloudwatch_event_rule" "workflow_job_in_progress" {
  name           = "workflow-job-in-progress"
  event_bus_name = modules.runners.webhook.eventbridge.name # The name of the event bus output by the module

  event_pattern = <<EOF
{
  "detail-type": ["workflow_job"],
  "detail": {
    "action": ["in_progress"]
  }
}
EOF
}

resource "aws_sqs_queue" "workflow_job_in_progress" {
  name = "workflow_job_in_progress
}


resource "aws_sqs_queue_policy" "workflow_job_in_progress" {
  queue_url = aws_sqs_queue.workflow_job_in_progress.id
  policy    = data.aws_iam_policy_document.sqs_policy.json
}

data "aws_iam_policy_document" "sqs_policy" {
  statement {
    sid     = "AllowFromEventBridge"
    actions = ["sqs:SendMessage"]

    principals {
      type        = "Service"
      identifiers = ["events.amazonaws.com"]
    }

    resources = [aws_sqs_queue.workflow_job_in_progress.arn]

    condition {
      test     = "ArnEquals"
      variable = "aws:SourceArn"
      values   = [aws_cloudwatch_event_rule.workflow_job_in_progress.arn]
    }
  }
}

v5.18.4

07 Nov 17:29
52ce9c1
Compare
Choose a tag to compare

5.18.4 (2024-11-07)

Bug Fixes

  • trigger cold start dispatcher after update SSM parameters (#4243) (580d24b)

v5.18.3

06 Nov 14:09
98e6a8c
Compare
Choose a tag to compare

5.18.3 (2024-11-05)

Bug Fixes

  • lambda: bump the aws group in /lambdas with 6 updates (#4235) (ef89b98)
  • remove unused example spot_instance_termination_watcher (#4226) (ad865a7) @piscue

v5.18.2

31 Oct 12:29
0d87aec
Compare
Choose a tag to compare

5.18.2 (2024-10-31)

Bug Fixes

  • webhook: add missing permission to workflow job queue (EventBridge) (#4224) (d7e516c)

v5.18.1

30 Oct 07:04
0c52580
Compare
Choose a tag to compare

5.18.1 (2024-10-29)

Bug Fixes

  • lambda: bump the aws group in /lambdas with 7 updates (#4211) (d18dcaa)
  • lambda: bump the aws-powertools group in /lambdas with 4 updates (#4212) (9c9219b)
  • webhook: grant KMS permission to decrypt when using EventBridge (#4220) (380bcaf)
  • webhook: result message webhook (#4221) (8099c17)

v5.18.0

28 Oct 17:02
7983143
Compare
Choose a tag to compare

5.18.0 (2024-10-28)

Features

Migration directions

This release is adding optional the EventBridge as option to the webhook. No matter if the feature is enabled or not resources are moved internally. Which will destroy all webhook related resources update to this verions.

To retain data for the Loggroup of the webhook or mmetrics for the webhook the resources not to be moved in the Terraform state. You can add HCL moved blocked to your deployment to instruct Terraform to move the resources instead of re-create.

Examples Terraform `moved` blockes

With module defaults or eventbridge is not eanavbled

# log group
moved {
   from = module.<runner-module-name>.module.webhook.aws_cloudwatch_log_group.webhook
   to = module.<runner-module-name>.module.webhook.module.direct[0].aws_cloudwatch_log_group.webhook
}

# lambda
moved {
   from = module.<runner-module-name>.module.webhook.aws_lambda_function.webhook
   to = module.<runner-module-name>.module.webhook.module.direct[0].aws_lambda_function.webhook
}

With EventBridge enabled

# log group
moved {
   from = module.<runner-module-name>.module.webhook.aws_cloudwatch_log_group.webhook
   to = module.<runner-module-name>.module.webhook.module.direct[0].aws_cloudwatch_log_group.webhook
}

# lambda
moved {
   from = module.<runner-module-name>.module.webhook.aws_lambda_function.webhook
   to = module.<runner-module-name>.module.webhook.module.direct[0].aws_lambda_function.webhook
}

Ater upgrade swithcing between webhook to EventBridge

When enable mode eventbridge

# log group
moved {
  from = module.runners.module.webhook.module.direct[0].aws_cloudwatch_log_group.webhook
  to = module.runners.module.webhook.module.eventbridge[0].aws_cloudwatch_log_group.webhook
}

# lambda
moved {
  from = module.runners.module.webhook.module.direct[0].aws_lambda_function.webhook
  to = module.runners.module.webhook.module.eventbridge[0].aws_lambda_function.webhook
}

Or vice versa for moving from eventbride to webhook

v5.17.3

23 Oct 14:35
3495d80
Compare
Choose a tag to compare

5.17.3 (2024-10-23)

Bug Fixes

  • lambda: bump the aws group across 1 directory with 5 updates (#4203) (e12ee80)
  • lambda: bump typescript from 5.5.4 to 5.6.3 in /lambdas (#4200) (cb0c1ff)

v5.17.2

21 Oct 14:27
3b9bba2
Compare
Choose a tag to compare

5.17.2 (2024-10-21)

Bug Fixes

  • spot termination watcher output multi runner (#4194) (367b1b3)

v5.17.1

17 Oct 07:42
4708125
Compare
Choose a tag to compare

5.17.1 (2024-10-17)

Bug Fixes

  • lambda: bump @octokit/types from 13.5.0 to 13.6.1 in /lambdas in the octokit group (#4183) (f24469f)
  • lambda: bump the aws group across 1 directory with 5 updates (#4191) (bf8a924)
  • lambda: bump the aws-powertools group in /lambdas with 4 updates (#4184) (e18ac60)