@cloudsnorkel/cdk-github-runners 0.14.15 → 0.14.16

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.
Files changed (59) hide show
  1. package/.jsii +800 -274
  2. package/API.md +480 -6
  3. package/README.md +149 -0
  4. package/SETUP_GITHUB.md +99 -3
  5. package/assets/delete-failed-runner.lambda/index.js +40 -31
  6. package/assets/idle-runner-repear.lambda/index.js +40 -31
  7. package/assets/setup.lambda/index.html +12 -7
  8. package/assets/setup.lambda/index.js +26 -26
  9. package/assets/status.lambda/index.js +40 -31
  10. package/assets/token-retriever.lambda/index.js +40 -31
  11. package/assets/webhook-handler.lambda/index.js +110 -43
  12. package/assets/webhook-redelivery.lambda/index.js +40 -31
  13. package/lib/access.js +1 -1
  14. package/lib/image-builders/api.js +1 -1
  15. package/lib/image-builders/aws-image-builder/ami.d.ts +1 -2
  16. package/lib/image-builders/aws-image-builder/ami.js +6 -13
  17. package/lib/image-builders/aws-image-builder/builder.d.ts +4 -2
  18. package/lib/image-builders/aws-image-builder/builder.js +36 -34
  19. package/lib/image-builders/aws-image-builder/container.d.ts +2 -2
  20. package/lib/image-builders/aws-image-builder/container.js +7 -12
  21. package/lib/image-builders/aws-image-builder/deprecated/ami.js +1 -1
  22. package/lib/image-builders/aws-image-builder/deprecated/container.js +1 -1
  23. package/lib/image-builders/aws-image-builder/deprecated/linux-components.js +1 -1
  24. package/lib/image-builders/aws-image-builder/deprecated/windows-components.js +1 -1
  25. package/lib/image-builders/aws-image-builder/index.d.ts +0 -1
  26. package/lib/image-builders/aws-image-builder/index.js +1 -2
  27. package/lib/image-builders/aws-image-builder/workflow.d.ts +4 -4
  28. package/lib/image-builders/aws-image-builder/workflow.js +7 -10
  29. package/lib/image-builders/codebuild-deprecated.js +1 -1
  30. package/lib/image-builders/components.js +1 -1
  31. package/lib/image-builders/static.js +1 -1
  32. package/lib/index.d.ts +1 -0
  33. package/lib/index.js +2 -1
  34. package/lib/providers/codebuild.js +16 -10
  35. package/lib/providers/common.d.ts +53 -0
  36. package/lib/providers/common.js +11 -4
  37. package/lib/providers/composite.d.ts +61 -0
  38. package/lib/providers/composite.js +229 -0
  39. package/lib/providers/ec2.js +9 -8
  40. package/lib/providers/ecs.js +11 -6
  41. package/lib/providers/fargate.js +14 -9
  42. package/lib/providers/index.d.ts +1 -0
  43. package/lib/providers/index.js +2 -1
  44. package/lib/providers/lambda.js +6 -5
  45. package/lib/runner.d.ts +29 -5
  46. package/lib/runner.js +57 -24
  47. package/lib/secrets.js +1 -1
  48. package/lib/webhook-handler.lambda.d.ts +11 -0
  49. package/lib/webhook-handler.lambda.js +81 -14
  50. package/lib/webhook.d.ts +52 -7
  51. package/lib/webhook.js +4 -2
  52. package/package.json +15 -19
  53. package/assets/image-builders/aws-image-builder/versioner.lambda/index.js +0 -2115
  54. package/lib/image-builders/aws-image-builder/common.d.ts +0 -10
  55. package/lib/image-builders/aws-image-builder/common.js +0 -48
  56. package/lib/image-builders/aws-image-builder/versioner-function.d.ts +0 -13
  57. package/lib/image-builders/aws-image-builder/versioner-function.js +0 -23
  58. package/lib/image-builders/aws-image-builder/versioner.lambda.d.ts +0 -7
  59. package/lib/image-builders/aws-image-builder/versioner.lambda.js +0 -115
package/.jsii CHANGED
@@ -3834,7 +3834,7 @@
3834
3834
  "stability": "experimental"
3835
3835
  },
3836
3836
  "homepage": "https://github.com/CloudSnorkel/cdk-github-runners.git",
3837
- "jsiiVersion": "5.8.22 (build 160a3ef)",
3837
+ "jsiiVersion": "5.8.25 (build 948fef6)",
3838
3838
  "keywords": [
3839
3839
  "aws",
3840
3840
  "aws-cdk",
@@ -3858,7 +3858,7 @@
3858
3858
  },
3859
3859
  "name": "@cloudsnorkel/cdk-github-runners",
3860
3860
  "readme": {
3861
- "markdown": "# GitHub Self-Hosted Runners CDK Constructs\n\n[![NPM](https://img.shields.io/npm/v/@cloudsnorkel/cdk-github-runners?label=npm&logo=npm)][7]\n[![PyPI](https://img.shields.io/pypi/v/cloudsnorkel.cdk-github-runners?label=pypi&logo=pypi)][6]\n[![Maven Central](https://img.shields.io/maven-central/v/com.cloudsnorkel/cdk.github.runners.svg?label=Maven%20Central&logo=apachemaven)][8]\n[![Go](https://img.shields.io/github/v/tag/CloudSnorkel/cdk-github-runners?color=red&label=go&logo=go)][11]\n[![Nuget](https://img.shields.io/nuget/v/CloudSnorkel.Cdk.Github.Runners?color=red&&logo=nuget)][12]\n[![Release](https://github.com/CloudSnorkel/cdk-github-runners/actions/workflows/release.yml/badge.svg)](https://github.com/CloudSnorkel/cdk-github-runners/actions/workflows/release.yml)\n[![License](https://img.shields.io/badge/license-Apache--2.0-blue)](https://github.com/CloudSnorkel/cdk-github-runners/blob/main/LICENSE)\n\nUse this CDK construct to create ephemeral [self-hosted GitHub runners][1] on-demand inside your AWS account.\n\n* 🧩 Easy to configure GitHub integration with a web-based interface\n* 🧠 Customizable runners with decent defaults\n* 🏃🏻 Multiple runner configurations controlled by labels\n* 🔐 Everything fully hosted in your account\n* 🔃 Automatically updated build environment with latest runner version\n\nSelf-hosted runners in AWS are useful when:\n\n* You need easy access to internal resources in your actions\n* You want to pre-install some software for your actions\n* You want to provide some basic AWS API access (but [aws-actions/configure-aws-credentials][2] has more security controls)\n* You are using GitHub Enterprise Server\n\nEphemeral (or on-demand) runners are the [recommended way by GitHub][14] for auto-scaling, and they make sure all jobs run with a clean image. Runners are started on-demand. You don't pay unless a job is running.\n\n## API\n\nThe best way to browse API documentation is on [Constructs Hub][13]. It is available in all supported programming languages.\n\n## Providers\n\nA runner provider creates compute resources on-demand and uses [actions/runner][5] to start a runner.\n\n| | EC2 | CodeBuild | Fargate | ECS | Lambda |\n|------------------|-------------------|----------------------------|----------------|----------------|---------------|\n| **Time limit** | Unlimited | 8 hours | Unlimited | Unlimited | 15 minutes |\n| **vCPUs** | Unlimited | 2, 4, 8, or 72 | 0.25 to 4 | Unlimited | 1 to 6 |\n| **RAM** | Unlimited | 3gb, 7gb, 15gb, or 145gb | 512mb to 30gb | Unlimited | 128mb to 10gb |\n| **Storage** | Unlimited | 50gb to 824gb | 20gb to 200gb | Unlimited | Up to 10gb |\n| **Architecture** | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 |\n| **sudo** | ✔ | ✔ | ✔ | ✔ | ❌ |\n| **Docker** | ✔ | ✔ (Linux only) | ❌ | ✔ | ❌ |\n| **Spot pricing** | ✔ | ❌ | ✔ | ✔ | ❌ |\n| **OS** | Linux, Windows | Linux, Windows | Linux, Windows | Linux, Windows | Linux |\n\nThe best provider to use mostly depends on your current infrastructure. When in doubt, CodeBuild is always a good choice. Execution history and logs are easy to view, and it has no restrictive limits unless you need to run for more than 8 hours.\n\n* EC2 is useful when you want runners to have complete access to the host\n* ECS is useful when you want to control the infrastructure, like leaving the runner host running for faster startups\n* Lambda is useful for short jobs that can work within time, size and readonly system constraints\n\nYou can also create your own provider by implementing `IRunnerProvider`.\n\n## Installation\n\n1. Install and use the appropriate package\n <details><summary>Python</summary>\n\n ### Install\n Available on [PyPI][6].\n ```bash\n pip install cloudsnorkel.cdk-github-runners\n ```\n ### Use\n ```python\n from aws_cdk import App, Stack\n from cloudsnorkel.cdk_github_runners import GitHubRunners\n\n app = App()\n stack = Stack(app, \"github-runners\")\n GitHubRunners(stack, \"runners\")\n\n app.synth()\n ```\n </details>\n <details><summary>TypeScript or JavaScript</summary>\n\n ### Install\n Available on [npm][7].\n ```bash\n npm i @cloudsnorkel/cdk-github-runners\n ```\n ### Use\n ```typescript\n import { App, Stack } from 'aws-cdk-lib';\n import { GitHubRunners } from '@cloudsnorkel/cdk-github-runners';\n\n const app = new App();\n const stack = new Stack(app, 'github-runners');\n new GitHubRunners(stack, 'runners');\n\n app.synth();\n ```\n </details>\n <details><summary>Java</summary>\n\n ### Install\n Available on [Maven][8].\n ```xml\n <dependency>\n <groupId>com.cloudsnorkel</groupId>\n <artifactId>cdk.github.runners</artifactId>\n </dependency>\n ```\n ### Use\n ```java\n import software.amazon.awscdk.App;\n import software.amazon.awscdk.Stack;\n import com.cloudsnorkel.cdk.github.runners.GitHubRunners;\n\n public class Example {\n public static void main(String[] args){\n App app = new App();\n Stack stack = new Stack(app, \"github-runners\");\n GitHubRunners.Builder.create(stack, \"runners\").build();\n\n app.synth();\n }\n }\n ```\n </details>\n <details><summary>Go</summary>\n\n ### Install\n Available on [GitHub][11].\n ```bash\n go get github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\n ```\n ### Use\n ```go\n package main\n\n import (\n \"github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\"\n \"github.com/aws/aws-cdk-go/awscdk/v2\"\n \"github.com/aws/jsii-runtime-go\"\n )\n\n func main() {\n app := awscdk.NewApp(nil)\n stack := awscdk.NewStack(app, jsii.String(\"github-runners\"), &awscdk.StackProps{})\n cloudsnorkelcdkgithubrunners.NewGitHubRunners(stack, jsii.String(\"runners\"), &cloudsnorkelcdkgithubrunners.GitHubRunnersProps{})\n\n app.Synth(nil)\n }\n ```\n </details>\n <details><summary>.NET</summary>\n\n ### Install\n Available on [Nuget][12].\n ```bash\n dotnet add package CloudSnorkel.Cdk.Github.Runners\n ```\n ### Use\n ```csharp\n using Amazon.CDK;\n using CloudSnorkel;\n\n namespace Example\n {\n sealed class Program\n {\n public static void Main(string[] args)\n {\n var app = new App();\n var stack = new Stack(app, \"github-runners\");\n new GitHubRunners(stack, \"runners\");\n app.Synth();\n }\n }\n }\n ```\n </details>\n2. Use `GitHubRunners` construct in your code (starting with default arguments is fine)\n3. Deploy your stack\n4. Look for the status command output similar to `aws --region us-east-1 lambda invoke --function-name status-XYZ123 status.json`\n ```\n ✅ github-runners-test\n\n ✨ Deployment time: 260.01s\n\n Outputs:\n github-runners-test.runnersstatuscommand4A30F0F5 = aws --region us-east-1 lambda invoke --function-name github-runners-test-runnersstatus1A5771C0-mvttg8oPQnQS status.json\n ```\n5. Execute the status command (you may need to specify `--profile` too) and open the resulting `status.json` file\n6. Open the URL in `github.setup.url` from `status.json` or [manually setup GitHub](SETUP_GITHUB.md) integration as an app or with personal access token\n7. Run status command again to confirm `github.auth.status` and `github.webhook.status` are OK\n8. Trigger a GitHub action that has a `self-hosted` label with `runs-on: [self-hosted, codebuild]` (or non-default labels you set in step 2)\n9. If the action is not successful, see [troubleshooting](#Troubleshooting)\n\n[![Demo](demo-thumbnail.jpg)](https://youtu.be/wlyv_3V8lIw)\n\n## Customizing\n\nThe default providers configured by `GitHubRunners` are useful for testing but probably not too much for actual production work. They run in the default VPC or no VPC and have no added IAM permissions. You would usually want to configure the providers yourself.\n\nFor example:\n\n```typescript\nlet vpc: ec2.Vpc;\nlet runnerSg: ec2.SecurityGroup;\nlet dbSg: ec2.SecurityGroup;\nlet bucket: s3.Bucket;\n\n// create a custom CodeBuild provider\nconst myProvider = new CodeBuildRunnerProvider(this, 'codebuild runner', {\n labels: ['my-codebuild'],\n vpc: vpc,\n securityGroups: [runnerSg],\n});\n// grant some permissions to the provider\nbucket.grantReadWrite(myProvider);\ndbSg.connections.allowFrom(runnerSg, ec2.Port.tcp(3306), 'allow runners to connect to MySQL database');\n\n// create the runner infrastructure\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nAnother way to customize runners is by modifying the image used to spin them up. The image contains the [runner][5], any required dependencies, and integration code with the provider. You may choose to customize this image by adding more packages, for example.\n\n```typescript\nconst myBuilder = FargateRunnerProvider.imageBuilder(this, 'image builder');\nmyBuilder.addComponent(\n RunnerImageComponent.custom({ commands: ['apt install -y nginx xz-utils'] }),\n);\n\nconst myProvider = new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['customized-fargate'],\n imageBuilder: myBuilder,\n});\n\n// create the runner infrastructure\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nYour workflow will then look like:\n\n```yaml\nname: self-hosted example\non: push\njobs:\n self-hosted:\n runs-on: [self-hosted, customized-fargate]\n steps:\n - run: echo hello world\n```\n\nWindows images can also be customized the same way.\n\n```typescript\nconst myWindowsBuilder = FargateRunnerProvider.imageBuilder(this, 'Windows image builder', {\n architecture: Architecture.X86_64,\n os: Os.WINDOWS,\n});\nmyWindowsBuilder.addComponent(\n RunnerImageComponent.custom({\n name: 'Ninja',\n commands: [\n 'Invoke-WebRequest -UseBasicParsing -Uri \"https://github.com/ninja-build/ninja/releases/download/v1.11.1/ninja-win.zip\" -OutFile ninja.zip',\n 'Expand-Archive ninja.zip -DestinationPath C:\\\\actions',\n 'del ninja.zip',\n ],\n }),\n);\n\nconst myProvider = new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['customized-windows-fargate'],\n imageBuilder: myWindowsBuilder,\n});\n\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nThe runner OS and architecture is determined by the image it is set to use. For example, to create a Fargate runner provider for ARM64 set the `architecture` property for the image builder to `Architecture.ARM64` in the image builder properties.\n\n```typescript\nnew GitHubRunners(this, 'runners', {\n providers: [\n new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['arm64', 'fargate'],\n imageBuilder: FargateRunnerProvider.imageBuilder(this, 'image builder', {\n architecture: Architecture.ARM64,\n os: Os.LINUX_UBUNTU,\n }),\n }),\n ],\n});\n```\n\n## Examples\n\nBeyond the code snippets above, the fullest example available is the [integration test](test/default.integ.ts).\n\nIf you have more to share, please open a PR adding them to the `examples` folder.\n\n## Architecture\n\n![Architecture diagram](architecture.svg)\n\n## Troubleshooting\n\nRunners are started in response to a webhook coming in from GitHub. If there are any issues starting the runner like missing capacity or transient API issues, the provider will keep retrying for 24 hours. Configuration issue related errors like pointing to a missing AMI will not be retried. GitHub itself will cancel the job if it can't find a runner for 24 hours. If your jobs don't start, follow the steps below to examine all parts of this workflow.\n\n1. Always start with the status function, make sure no errors are reported, and confirm all status codes are OK\n2. Make sure `runs-on` in the workflow matches the expected labels set in the runner provider\n3. Diagnose relevant executions of the orchestrator step function by visiting the URL in `troubleshooting.stepFunctionUrl` from `status.json`\n 1. If the execution failed, check your runner provider configuration for errors\n 2. If the execution is still running for a long time, check the execution events to see why runner starting is being retried\n 3. If there are no relevant executions, move to the next step\n4. Confirm the webhook Lambda was called by visiting the URL in `troubleshooting.webhookHandlerUrl` from `status.json`\n 1. If it's not called or logs errors, confirm the webhook settings on the GitHub side\n 2. If you see too many errors, make sure you're only sending `workflow_job` events\n5. When using GitHub app, make sure there are active installations in `github.auth.app.installations`\n\nAll logs are saved in CloudWatch.\n* Log group names can be found in `status.json` for each provider, image builder, and other parts of the system\n* Some useful Logs Insights queries can be enabled with `GitHubRunners.createLogsInsightsQueries()`\n\nTo get `status.json`, check out the CloudFormation stack output for a command that generates it. The command looks like:\n\n```\naws --region us-east-1 lambda invoke --function-name status-XYZ123 status.json\n```\n\n## Monitoring\n\nThere are two important ways to monitor your runners:\n\n1. Make sure runners don't fail to start. When that happens, jobs may sit and wait. Use `GitHubRunners.metricFailed()` to get a metric for the number of failed runner starts. You should use this metric to trigger an alarm.\n2. Make sure runner images don't fail to build. Failed runner image builds mean you will get stuck with out-of-date software on your runners. It may lead to security vulnerabilities, or it may lead to slower runner start-ups as the runner software itself needs to be updated. Use `GitHubRunners.failedImageBuildsTopic()` to get SNS topic that gets notified of failed runner image builds. You should subscribe to this topic.\n\nOther useful metrics to track:\n\n1. Use `GitHubRunners.metricJobCompleted()` to get a metric for the number of completed jobs broken down by labels and job success.\n2. Use `GitHubRunners.metricTime()` to get a metric for the total time a runner is running. This includes the overhead of starting the runner.\n\n## Contributing\n\nIf you use and love this project, please consider contributing.\n\n1. 🪳 If you see something, say something. [Issues][16] help improve the quality of the project.\n * Include relevant logs and package versions for bugs.\n * When possible, describe the use-case behind feature requests.\n1. 🛠️ [Pull requests][17] are welcome.\n * Run `npm run build` before submitting to make sure all tests pass.\n * Allow edits from maintainers so small adjustments can be made easily.\n1. 💵 Consider [sponsoring][15] the project to show your support and optionally get your name listed below.\n\n## Other Options\n\n1. [philips-labs/terraform-aws-github-runner][3] if you're using Terraform\n2. [actions/actions-runner-controller][4] if you're using Kubernetes\n\n\n[1]: https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners\n[2]: https://github.com/marketplace/actions/configure-aws-credentials-action-for-github-actions\n[3]: https://github.com/philips-labs/terraform-aws-github-runner\n[4]: https://github.com/actions/actions-runner-controller\n[5]: https://github.com/actions/runner\n[6]: https://pypi.org/project/cloudsnorkel.cdk-github-runners\n[7]: https://www.npmjs.com/package/@cloudsnorkel/cdk-github-runners\n[8]: https://central.sonatype.com/artifact/com.cloudsnorkel/cdk.github.runners/\n[9]: https://docs.github.com/en/developers/apps/getting-started-with-apps/about-apps\n[10]: https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token\n[11]: https://pkg.go.dev/github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\n[12]: https://www.nuget.org/packages/CloudSnorkel.Cdk.Github.Runners/\n[13]: https://constructs.dev/packages/@cloudsnorkel/cdk-github-runners/\n[14]: https://docs.github.com/en/actions/hosting-your-own-runners/autoscaling-with-self-hosted-runners#using-ephemeral-runners-for-autoscaling\n[15]: https://github.com/sponsors/CloudSnorkel\n[16]: https://github.com/CloudSnorkel/cdk-github-runners/issues\n[17]: https://github.com/CloudSnorkel/cdk-github-runners/pulls\n"
3861
+ "markdown": "# GitHub Self-Hosted Runners CDK Constructs\n\n[![NPM](https://img.shields.io/npm/v/@cloudsnorkel/cdk-github-runners?label=npm&logo=npm)][7]\n[![PyPI](https://img.shields.io/pypi/v/cloudsnorkel.cdk-github-runners?label=pypi&logo=pypi)][6]\n[![Maven Central](https://img.shields.io/maven-central/v/com.cloudsnorkel/cdk.github.runners.svg?label=Maven%20Central&logo=apachemaven)][8]\n[![Go](https://img.shields.io/github/v/tag/CloudSnorkel/cdk-github-runners?color=red&label=go&logo=go)][11]\n[![Nuget](https://img.shields.io/nuget/v/CloudSnorkel.Cdk.Github.Runners?color=red&&logo=nuget)][12]\n[![Release](https://github.com/CloudSnorkel/cdk-github-runners/actions/workflows/release.yml/badge.svg)](https://github.com/CloudSnorkel/cdk-github-runners/actions/workflows/release.yml)\n[![License](https://img.shields.io/badge/license-Apache--2.0-blue)](https://github.com/CloudSnorkel/cdk-github-runners/blob/main/LICENSE)\n\nUse this CDK construct to create ephemeral [self-hosted GitHub runners][1] on-demand inside your AWS account.\n\n* 🧩 Easy to configure GitHub integration with a web-based interface\n* 🧠 Customizable runners with decent defaults\n* 🏃🏻 Multiple runner configurations controlled by labels\n* 🔐 Everything fully hosted in your account\n* 🔃 Automatically updated build environment with latest runner version\n\nSelf-hosted runners in AWS are useful when:\n\n* You need easy access to internal resources in your actions\n* You want to pre-install some software for your actions\n* You want to provide some basic AWS API access (but [aws-actions/configure-aws-credentials][2] has more security controls)\n* You are using GitHub Enterprise Server\n\nEphemeral (or on-demand) runners are the [recommended way by GitHub][14] for auto-scaling, and they make sure all jobs run with a clean image. Runners are started on-demand. You don't pay unless a job is running.\n\n## API\n\nThe best way to browse API documentation is on [Constructs Hub][13]. It is available in all supported programming languages.\n\n## Providers\n\nA runner provider creates compute resources on-demand and uses [actions/runner][5] to start a runner.\n\n| | EC2 | CodeBuild | Fargate | ECS | Lambda |\n|------------------|-------------------|----------------------------|----------------|----------------|---------------|\n| **Time limit** | Unlimited | 8 hours | Unlimited | Unlimited | 15 minutes |\n| **vCPUs** | Unlimited | 2, 4, 8, or 72 | 0.25 to 4 | Unlimited | 1 to 6 |\n| **RAM** | Unlimited | 3gb, 7gb, 15gb, or 145gb | 512mb to 30gb | Unlimited | 128mb to 10gb |\n| **Storage** | Unlimited | 50gb to 824gb | 20gb to 200gb | Unlimited | Up to 10gb |\n| **Architecture** | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 | x86_64, ARM64 |\n| **sudo** | ✔ | ✔ | ✔ | ✔ | ❌ |\n| **Docker** | ✔ | ✔ (Linux only) | ❌ | ✔ | ❌ |\n| **Spot pricing** | ✔ | ❌ | ✔ | ✔ | ❌ |\n| **OS** | Linux, Windows | Linux, Windows | Linux, Windows | Linux, Windows | Linux |\n\nThe best provider to use mostly depends on your current infrastructure. When in doubt, CodeBuild is always a good choice. Execution history and logs are easy to view, and it has no restrictive limits unless you need to run for more than 8 hours.\n\n* EC2 is useful when you want runners to have complete access to the host\n* ECS is useful when you want to control the infrastructure, like leaving the runner host running for faster startups\n* Lambda is useful for short jobs that can work within time, size and readonly system constraints\n\nYou can also create your own provider by implementing `IRunnerProvider`.\n\n## Installation\n\n1. Install and use the appropriate package\n <details><summary>Python</summary>\n\n ### Install\n Available on [PyPI][6].\n ```bash\n pip install cloudsnorkel.cdk-github-runners\n ```\n ### Use\n ```python\n from aws_cdk import App, Stack\n from cloudsnorkel.cdk_github_runners import GitHubRunners\n\n app = App()\n stack = Stack(app, \"github-runners\")\n GitHubRunners(stack, \"runners\")\n\n app.synth()\n ```\n </details>\n <details><summary>TypeScript or JavaScript</summary>\n\n ### Install\n Available on [npm][7].\n ```bash\n npm i @cloudsnorkel/cdk-github-runners\n ```\n ### Use\n ```typescript\n import { App, Stack } from 'aws-cdk-lib';\n import { GitHubRunners } from '@cloudsnorkel/cdk-github-runners';\n\n const app = new App();\n const stack = new Stack(app, 'github-runners');\n new GitHubRunners(stack, 'runners');\n\n app.synth();\n ```\n </details>\n <details><summary>Java</summary>\n\n ### Install\n Available on [Maven][8].\n ```xml\n <dependency>\n <groupId>com.cloudsnorkel</groupId>\n <artifactId>cdk.github.runners</artifactId>\n </dependency>\n ```\n ### Use\n ```java\n import software.amazon.awscdk.App;\n import software.amazon.awscdk.Stack;\n import com.cloudsnorkel.cdk.github.runners.GitHubRunners;\n\n public class Example {\n public static void main(String[] args){\n App app = new App();\n Stack stack = new Stack(app, \"github-runners\");\n GitHubRunners.Builder.create(stack, \"runners\").build();\n\n app.synth();\n }\n }\n ```\n </details>\n <details><summary>Go</summary>\n\n ### Install\n Available on [GitHub][11].\n ```bash\n go get github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\n ```\n ### Use\n ```go\n package main\n\n import (\n \"github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\"\n \"github.com/aws/aws-cdk-go/awscdk/v2\"\n \"github.com/aws/jsii-runtime-go\"\n )\n\n func main() {\n app := awscdk.NewApp(nil)\n stack := awscdk.NewStack(app, jsii.String(\"github-runners\"), &awscdk.StackProps{})\n cloudsnorkelcdkgithubrunners.NewGitHubRunners(stack, jsii.String(\"runners\"), &cloudsnorkelcdkgithubrunners.GitHubRunnersProps{})\n\n app.Synth(nil)\n }\n ```\n </details>\n <details><summary>.NET</summary>\n\n ### Install\n Available on [Nuget][12].\n ```bash\n dotnet add package CloudSnorkel.Cdk.Github.Runners\n ```\n ### Use\n ```csharp\n using Amazon.CDK;\n using CloudSnorkel;\n\n namespace Example\n {\n sealed class Program\n {\n public static void Main(string[] args)\n {\n var app = new App();\n var stack = new Stack(app, \"github-runners\");\n new GitHubRunners(stack, \"runners\");\n app.Synth();\n }\n }\n }\n ```\n </details>\n2. Use `GitHubRunners` construct in your code (starting with default arguments is fine)\n3. Deploy your stack\n4. Look for the status command output similar to `aws --region us-east-1 lambda invoke --function-name status-XYZ123 status.json`\n ```\n ✅ github-runners-test\n\n ✨ Deployment time: 260.01s\n\n Outputs:\n github-runners-test.runnersstatuscommand4A30F0F5 = aws --region us-east-1 lambda invoke --function-name github-runners-test-runnersstatus1A5771C0-mvttg8oPQnQS status.json\n ```\n5. Execute the status command (you may need to specify `--profile` too) and open the resulting `status.json` file\n6. Open the URL in `github.setup.url` from `status.json` or [manually setup GitHub](SETUP_GITHUB.md) integration as an app or with personal access token\n7. Run status command again to confirm `github.auth.status` and `github.webhook.status` are OK\n8. Trigger a GitHub action that has a `self-hosted` label with `runs-on: [self-hosted, codebuild]` (or non-default labels you set in step 2)\n9. If the action is not successful, see [troubleshooting](#Troubleshooting)\n\n[![Demo](demo-thumbnail.jpg)](https://youtu.be/wlyv_3V8lIw)\n\n## Customizing\n\nThe default providers configured by `GitHubRunners` are useful for testing but probably not too much for actual production work. They run in the default VPC or no VPC and have no added IAM permissions. You would usually want to configure the providers yourself.\n\nFor example:\n\n```typescript\nlet vpc: ec2.Vpc;\nlet runnerSg: ec2.SecurityGroup;\nlet dbSg: ec2.SecurityGroup;\nlet bucket: s3.Bucket;\n\n// create a custom CodeBuild provider\nconst myProvider = new CodeBuildRunnerProvider(this, 'codebuild runner', {\n labels: ['my-codebuild'],\n vpc: vpc,\n securityGroups: [runnerSg],\n});\n// grant some permissions to the provider\nbucket.grantReadWrite(myProvider);\ndbSg.connections.allowFrom(runnerSg, ec2.Port.tcp(3306), 'allow runners to connect to MySQL database');\n\n// create the runner infrastructure\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nAnother way to customize runners is by modifying the image used to spin them up. The image contains the [runner][5], any required dependencies, and integration code with the provider. You may choose to customize this image by adding more packages, for example.\n\n```typescript\nconst myBuilder = FargateRunnerProvider.imageBuilder(this, 'image builder');\nmyBuilder.addComponent(\n RunnerImageComponent.custom({ commands: ['apt install -y nginx xz-utils'] }),\n);\n\nconst myProvider = new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['customized-fargate'],\n imageBuilder: myBuilder,\n});\n\n// create the runner infrastructure\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nYour workflow will then look like:\n\n```yaml\nname: self-hosted example\non: push\njobs:\n self-hosted:\n runs-on: [self-hosted, customized-fargate]\n steps:\n - run: echo hello world\n```\n\nWindows images can also be customized the same way.\n\n```typescript\nconst myWindowsBuilder = FargateRunnerProvider.imageBuilder(this, 'Windows image builder', {\n architecture: Architecture.X86_64,\n os: Os.WINDOWS,\n});\nmyWindowsBuilder.addComponent(\n RunnerImageComponent.custom({\n name: 'Ninja',\n commands: [\n 'Invoke-WebRequest -UseBasicParsing -Uri \"https://github.com/ninja-build/ninja/releases/download/v1.11.1/ninja-win.zip\" -OutFile ninja.zip',\n 'Expand-Archive ninja.zip -DestinationPath C:\\\\actions',\n 'del ninja.zip',\n ],\n }),\n);\n\nconst myProvider = new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['customized-windows-fargate'],\n imageBuilder: myWindowsBuilder,\n});\n\nnew GitHubRunners(this, 'runners', {\n providers: [myProvider],\n});\n```\n\nThe runner OS and architecture is determined by the image it is set to use. For example, to create a Fargate runner provider for ARM64 set the `architecture` property for the image builder to `Architecture.ARM64` in the image builder properties.\n\n```typescript\nnew GitHubRunners(this, 'runners', {\n providers: [\n new FargateRunnerProvider(this, 'fargate runner', {\n labels: ['arm64', 'fargate'],\n imageBuilder: FargateRunnerProvider.imageBuilder(this, 'image builder', {\n architecture: Architecture.ARM64,\n os: Os.LINUX_UBUNTU,\n }),\n }),\n ],\n});\n```\n\n### Composite Providers\n\nComposite providers allow you to combine multiple runner providers with different strategies. There are two types:\n\n**Fallback Strategy**: Try providers in order until one succeeds. Useful for trying spot instances first, then falling back to on-demand if spot capacity is unavailable.\n\n```typescript\n// Try spot instances first, fall back to on-demand if spot is unavailable\nconst ecsFallback = CompositeProvider.fallback(this, 'ECS Fallback', [\n new EcsRunnerProvider(this, 'ECS Spot', {\n labels: ['ecs', 'linux', 'x64'],\n spot: true,\n // ... other config\n }),\n new EcsRunnerProvider(this, 'ECS On-Demand', {\n labels: ['ecs', 'linux', 'x64'],\n spot: false,\n // ... other config\n }),\n]);\n\nnew GitHubRunners(this, 'runners', {\n providers: [ecsFallback],\n});\n```\n\n**Weighted Distribution Strategy**: Randomly select a provider based on weights. Useful for distributing load across multiple availability zones or instance types.\n\n```typescript\n// Distribute 60% of traffic to AZ-1, 40% to AZ-2\nconst distributedProvider = CompositeProvider.distribute(this, 'Fargate Distribution', [\n {\n weight: 3, // 3/(3+2) = 60%\n provider: new FargateRunnerProvider(this, 'Fargate AZ-1', {\n labels: ['fargate', 'linux', 'x64'],\n subnetSelection: vpc.selectSubnets({\n availabilityZones: [vpc.availabilityZones[0]],\n }),\n // ... other config\n }),\n },\n {\n weight: 2, // 2/(3+2) = 40%\n provider: new FargateRunnerProvider(this, 'Fargate AZ-2', {\n labels: ['fargate', 'linux', 'x64'],\n subnetSelection: vpc.selectSubnets({\n availabilityZones: [vpc.availabilityZones[1]],\n }),\n // ... other config\n }),\n },\n]);\n\nnew GitHubRunners(this, 'runners', {\n providers: [distributedProvider],\n});\n```\n\n**Important**: All providers in a composite must have the exact same labels. This ensures any provisioned runner can match the labels requested by the GitHub workflow job.\n\n### Custom Provider Selection\n\nBy default, providers are selected based on label matching: the first provider that has all the labels requested by the job is selected. You can customize this behavior using a provider selector Lambda function to:\n\n* Filter out certain jobs (prevent runner provisioning)\n* Dynamically select a provider based on job characteristics (repository, branch, time of day, etc.)\n* Customize labels for the runner (add, remove, or modify labels dynamically)\n\nThe selector function receives the full GitHub webhook payload, a map of all available providers and their labels, and the default provider/labels that would have been selected. It returns the provider to use (or `undefined` to skip runner creation) and the labels to assign to the runner.\n\n**Example: Route jobs to different providers based on repository**\n\n```typescript\nimport { ComputeType } from 'aws-cdk-lib/aws-codebuild';\nimport { Function, Code, Runtime } from 'aws-cdk-lib/aws-lambda';\nimport { GitHubRunners, CodeBuildRunnerProvider } from '@cloudsnorkel/cdk-github-runners';\n\nconst defaultProvider = new CodeBuildRunnerProvider(this, 'default', {\n labels: ['custom-runner', 'default'],\n});\nconst productionProvider = new CodeBuildRunnerProvider(this, 'production', {\n labels: ['custom-runner', 'production'],\n computeType: ComputeType.LARGE,\n});\n\nconst providerSelector = new Function(this, 'provider-selector', {\n runtime: Runtime.NODEJS_LATEST,\n handler: 'index.handler',\n code: Code.fromInline(`\n exports.handler = async (event) => {\n const { payload, providers, defaultProvider, defaultLabels } = event;\n\n // Route production repos to dedicated provider\n if (payload.repository.name.includes('prod')) {\n return {\n provider: '${productionProvider.node.path}',\n labels: ['custom-runner', 'production', 'modified-via-selector'],\n };\n }\n\n // Filter out draft PRs\n if (payload.workflow_job.head_branch?.startsWith('draft/')) {\n return { provider: undefined }; // Skip runner provisioning\n }\n\n // Use default for everything else\n return {\n provider: defaultProvider,\n labels: defaultLabels,\n };\n };\n `),\n});\n\nnew GitHubRunners(this, 'runners', {\n providers: [defaultProvider, productionProvider],\n providerSelector: providerSelector,\n});\n```\n\n**Example: Add dynamic labels based on job metadata**\n\n```typescript\nconst providerSelector = new Function(this, 'provider-selector', {\n runtime: Runtime.NODEJS_LATEST,\n handler: 'index.handler',\n code: Code.fromInline(`\n exports.handler = async (event) => {\n const { payload, defaultProvider, defaultLabels } = event;\n\n // Add branch name as a label\n const branch = payload.workflow_job.head_branch || 'unknown';\n const labels = [...(defaultLabels || []), 'branch:' + branch];\n\n return {\n provider: defaultProvider,\n labels: labels,\n };\n };\n `),\n});\n```\n\n**Important considerations:**\n\n* ⚠️ **Label matching responsibility**: You are responsible for ensuring the selected provider's labels match what the job requires. If labels don't match, the runner will be provisioned but GitHub Actions won't assign the job to it.\n* ⚠️ **No guarantee of assignment**: Provider selection only determines which provider will provision a runner. GitHub Actions may still route the job to any available runner with matching labels. For reliable provider assignment, consider repo-level runner registration (the default).\n* ⚡ **Performance**: The selector runs synchronously during webhook processing. Keep it fast and efficient—the webhook has a 30-second timeout total.\n\n## Examples\n\nBeyond the code snippets above, the fullest example available is the [integration test](test/default.integ.ts).\n\nIf you have more to share, please open a PR adding them to the `examples` folder.\n\n## Architecture\n\n![Architecture diagram](architecture.svg)\n\n## Troubleshooting\n\nRunners are started in response to a webhook coming in from GitHub. If there are any issues starting the runner like missing capacity or transient API issues, the provider will keep retrying for 24 hours. Configuration issue related errors like pointing to a missing AMI will not be retried. GitHub itself will cancel the job if it can't find a runner for 24 hours. If your jobs don't start, follow the steps below to examine all parts of this workflow.\n\n1. Always start with the status function, make sure no errors are reported, and confirm all status codes are OK\n2. Make sure `runs-on` in the workflow matches the expected labels set in the runner provider\n3. Diagnose relevant executions of the orchestrator step function by visiting the URL in `troubleshooting.stepFunctionUrl` from `status.json`\n 1. If the execution failed, check your runner provider configuration for errors\n 2. If the execution is still running for a long time, check the execution events to see why runner starting is being retried\n 3. If there are no relevant executions, move to the next step\n4. Confirm the webhook Lambda was called by visiting the URL in `troubleshooting.webhookHandlerUrl` from `status.json`\n 1. If it's not called or logs errors, confirm the webhook settings on the GitHub side\n 2. If you see too many errors, make sure you're only sending `workflow_job` events\n5. When using GitHub app, make sure there are active installations in `github.auth.app.installations`\n\nAll logs are saved in CloudWatch.\n* Log group names can be found in `status.json` for each provider, image builder, and other parts of the system\n* Some useful Logs Insights queries can be enabled with `GitHubRunners.createLogsInsightsQueries()`\n\nTo get `status.json`, check out the CloudFormation stack output for a command that generates it. The command looks like:\n\n```\naws --region us-east-1 lambda invoke --function-name status-XYZ123 status.json\n```\n\n## Monitoring\n\nThere are two important ways to monitor your runners:\n\n1. Make sure runners don't fail to start. When that happens, jobs may sit and wait. Use `GitHubRunners.metricFailed()` to get a metric for the number of failed runner starts. You should use this metric to trigger an alarm.\n2. Make sure runner images don't fail to build. Failed runner image builds mean you will get stuck with out-of-date software on your runners. It may lead to security vulnerabilities, or it may lead to slower runner start-ups as the runner software itself needs to be updated. Use `GitHubRunners.failedImageBuildsTopic()` to get SNS topic that gets notified of failed runner image builds. You should subscribe to this topic.\n\nOther useful metrics to track:\n\n1. Use `GitHubRunners.metricJobCompleted()` to get a metric for the number of completed jobs broken down by labels and job success.\n2. Use `GitHubRunners.metricTime()` to get a metric for the total time a runner is running. This includes the overhead of starting the runner.\n\n## Contributing\n\nIf you use and love this project, please consider contributing.\n\n1. 🪳 If you see something, say something. [Issues][16] help improve the quality of the project.\n * Include relevant logs and package versions for bugs.\n * When possible, describe the use-case behind feature requests.\n1. 🛠️ [Pull requests][17] are welcome.\n * Run `npm run build` before submitting to make sure all tests pass.\n * Allow edits from maintainers so small adjustments can be made easily.\n1. 💵 Consider [sponsoring][15] the project to show your support and optionally get your name listed below.\n\n## Other Options\n\n1. [philips-labs/terraform-aws-github-runner][3] if you're using Terraform\n2. [actions/actions-runner-controller][4] if you're using Kubernetes\n\n\n[1]: https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners\n[2]: https://github.com/marketplace/actions/configure-aws-credentials-action-for-github-actions\n[3]: https://github.com/philips-labs/terraform-aws-github-runner\n[4]: https://github.com/actions/actions-runner-controller\n[5]: https://github.com/actions/runner\n[6]: https://pypi.org/project/cloudsnorkel.cdk-github-runners\n[7]: https://www.npmjs.com/package/@cloudsnorkel/cdk-github-runners\n[8]: https://central.sonatype.com/artifact/com.cloudsnorkel/cdk.github.runners/\n[9]: https://docs.github.com/en/developers/apps/getting-started-with-apps/about-apps\n[10]: https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token\n[11]: https://pkg.go.dev/github.com/CloudSnorkel/cdk-github-runners-go/cloudsnorkelcdkgithubrunners\n[12]: https://www.nuget.org/packages/CloudSnorkel.Cdk.Github.Runners/\n[13]: https://constructs.dev/packages/@cloudsnorkel/cdk-github-runners/\n[14]: https://docs.github.com/en/actions/hosting-your-own-runners/autoscaling-with-self-hosted-runners#using-ephemeral-runners-for-autoscaling\n[15]: https://github.com/sponsors/CloudSnorkel\n[16]: https://github.com/CloudSnorkel/cdk-github-runners/issues\n[17]: https://github.com/CloudSnorkel/cdk-github-runners/pulls\n"
3862
3862
  },
3863
3863
  "repository": {
3864
3864
  "type": "git",
@@ -4813,7 +4813,7 @@
4813
4813
  "kind": "interface",
4814
4814
  "locationInModule": {
4815
4815
  "filename": "src/image-builders/aws-image-builder/builder.ts",
4816
- "line": 34
4816
+ "line": 33
4817
4817
  },
4818
4818
  "name": "AwsImageBuilderRunnerImageBuilderProps",
4819
4819
  "properties": [
@@ -4828,7 +4828,7 @@
4828
4828
  "immutable": true,
4829
4829
  "locationInModule": {
4830
4830
  "filename": "src/image-builders/aws-image-builder/builder.ts",
4831
- "line": 58
4831
+ "line": 57
4832
4832
  },
4833
4833
  "name": "fastLaunchOptions",
4834
4834
  "optional": true,
@@ -4846,7 +4846,7 @@
4846
4846
  "immutable": true,
4847
4847
  "locationInModule": {
4848
4848
  "filename": "src/image-builders/aws-image-builder/builder.ts",
4849
- "line": 40
4849
+ "line": 39
4850
4850
  },
4851
4851
  "name": "instanceType",
4852
4852
  "optional": true,
@@ -4865,7 +4865,7 @@
4865
4865
  "immutable": true,
4866
4866
  "locationInModule": {
4867
4867
  "filename": "src/image-builders/aws-image-builder/builder.ts",
4868
- "line": 49
4868
+ "line": 48
4869
4869
  },
4870
4870
  "name": "storageSize",
4871
4871
  "optional": true,
@@ -5416,7 +5416,7 @@
5416
5416
  },
5417
5417
  "locationInModule": {
5418
5418
  "filename": "src/providers/codebuild.ts",
5419
- "line": 243
5419
+ "line": 244
5420
5420
  },
5421
5421
  "parameters": [
5422
5422
  {
@@ -5443,7 +5443,7 @@
5443
5443
  "kind": "class",
5444
5444
  "locationInModule": {
5445
5445
  "filename": "src/providers/codebuild.ts",
5446
- "line": 473
5446
+ "line": 480
5447
5447
  },
5448
5448
  "name": "CodeBuildRunner",
5449
5449
  "symbolId": "src/providers/codebuild:CodeBuildRunner"
@@ -5537,7 +5537,7 @@
5537
5537
  },
5538
5538
  "locationInModule": {
5539
5539
  "filename": "src/providers/codebuild.ts",
5540
- "line": 243
5540
+ "line": 244
5541
5541
  },
5542
5542
  "parameters": [
5543
5543
  {
@@ -5567,7 +5567,7 @@
5567
5567
  "kind": "class",
5568
5568
  "locationInModule": {
5569
5569
  "filename": "src/providers/codebuild.ts",
5570
- "line": 139
5570
+ "line": 140
5571
5571
  },
5572
5572
  "methods": [
5573
5573
  {
@@ -5578,7 +5578,7 @@
5578
5578
  },
5579
5579
  "locationInModule": {
5580
5580
  "filename": "src/providers/codebuild.ts",
5581
- "line": 188
5581
+ "line": 189
5582
5582
  },
5583
5583
  "name": "imageBuilder",
5584
5584
  "parameters": [
@@ -5617,7 +5617,7 @@
5617
5617
  },
5618
5618
  "locationInModule": {
5619
5619
  "filename": "src/providers/codebuild.ts",
5620
- "line": 392
5620
+ "line": 394
5621
5621
  },
5622
5622
  "name": "getStepFunctionTask",
5623
5623
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5646,7 +5646,7 @@
5646
5646
  },
5647
5647
  "locationInModule": {
5648
5648
  "filename": "src/providers/codebuild.ts",
5649
- "line": 441
5649
+ "line": 447
5650
5650
  },
5651
5651
  "name": "grantStateMachine",
5652
5652
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5665,7 +5665,7 @@
5665
5665
  },
5666
5666
  "locationInModule": {
5667
5667
  "filename": "src/providers/common.ts",
5668
- "line": 556
5668
+ "line": 612
5669
5669
  },
5670
5670
  "name": "labelsFromProperties",
5671
5671
  "parameters": [
@@ -5715,7 +5715,7 @@
5715
5715
  },
5716
5716
  "locationInModule": {
5717
5717
  "filename": "src/providers/codebuild.ts",
5718
- "line": 444
5718
+ "line": 450
5719
5719
  },
5720
5720
  "name": "status",
5721
5721
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5747,7 +5747,7 @@
5747
5747
  "immutable": true,
5748
5748
  "locationInModule": {
5749
5749
  "filename": "src/providers/codebuild.ts",
5750
- "line": 168
5750
+ "line": 169
5751
5751
  },
5752
5752
  "name": "LINUX_ARM64_DOCKERFILE_PATH",
5753
5753
  "static": true,
@@ -5766,7 +5766,7 @@
5766
5766
  "immutable": true,
5767
5767
  "locationInModule": {
5768
5768
  "filename": "src/providers/codebuild.ts",
5769
- "line": 153
5769
+ "line": 154
5770
5770
  },
5771
5771
  "name": "LINUX_X64_DOCKERFILE_PATH",
5772
5772
  "static": true,
@@ -5782,7 +5782,7 @@
5782
5782
  "immutable": true,
5783
5783
  "locationInModule": {
5784
5784
  "filename": "src/providers/codebuild.ts",
5785
- "line": 465
5785
+ "line": 472
5786
5786
  },
5787
5787
  "name": "connections",
5788
5788
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -5798,7 +5798,7 @@
5798
5798
  "immutable": true,
5799
5799
  "locationInModule": {
5800
5800
  "filename": "src/providers/codebuild.ts",
5801
- "line": 218
5801
+ "line": 219
5802
5802
  },
5803
5803
  "name": "grantPrincipal",
5804
5804
  "overrides": "aws-cdk-lib.aws_iam.IGrantable",
@@ -5815,7 +5815,7 @@
5815
5815
  "immutable": true,
5816
5816
  "locationInModule": {
5817
5817
  "filename": "src/providers/codebuild.ts",
5818
- "line": 223
5818
+ "line": 224
5819
5819
  },
5820
5820
  "name": "image",
5821
5821
  "type": {
@@ -5830,7 +5830,7 @@
5830
5830
  "immutable": true,
5831
5831
  "locationInModule": {
5832
5832
  "filename": "src/providers/codebuild.ts",
5833
- "line": 213
5833
+ "line": 214
5834
5834
  },
5835
5835
  "name": "labels",
5836
5836
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5852,7 +5852,7 @@
5852
5852
  "immutable": true,
5853
5853
  "locationInModule": {
5854
5854
  "filename": "src/providers/codebuild.ts",
5855
- "line": 230
5855
+ "line": 231
5856
5856
  },
5857
5857
  "name": "logGroup",
5858
5858
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5868,7 +5868,7 @@
5868
5868
  "immutable": true,
5869
5869
  "locationInModule": {
5870
5870
  "filename": "src/providers/codebuild.ts",
5871
- "line": 208
5871
+ "line": 209
5872
5872
  },
5873
5873
  "name": "project",
5874
5874
  "type": {
@@ -5883,7 +5883,7 @@
5883
5883
  "immutable": true,
5884
5884
  "locationInModule": {
5885
5885
  "filename": "src/providers/codebuild.ts",
5886
- "line": 232
5886
+ "line": 233
5887
5887
  },
5888
5888
  "name": "retryableErrors",
5889
5889
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -5912,7 +5912,7 @@
5912
5912
  "kind": "interface",
5913
5913
  "locationInModule": {
5914
5914
  "filename": "src/providers/codebuild.ts",
5915
- "line": 31
5915
+ "line": 32
5916
5916
  },
5917
5917
  "name": "CodeBuildRunnerProviderProps",
5918
5918
  "properties": [
@@ -5927,7 +5927,7 @@
5927
5927
  "immutable": true,
5928
5928
  "locationInModule": {
5929
5929
  "filename": "src/providers/codebuild.ts",
5930
- "line": 112
5930
+ "line": 113
5931
5931
  },
5932
5932
  "name": "computeType",
5933
5933
  "optional": true,
@@ -5946,7 +5946,7 @@
5946
5946
  "immutable": true,
5947
5947
  "locationInModule": {
5948
5948
  "filename": "src/providers/codebuild.ts",
5949
- "line": 129
5949
+ "line": 130
5950
5950
  },
5951
5951
  "name": "dockerInDocker",
5952
5952
  "optional": true,
@@ -5965,7 +5965,7 @@
5965
5965
  "immutable": true,
5966
5966
  "locationInModule": {
5967
5967
  "filename": "src/providers/codebuild.ts",
5968
- "line": 74
5968
+ "line": 75
5969
5969
  },
5970
5970
  "name": "group",
5971
5971
  "optional": true,
@@ -5984,7 +5984,7 @@
5984
5984
  "immutable": true,
5985
5985
  "locationInModule": {
5986
5986
  "filename": "src/providers/codebuild.ts",
5987
- "line": 41
5987
+ "line": 42
5988
5988
  },
5989
5989
  "name": "imageBuilder",
5990
5990
  "optional": true,
@@ -6003,7 +6003,7 @@
6003
6003
  "immutable": true,
6004
6004
  "locationInModule": {
6005
6005
  "filename": "src/providers/codebuild.ts",
6006
- "line": 49
6006
+ "line": 50
6007
6007
  },
6008
6008
  "name": "label",
6009
6009
  "optional": true,
@@ -6022,7 +6022,7 @@
6022
6022
  "immutable": true,
6023
6023
  "locationInModule": {
6024
6024
  "filename": "src/providers/codebuild.ts",
6025
- "line": 60
6025
+ "line": 61
6026
6026
  },
6027
6027
  "name": "labels",
6028
6028
  "optional": true,
@@ -6046,7 +6046,7 @@
6046
6046
  "immutable": true,
6047
6047
  "locationInModule": {
6048
6048
  "filename": "src/providers/codebuild.ts",
6049
- "line": 90
6049
+ "line": 91
6050
6050
  },
6051
6051
  "name": "securityGroup",
6052
6052
  "optional": true,
@@ -6064,7 +6064,7 @@
6064
6064
  "immutable": true,
6065
6065
  "locationInModule": {
6066
6066
  "filename": "src/providers/codebuild.ts",
6067
- "line": 97
6067
+ "line": 98
6068
6068
  },
6069
6069
  "name": "securityGroups",
6070
6070
  "optional": true,
@@ -6087,7 +6087,7 @@
6087
6087
  "immutable": true,
6088
6088
  "locationInModule": {
6089
6089
  "filename": "src/providers/codebuild.ts",
6090
- "line": 104
6090
+ "line": 105
6091
6091
  },
6092
6092
  "name": "subnetSelection",
6093
6093
  "optional": true,
@@ -6106,7 +6106,7 @@
6106
6106
  "immutable": true,
6107
6107
  "locationInModule": {
6108
6108
  "filename": "src/providers/codebuild.ts",
6109
- "line": 121
6109
+ "line": 122
6110
6110
  },
6111
6111
  "name": "timeout",
6112
6112
  "optional": true,
@@ -6124,7 +6124,7 @@
6124
6124
  "immutable": true,
6125
6125
  "locationInModule": {
6126
6126
  "filename": "src/providers/codebuild.ts",
6127
- "line": 81
6127
+ "line": 82
6128
6128
  },
6129
6129
  "name": "vpc",
6130
6130
  "optional": true,
@@ -6135,6 +6135,132 @@
6135
6135
  ],
6136
6136
  "symbolId": "src/providers/codebuild:CodeBuildRunnerProviderProps"
6137
6137
  },
6138
+ "@cloudsnorkel/cdk-github-runners.CompositeProvider": {
6139
+ "assembly": "@cloudsnorkel/cdk-github-runners",
6140
+ "docs": {
6141
+ "stability": "experimental",
6142
+ "summary": "A composite runner provider that implements fallback and distribution strategies."
6143
+ },
6144
+ "fqn": "@cloudsnorkel/cdk-github-runners.CompositeProvider",
6145
+ "initializer": {
6146
+ "docs": {
6147
+ "stability": "experimental"
6148
+ }
6149
+ },
6150
+ "kind": "class",
6151
+ "locationInModule": {
6152
+ "filename": "src/providers/composite.ts",
6153
+ "line": 24
6154
+ },
6155
+ "methods": [
6156
+ {
6157
+ "docs": {
6158
+ "remarks": "For example, given providers A (weight 10), B (weight 20), C (weight 30):\n- Total weight = 60\n- Probability of selecting A = 10/60 = 16.67%\n- Probability of selecting B = 20/60 = 33.33%\n- Probability of selecting C = 30/60 = 50%\n\nYou can use this to distribute load across multiple instance types or availability zones.",
6159
+ "stability": "experimental",
6160
+ "summary": "Creates a weighted distribution runner provider that randomly selects a provider based on weights."
6161
+ },
6162
+ "locationInModule": {
6163
+ "filename": "src/providers/composite.ts",
6164
+ "line": 66
6165
+ },
6166
+ "name": "distribute",
6167
+ "parameters": [
6168
+ {
6169
+ "docs": {
6170
+ "summary": "The scope in which to define this construct."
6171
+ },
6172
+ "name": "scope",
6173
+ "type": {
6174
+ "fqn": "constructs.Construct"
6175
+ }
6176
+ },
6177
+ {
6178
+ "docs": {
6179
+ "summary": "The scoped construct ID."
6180
+ },
6181
+ "name": "id",
6182
+ "type": {
6183
+ "primitive": "string"
6184
+ }
6185
+ },
6186
+ {
6187
+ "docs": {
6188
+ "summary": "List of weighted runner providers."
6189
+ },
6190
+ "name": "weightedProviders",
6191
+ "type": {
6192
+ "collection": {
6193
+ "elementtype": {
6194
+ "fqn": "@cloudsnorkel/cdk-github-runners.WeightedRunnerProvider"
6195
+ },
6196
+ "kind": "array"
6197
+ }
6198
+ }
6199
+ }
6200
+ ],
6201
+ "returns": {
6202
+ "type": {
6203
+ "fqn": "@cloudsnorkel/cdk-github-runners.ICompositeProvider"
6204
+ }
6205
+ },
6206
+ "static": true
6207
+ },
6208
+ {
6209
+ "docs": {
6210
+ "remarks": "For example, given providers A, B, C:\n- Try A first\n- If A fails, try B\n- If B fails, try C\n\nYou can use this to try spot instance first, and switch to on-demand instances if spot is unavailable.\n\nOr you can use this to try different instance types in order of preference.",
6211
+ "stability": "experimental",
6212
+ "summary": "Creates a fallback runner provider that tries each provider in order until one succeeds."
6213
+ },
6214
+ "locationInModule": {
6215
+ "filename": "src/providers/composite.ts",
6216
+ "line": 41
6217
+ },
6218
+ "name": "fallback",
6219
+ "parameters": [
6220
+ {
6221
+ "docs": {
6222
+ "summary": "The scope in which to define this construct."
6223
+ },
6224
+ "name": "scope",
6225
+ "type": {
6226
+ "fqn": "constructs.Construct"
6227
+ }
6228
+ },
6229
+ {
6230
+ "docs": {
6231
+ "summary": "The scoped construct ID."
6232
+ },
6233
+ "name": "id",
6234
+ "type": {
6235
+ "primitive": "string"
6236
+ }
6237
+ },
6238
+ {
6239
+ "docs": {
6240
+ "summary": "List of runner providers to try in order."
6241
+ },
6242
+ "name": "providers",
6243
+ "type": {
6244
+ "collection": {
6245
+ "elementtype": {
6246
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
6247
+ },
6248
+ "kind": "array"
6249
+ }
6250
+ }
6251
+ }
6252
+ ],
6253
+ "returns": {
6254
+ "type": {
6255
+ "fqn": "@cloudsnorkel/cdk-github-runners.ICompositeProvider"
6256
+ }
6257
+ },
6258
+ "static": true
6259
+ }
6260
+ ],
6261
+ "name": "CompositeProvider",
6262
+ "symbolId": "src/providers/composite:CompositeProvider"
6263
+ },
6138
6264
  "@cloudsnorkel/cdk-github-runners.ContainerImageBuilder": {
6139
6265
  "assembly": "@cloudsnorkel/cdk-github-runners",
6140
6266
  "base": "constructs.Construct",
@@ -6821,7 +6947,7 @@
6821
6947
  },
6822
6948
  "locationInModule": {
6823
6949
  "filename": "src/providers/ec2.ts",
6824
- "line": 387
6950
+ "line": 388
6825
6951
  },
6826
6952
  "parameters": [
6827
6953
  {
@@ -6848,7 +6974,7 @@
6848
6974
  "kind": "class",
6849
6975
  "locationInModule": {
6850
6976
  "filename": "src/providers/ec2.ts",
6851
- "line": 632
6977
+ "line": 634
6852
6978
  },
6853
6979
  "name": "Ec2Runner",
6854
6980
  "symbolId": "src/providers/ec2:Ec2Runner"
@@ -6868,7 +6994,7 @@
6868
6994
  },
6869
6995
  "locationInModule": {
6870
6996
  "filename": "src/providers/ec2.ts",
6871
- "line": 387
6997
+ "line": 388
6872
6998
  },
6873
6999
  "parameters": [
6874
7000
  {
@@ -6898,7 +7024,7 @@
6898
7024
  "kind": "class",
6899
7025
  "locationInModule": {
6900
7026
  "filename": "src/providers/ec2.ts",
6901
- "line": 312
7027
+ "line": 313
6902
7028
  },
6903
7029
  "methods": [
6904
7030
  {
@@ -6909,7 +7035,7 @@
6909
7035
  },
6910
7036
  "locationInModule": {
6911
7037
  "filename": "src/providers/ec2.ts",
6912
- "line": 332
7038
+ "line": 333
6913
7039
  },
6914
7040
  "name": "imageBuilder",
6915
7041
  "parameters": [
@@ -6948,7 +7074,7 @@
6948
7074
  },
6949
7075
  "locationInModule": {
6950
7076
  "filename": "src/providers/ec2.ts",
6951
- "line": 451
7077
+ "line": 452
6952
7078
  },
6953
7079
  "name": "getStepFunctionTask",
6954
7080
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -6977,7 +7103,7 @@
6977
7103
  },
6978
7104
  "locationInModule": {
6979
7105
  "filename": "src/providers/ec2.ts",
6980
- "line": 572
7106
+ "line": 573
6981
7107
  },
6982
7108
  "name": "grantStateMachine",
6983
7109
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -6996,7 +7122,7 @@
6996
7122
  },
6997
7123
  "locationInModule": {
6998
7124
  "filename": "src/providers/common.ts",
6999
- "line": 556
7125
+ "line": 612
7000
7126
  },
7001
7127
  "name": "labelsFromProperties",
7002
7128
  "parameters": [
@@ -7046,7 +7172,7 @@
7046
7172
  },
7047
7173
  "locationInModule": {
7048
7174
  "filename": "src/providers/ec2.ts",
7049
- "line": 602
7175
+ "line": 603
7050
7176
  },
7051
7177
  "name": "status",
7052
7178
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7075,7 +7201,7 @@
7075
7201
  "immutable": true,
7076
7202
  "locationInModule": {
7077
7203
  "filename": "src/providers/ec2.ts",
7078
- "line": 624
7204
+ "line": 626
7079
7205
  },
7080
7206
  "name": "connections",
7081
7207
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -7091,7 +7217,7 @@
7091
7217
  "immutable": true,
7092
7218
  "locationInModule": {
7093
7219
  "filename": "src/providers/ec2.ts",
7094
- "line": 359
7220
+ "line": 360
7095
7221
  },
7096
7222
  "name": "grantPrincipal",
7097
7223
  "overrides": "aws-cdk-lib.aws_iam.IGrantable",
@@ -7107,7 +7233,7 @@
7107
7233
  "immutable": true,
7108
7234
  "locationInModule": {
7109
7235
  "filename": "src/providers/ec2.ts",
7110
- "line": 354
7236
+ "line": 355
7111
7237
  },
7112
7238
  "name": "labels",
7113
7239
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7129,7 +7255,7 @@
7129
7255
  "immutable": true,
7130
7256
  "locationInModule": {
7131
7257
  "filename": "src/providers/ec2.ts",
7132
- "line": 366
7258
+ "line": 367
7133
7259
  },
7134
7260
  "name": "logGroup",
7135
7261
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7145,7 +7271,7 @@
7145
7271
  "immutable": true,
7146
7272
  "locationInModule": {
7147
7273
  "filename": "src/providers/ec2.ts",
7148
- "line": 368
7274
+ "line": 369
7149
7275
  },
7150
7276
  "name": "retryableErrors",
7151
7277
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7175,7 +7301,7 @@
7175
7301
  "kind": "interface",
7176
7302
  "locationInModule": {
7177
7303
  "filename": "src/providers/ec2.ts",
7178
- "line": 194
7304
+ "line": 195
7179
7305
  },
7180
7306
  "name": "Ec2RunnerProviderProps",
7181
7307
  "properties": [
@@ -7188,7 +7314,7 @@
7188
7314
  "immutable": true,
7189
7315
  "locationInModule": {
7190
7316
  "filename": "src/providers/ec2.ts",
7191
- "line": 207
7317
+ "line": 208
7192
7318
  },
7193
7319
  "name": "amiBuilder",
7194
7320
  "optional": true,
@@ -7207,7 +7333,7 @@
7207
7333
  "immutable": true,
7208
7334
  "locationInModule": {
7209
7335
  "filename": "src/providers/ec2.ts",
7210
- "line": 232
7336
+ "line": 233
7211
7337
  },
7212
7338
  "name": "group",
7213
7339
  "optional": true,
@@ -7226,7 +7352,7 @@
7226
7352
  "immutable": true,
7227
7353
  "locationInModule": {
7228
7354
  "filename": "src/providers/ec2.ts",
7229
- "line": 202
7355
+ "line": 203
7230
7356
  },
7231
7357
  "name": "imageBuilder",
7232
7358
  "optional": true,
@@ -7244,7 +7370,7 @@
7244
7370
  "immutable": true,
7245
7371
  "locationInModule": {
7246
7372
  "filename": "src/providers/ec2.ts",
7247
- "line": 239
7373
+ "line": 240
7248
7374
  },
7249
7375
  "name": "instanceType",
7250
7376
  "optional": true,
@@ -7263,7 +7389,7 @@
7263
7389
  "immutable": true,
7264
7390
  "locationInModule": {
7265
7391
  "filename": "src/providers/ec2.ts",
7266
- "line": 218
7392
+ "line": 219
7267
7393
  },
7268
7394
  "name": "labels",
7269
7395
  "optional": true,
@@ -7287,7 +7413,7 @@
7287
7413
  "immutable": true,
7288
7414
  "locationInModule": {
7289
7415
  "filename": "src/providers/ec2.ts",
7290
- "line": 260
7416
+ "line": 261
7291
7417
  },
7292
7418
  "name": "securityGroup",
7293
7419
  "optional": true,
@@ -7305,7 +7431,7 @@
7305
7431
  "immutable": true,
7306
7432
  "locationInModule": {
7307
7433
  "filename": "src/providers/ec2.ts",
7308
- "line": 267
7434
+ "line": 268
7309
7435
  },
7310
7436
  "name": "securityGroups",
7311
7437
  "optional": true,
@@ -7329,7 +7455,7 @@
7329
7455
  "immutable": true,
7330
7456
  "locationInModule": {
7331
7457
  "filename": "src/providers/ec2.ts",
7332
- "line": 297
7458
+ "line": 298
7333
7459
  },
7334
7460
  "name": "spot",
7335
7461
  "optional": true,
@@ -7347,7 +7473,7 @@
7347
7473
  "immutable": true,
7348
7474
  "locationInModule": {
7349
7475
  "filename": "src/providers/ec2.ts",
7350
- "line": 304
7476
+ "line": 305
7351
7477
  },
7352
7478
  "name": "spotMaxPrice",
7353
7479
  "optional": true,
@@ -7364,7 +7490,7 @@
7364
7490
  "immutable": true,
7365
7491
  "locationInModule": {
7366
7492
  "filename": "src/providers/ec2.ts",
7367
- "line": 251
7493
+ "line": 252
7368
7494
  },
7369
7495
  "name": "storageOptions",
7370
7496
  "optional": true,
@@ -7383,7 +7509,7 @@
7383
7509
  "immutable": true,
7384
7510
  "locationInModule": {
7385
7511
  "filename": "src/providers/ec2.ts",
7386
- "line": 246
7512
+ "line": 247
7387
7513
  },
7388
7514
  "name": "storageSize",
7389
7515
  "optional": true,
@@ -7402,7 +7528,7 @@
7402
7528
  "immutable": true,
7403
7529
  "locationInModule": {
7404
7530
  "filename": "src/providers/ec2.ts",
7405
- "line": 276
7531
+ "line": 277
7406
7532
  },
7407
7533
  "name": "subnet",
7408
7534
  "optional": true,
@@ -7421,7 +7547,7 @@
7421
7547
  "immutable": true,
7422
7548
  "locationInModule": {
7423
7549
  "filename": "src/providers/ec2.ts",
7424
- "line": 290
7550
+ "line": 291
7425
7551
  },
7426
7552
  "name": "subnetSelection",
7427
7553
  "optional": true,
@@ -7439,7 +7565,7 @@
7439
7565
  "immutable": true,
7440
7566
  "locationInModule": {
7441
7567
  "filename": "src/providers/ec2.ts",
7442
- "line": 283
7568
+ "line": 284
7443
7569
  },
7444
7570
  "name": "vpc",
7445
7571
  "optional": true,
@@ -7465,7 +7591,7 @@
7465
7591
  },
7466
7592
  "locationInModule": {
7467
7593
  "filename": "src/providers/ecs.ts",
7468
- "line": 394
7594
+ "line": 395
7469
7595
  },
7470
7596
  "parameters": [
7471
7597
  {
@@ -7495,7 +7621,7 @@
7495
7621
  "kind": "class",
7496
7622
  "locationInModule": {
7497
7623
  "filename": "src/providers/ecs.ts",
7498
- "line": 259
7624
+ "line": 260
7499
7625
  },
7500
7626
  "methods": [
7501
7627
  {
@@ -7506,7 +7632,7 @@
7506
7632
  },
7507
7633
  "locationInModule": {
7508
7634
  "filename": "src/providers/ecs.ts",
7509
- "line": 278
7635
+ "line": 279
7510
7636
  },
7511
7637
  "name": "imageBuilder",
7512
7638
  "parameters": [
@@ -7545,7 +7671,7 @@
7545
7671
  },
7546
7672
  "locationInModule": {
7547
7673
  "filename": "src/providers/ecs.ts",
7548
- "line": 618
7674
+ "line": 619
7549
7675
  },
7550
7676
  "name": "getStepFunctionTask",
7551
7677
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7574,7 +7700,7 @@
7574
7700
  },
7575
7701
  "locationInModule": {
7576
7702
  "filename": "src/providers/ecs.ts",
7577
- "line": 680
7703
+ "line": 685
7578
7704
  },
7579
7705
  "name": "grantStateMachine",
7580
7706
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7593,7 +7719,7 @@
7593
7719
  },
7594
7720
  "locationInModule": {
7595
7721
  "filename": "src/providers/common.ts",
7596
- "line": 556
7722
+ "line": 612
7597
7723
  },
7598
7724
  "name": "labelsFromProperties",
7599
7725
  "parameters": [
@@ -7643,7 +7769,7 @@
7643
7769
  },
7644
7770
  "locationInModule": {
7645
7771
  "filename": "src/providers/ecs.ts",
7646
- "line": 683
7772
+ "line": 688
7647
7773
  },
7648
7774
  "name": "status",
7649
7775
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7672,7 +7798,7 @@
7672
7798
  "immutable": true,
7673
7799
  "locationInModule": {
7674
7800
  "filename": "src/providers/ecs.ts",
7675
- "line": 343
7801
+ "line": 344
7676
7802
  },
7677
7803
  "name": "connections",
7678
7804
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -7688,7 +7814,7 @@
7688
7814
  "immutable": true,
7689
7815
  "locationInModule": {
7690
7816
  "filename": "src/providers/ecs.ts",
7691
- "line": 338
7817
+ "line": 339
7692
7818
  },
7693
7819
  "name": "grantPrincipal",
7694
7820
  "overrides": "aws-cdk-lib.aws_iam.IGrantable",
@@ -7704,7 +7830,7 @@
7704
7830
  "immutable": true,
7705
7831
  "locationInModule": {
7706
7832
  "filename": "src/providers/ecs.ts",
7707
- "line": 318
7833
+ "line": 319
7708
7834
  },
7709
7835
  "name": "labels",
7710
7836
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7726,7 +7852,7 @@
7726
7852
  "immutable": true,
7727
7853
  "locationInModule": {
7728
7854
  "filename": "src/providers/ecs.ts",
7729
- "line": 355
7855
+ "line": 356
7730
7856
  },
7731
7857
  "name": "logGroup",
7732
7858
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7742,7 +7868,7 @@
7742
7868
  "immutable": true,
7743
7869
  "locationInModule": {
7744
7870
  "filename": "src/providers/ecs.ts",
7745
- "line": 387
7871
+ "line": 388
7746
7872
  },
7747
7873
  "name": "retryableErrors",
7748
7874
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -7772,7 +7898,7 @@
7772
7898
  "kind": "interface",
7773
7899
  "locationInModule": {
7774
7900
  "filename": "src/providers/ecs.ts",
7775
- "line": 37
7901
+ "line": 38
7776
7902
  },
7777
7903
  "name": "EcsRunnerProviderProps",
7778
7904
  "properties": [
@@ -7787,7 +7913,7 @@
7787
7913
  "immutable": true,
7788
7914
  "locationInModule": {
7789
7915
  "filename": "src/providers/ecs.ts",
7790
- "line": 116
7916
+ "line": 117
7791
7917
  },
7792
7918
  "name": "assignPublicIp",
7793
7919
  "optional": true,
@@ -7806,7 +7932,7 @@
7806
7932
  "immutable": true,
7807
7933
  "locationInModule": {
7808
7934
  "filename": "src/providers/ecs.ts",
7809
- "line": 107
7935
+ "line": 108
7810
7936
  },
7811
7937
  "name": "capacityProvider",
7812
7938
  "optional": true,
@@ -7824,7 +7950,7 @@
7824
7950
  "immutable": true,
7825
7951
  "locationInModule": {
7826
7952
  "filename": "src/providers/ecs.ts",
7827
- "line": 98
7953
+ "line": 99
7828
7954
  },
7829
7955
  "name": "cluster",
7830
7956
  "optional": true,
@@ -7843,7 +7969,7 @@
7843
7969
  "immutable": true,
7844
7970
  "locationInModule": {
7845
7971
  "filename": "src/providers/ecs.ts",
7846
- "line": 123
7972
+ "line": 124
7847
7973
  },
7848
7974
  "name": "cpu",
7849
7975
  "optional": true,
@@ -7862,7 +7988,7 @@
7862
7988
  "immutable": true,
7863
7989
  "locationInModule": {
7864
7990
  "filename": "src/providers/ecs.ts",
7865
- "line": 180
7991
+ "line": 181
7866
7992
  },
7867
7993
  "name": "dockerInDocker",
7868
7994
  "optional": true,
@@ -7881,7 +8007,7 @@
7881
8007
  "immutable": true,
7882
8008
  "locationInModule": {
7883
8009
  "filename": "src/providers/ecs.ts",
7884
- "line": 70
8010
+ "line": 71
7885
8011
  },
7886
8012
  "name": "group",
7887
8013
  "optional": true,
@@ -7900,7 +8026,7 @@
7900
8026
  "immutable": true,
7901
8027
  "locationInModule": {
7902
8028
  "filename": "src/providers/ecs.ts",
7903
- "line": 45
8029
+ "line": 46
7904
8030
  },
7905
8031
  "name": "imageBuilder",
7906
8032
  "optional": true,
@@ -7919,7 +8045,7 @@
7919
8045
  "immutable": true,
7920
8046
  "locationInModule": {
7921
8047
  "filename": "src/providers/ecs.ts",
7922
- "line": 144
8048
+ "line": 145
7923
8049
  },
7924
8050
  "name": "instanceType",
7925
8051
  "optional": true,
@@ -7938,7 +8064,7 @@
7938
8064
  "immutable": true,
7939
8065
  "locationInModule": {
7940
8066
  "filename": "src/providers/ecs.ts",
7941
- "line": 56
8067
+ "line": 57
7942
8068
  },
7943
8069
  "name": "labels",
7944
8070
  "optional": true,
@@ -7962,7 +8088,7 @@
7962
8088
  "immutable": true,
7963
8089
  "locationInModule": {
7964
8090
  "filename": "src/providers/ecs.ts",
7965
- "line": 158
8091
+ "line": 159
7966
8092
  },
7967
8093
  "name": "maxInstances",
7968
8094
  "optional": true,
@@ -7980,7 +8106,7 @@
7980
8106
  "immutable": true,
7981
8107
  "locationInModule": {
7982
8108
  "filename": "src/providers/ecs.ts",
7983
- "line": 130
8109
+ "line": 131
7984
8110
  },
7985
8111
  "name": "memoryLimitMiB",
7986
8112
  "optional": true,
@@ -7998,7 +8124,7 @@
7998
8124
  "immutable": true,
7999
8125
  "locationInModule": {
8000
8126
  "filename": "src/providers/ecs.ts",
8001
- "line": 137
8127
+ "line": 138
8002
8128
  },
8003
8129
  "name": "memoryReservationMiB",
8004
8130
  "optional": true,
@@ -8017,7 +8143,7 @@
8017
8143
  "immutable": true,
8018
8144
  "locationInModule": {
8019
8145
  "filename": "src/providers/ecs.ts",
8020
- "line": 151
8146
+ "line": 152
8021
8147
  },
8022
8148
  "name": "minInstances",
8023
8149
  "optional": true,
@@ -8036,7 +8162,7 @@
8036
8162
  "immutable": true,
8037
8163
  "locationInModule": {
8038
8164
  "filename": "src/providers/ecs.ts",
8039
- "line": 210
8165
+ "line": 211
8040
8166
  },
8041
8167
  "name": "placementConstraints",
8042
8168
  "optional": true,
@@ -8060,7 +8186,7 @@
8060
8186
  "immutable": true,
8061
8187
  "locationInModule": {
8062
8188
  "filename": "src/providers/ecs.ts",
8063
- "line": 201
8189
+ "line": 202
8064
8190
  },
8065
8191
  "name": "placementStrategies",
8066
8192
  "optional": true,
@@ -8083,7 +8209,7 @@
8083
8209
  "immutable": true,
8084
8210
  "locationInModule": {
8085
8211
  "filename": "src/providers/ecs.ts",
8086
- "line": 91
8212
+ "line": 92
8087
8213
  },
8088
8214
  "name": "securityGroups",
8089
8215
  "optional": true,
@@ -8106,7 +8232,7 @@
8106
8232
  "immutable": true,
8107
8233
  "locationInModule": {
8108
8234
  "filename": "src/providers/ecs.ts",
8109
- "line": 187
8235
+ "line": 188
8110
8236
  },
8111
8237
  "name": "spot",
8112
8238
  "optional": true,
@@ -8123,7 +8249,7 @@
8123
8249
  "immutable": true,
8124
8250
  "locationInModule": {
8125
8251
  "filename": "src/providers/ecs.ts",
8126
- "line": 192
8252
+ "line": 193
8127
8253
  },
8128
8254
  "name": "spotMaxPrice",
8129
8255
  "optional": true,
@@ -8140,7 +8266,7 @@
8140
8266
  "immutable": true,
8141
8267
  "locationInModule": {
8142
8268
  "filename": "src/providers/ecs.ts",
8143
- "line": 172
8269
+ "line": 173
8144
8270
  },
8145
8271
  "name": "storageOptions",
8146
8272
  "optional": true,
@@ -8159,7 +8285,7 @@
8159
8285
  "immutable": true,
8160
8286
  "locationInModule": {
8161
8287
  "filename": "src/providers/ecs.ts",
8162
- "line": 167
8288
+ "line": 168
8163
8289
  },
8164
8290
  "name": "storageSize",
8165
8291
  "optional": true,
@@ -8177,7 +8303,7 @@
8177
8303
  "immutable": true,
8178
8304
  "locationInModule": {
8179
8305
  "filename": "src/providers/ecs.ts",
8180
- "line": 84
8306
+ "line": 85
8181
8307
  },
8182
8308
  "name": "subnetSelection",
8183
8309
  "optional": true,
@@ -8195,7 +8321,7 @@
8195
8321
  "immutable": true,
8196
8322
  "locationInModule": {
8197
8323
  "filename": "src/providers/ecs.ts",
8198
- "line": 77
8324
+ "line": 78
8199
8325
  },
8200
8326
  "name": "vpc",
8201
8327
  "optional": true,
@@ -8220,7 +8346,7 @@
8220
8346
  },
8221
8347
  "locationInModule": {
8222
8348
  "filename": "src/providers/fargate.ts",
8223
- "line": 384
8349
+ "line": 385
8224
8350
  },
8225
8351
  "parameters": [
8226
8352
  {
@@ -8247,7 +8373,7 @@
8247
8373
  "kind": "class",
8248
8374
  "locationInModule": {
8249
8375
  "filename": "src/providers/fargate.ts",
8250
- "line": 560
8376
+ "line": 566
8251
8377
  },
8252
8378
  "name": "FargateRunner",
8253
8379
  "symbolId": "src/providers/fargate:FargateRunner"
@@ -8267,7 +8393,7 @@
8267
8393
  },
8268
8394
  "locationInModule": {
8269
8395
  "filename": "src/providers/fargate.ts",
8270
- "line": 384
8396
+ "line": 385
8271
8397
  },
8272
8398
  "parameters": [
8273
8399
  {
@@ -8297,7 +8423,7 @@
8297
8423
  "kind": "class",
8298
8424
  "locationInModule": {
8299
8425
  "filename": "src/providers/fargate.ts",
8300
- "line": 256
8426
+ "line": 257
8301
8427
  },
8302
8428
  "methods": [
8303
8429
  {
@@ -8308,7 +8434,7 @@
8308
8434
  },
8309
8435
  "locationInModule": {
8310
8436
  "filename": "src/providers/fargate.ts",
8311
- "line": 296
8437
+ "line": 297
8312
8438
  },
8313
8439
  "name": "imageBuilder",
8314
8440
  "parameters": [
@@ -8347,7 +8473,7 @@
8347
8473
  },
8348
8474
  "locationInModule": {
8349
8475
  "filename": "src/providers/fargate.ts",
8350
- "line": 473
8476
+ "line": 474
8351
8477
  },
8352
8478
  "name": "getStepFunctionTask",
8353
8479
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8376,7 +8502,7 @@
8376
8502
  },
8377
8503
  "locationInModule": {
8378
8504
  "filename": "src/providers/fargate.ts",
8379
- "line": 535
8505
+ "line": 540
8380
8506
  },
8381
8507
  "name": "grantStateMachine",
8382
8508
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8395,7 +8521,7 @@
8395
8521
  },
8396
8522
  "locationInModule": {
8397
8523
  "filename": "src/providers/common.ts",
8398
- "line": 556
8524
+ "line": 612
8399
8525
  },
8400
8526
  "name": "labelsFromProperties",
8401
8527
  "parameters": [
@@ -8445,7 +8571,7 @@
8445
8571
  },
8446
8572
  "locationInModule": {
8447
8573
  "filename": "src/providers/fargate.ts",
8448
- "line": 538
8574
+ "line": 543
8449
8575
  },
8450
8576
  "name": "status",
8451
8577
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8477,7 +8603,7 @@
8477
8603
  "immutable": true,
8478
8604
  "locationInModule": {
8479
8605
  "filename": "src/providers/fargate.ts",
8480
- "line": 277
8606
+ "line": 278
8481
8607
  },
8482
8608
  "name": "LINUX_ARM64_DOCKERFILE_PATH",
8483
8609
  "static": true,
@@ -8496,7 +8622,7 @@
8496
8622
  "immutable": true,
8497
8623
  "locationInModule": {
8498
8624
  "filename": "src/providers/fargate.ts",
8499
- "line": 266
8625
+ "line": 267
8500
8626
  },
8501
8627
  "name": "LINUX_X64_DOCKERFILE_PATH",
8502
8628
  "static": true,
@@ -8512,7 +8638,7 @@
8512
8638
  "immutable": true,
8513
8639
  "locationInModule": {
8514
8640
  "filename": "src/providers/fargate.ts",
8515
- "line": 345
8641
+ "line": 346
8516
8642
  },
8517
8643
  "name": "assignPublicIp",
8518
8644
  "type": {
@@ -8527,7 +8653,7 @@
8527
8653
  "immutable": true,
8528
8654
  "locationInModule": {
8529
8655
  "filename": "src/providers/fargate.ts",
8530
- "line": 315
8656
+ "line": 316
8531
8657
  },
8532
8658
  "name": "cluster",
8533
8659
  "type": {
@@ -8542,7 +8668,7 @@
8542
8668
  "immutable": true,
8543
8669
  "locationInModule": {
8544
8670
  "filename": "src/providers/fargate.ts",
8545
- "line": 355
8671
+ "line": 356
8546
8672
  },
8547
8673
  "name": "connections",
8548
8674
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -8558,7 +8684,7 @@
8558
8684
  "immutable": true,
8559
8685
  "locationInModule": {
8560
8686
  "filename": "src/providers/fargate.ts",
8561
- "line": 325
8687
+ "line": 326
8562
8688
  },
8563
8689
  "name": "container",
8564
8690
  "type": {
@@ -8573,7 +8699,7 @@
8573
8699
  "immutable": true,
8574
8700
  "locationInModule": {
8575
8701
  "filename": "src/providers/fargate.ts",
8576
- "line": 350
8702
+ "line": 351
8577
8703
  },
8578
8704
  "name": "grantPrincipal",
8579
8705
  "overrides": "aws-cdk-lib.aws_iam.IGrantable",
@@ -8590,7 +8716,7 @@
8590
8716
  "immutable": true,
8591
8717
  "locationInModule": {
8592
8718
  "filename": "src/providers/fargate.ts",
8593
- "line": 365
8719
+ "line": 366
8594
8720
  },
8595
8721
  "name": "image",
8596
8722
  "type": {
@@ -8605,7 +8731,7 @@
8605
8731
  "immutable": true,
8606
8732
  "locationInModule": {
8607
8733
  "filename": "src/providers/fargate.ts",
8608
- "line": 330
8734
+ "line": 331
8609
8735
  },
8610
8736
  "name": "labels",
8611
8737
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8627,7 +8753,7 @@
8627
8753
  "immutable": true,
8628
8754
  "locationInModule": {
8629
8755
  "filename": "src/providers/fargate.ts",
8630
- "line": 372
8756
+ "line": 373
8631
8757
  },
8632
8758
  "name": "logGroup",
8633
8759
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8643,7 +8769,7 @@
8643
8769
  "immutable": true,
8644
8770
  "locationInModule": {
8645
8771
  "filename": "src/providers/fargate.ts",
8646
- "line": 374
8772
+ "line": 375
8647
8773
  },
8648
8774
  "name": "retryableErrors",
8649
8775
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -8664,7 +8790,7 @@
8664
8790
  "immutable": true,
8665
8791
  "locationInModule": {
8666
8792
  "filename": "src/providers/fargate.ts",
8667
- "line": 360
8793
+ "line": 361
8668
8794
  },
8669
8795
  "name": "spot",
8670
8796
  "type": {
@@ -8679,7 +8805,7 @@
8679
8805
  "immutable": true,
8680
8806
  "locationInModule": {
8681
8807
  "filename": "src/providers/fargate.ts",
8682
- "line": 320
8808
+ "line": 321
8683
8809
  },
8684
8810
  "name": "task",
8685
8811
  "type": {
@@ -8694,7 +8820,7 @@
8694
8820
  "immutable": true,
8695
8821
  "locationInModule": {
8696
8822
  "filename": "src/providers/fargate.ts",
8697
- "line": 340
8823
+ "line": 341
8698
8824
  },
8699
8825
  "name": "subnetSelection",
8700
8826
  "optional": true,
@@ -8710,7 +8836,7 @@
8710
8836
  "immutable": true,
8711
8837
  "locationInModule": {
8712
8838
  "filename": "src/providers/fargate.ts",
8713
- "line": 335
8839
+ "line": 336
8714
8840
  },
8715
8841
  "name": "vpc",
8716
8842
  "optional": true,
@@ -8735,7 +8861,7 @@
8735
8861
  "kind": "interface",
8736
8862
  "locationInModule": {
8737
8863
  "filename": "src/providers/fargate.ts",
8738
- "line": 31
8864
+ "line": 32
8739
8865
  },
8740
8866
  "name": "FargateRunnerProviderProps",
8741
8867
  "properties": [
@@ -8750,7 +8876,7 @@
8750
8876
  "immutable": true,
8751
8877
  "locationInModule": {
8752
8878
  "filename": "src/providers/fargate.ts",
8753
- "line": 118
8879
+ "line": 119
8754
8880
  },
8755
8881
  "name": "assignPublicIp",
8756
8882
  "optional": true,
@@ -8768,7 +8894,7 @@
8768
8894
  "immutable": true,
8769
8895
  "locationInModule": {
8770
8896
  "filename": "src/providers/fargate.ts",
8771
- "line": 109
8897
+ "line": 110
8772
8898
  },
8773
8899
  "name": "cluster",
8774
8900
  "optional": true,
@@ -8787,7 +8913,7 @@
8787
8913
  "immutable": true,
8788
8914
  "locationInModule": {
8789
8915
  "filename": "src/providers/fargate.ts",
8790
- "line": 137
8916
+ "line": 138
8791
8917
  },
8792
8918
  "name": "cpu",
8793
8919
  "optional": true,
@@ -8806,7 +8932,7 @@
8806
8932
  "immutable": true,
8807
8933
  "locationInModule": {
8808
8934
  "filename": "src/providers/fargate.ts",
8809
- "line": 164
8935
+ "line": 165
8810
8936
  },
8811
8937
  "name": "ephemeralStorageGiB",
8812
8938
  "optional": true,
@@ -8825,7 +8951,7 @@
8825
8951
  "immutable": true,
8826
8952
  "locationInModule": {
8827
8953
  "filename": "src/providers/fargate.ts",
8828
- "line": 72
8954
+ "line": 73
8829
8955
  },
8830
8956
  "name": "group",
8831
8957
  "optional": true,
@@ -8844,7 +8970,7 @@
8844
8970
  "immutable": true,
8845
8971
  "locationInModule": {
8846
8972
  "filename": "src/providers/fargate.ts",
8847
- "line": 39
8973
+ "line": 40
8848
8974
  },
8849
8975
  "name": "imageBuilder",
8850
8976
  "optional": true,
@@ -8863,7 +8989,7 @@
8863
8989
  "immutable": true,
8864
8990
  "locationInModule": {
8865
8991
  "filename": "src/providers/fargate.ts",
8866
- "line": 47
8992
+ "line": 48
8867
8993
  },
8868
8994
  "name": "label",
8869
8995
  "optional": true,
@@ -8882,7 +9008,7 @@
8882
9008
  "immutable": true,
8883
9009
  "locationInModule": {
8884
9010
  "filename": "src/providers/fargate.ts",
8885
- "line": 58
9011
+ "line": 59
8886
9012
  },
8887
9013
  "name": "labels",
8888
9014
  "optional": true,
@@ -8906,7 +9032,7 @@
8906
9032
  "immutable": true,
8907
9033
  "locationInModule": {
8908
9034
  "filename": "src/providers/fargate.ts",
8909
- "line": 155
9035
+ "line": 156
8910
9036
  },
8911
9037
  "name": "memoryLimitMiB",
8912
9038
  "optional": true,
@@ -8925,7 +9051,7 @@
8925
9051
  "immutable": true,
8926
9052
  "locationInModule": {
8927
9053
  "filename": "src/providers/fargate.ts",
8928
- "line": 95
9054
+ "line": 96
8929
9055
  },
8930
9056
  "name": "securityGroup",
8931
9057
  "optional": true,
@@ -8943,7 +9069,7 @@
8943
9069
  "immutable": true,
8944
9070
  "locationInModule": {
8945
9071
  "filename": "src/providers/fargate.ts",
8946
- "line": 102
9072
+ "line": 103
8947
9073
  },
8948
9074
  "name": "securityGroups",
8949
9075
  "optional": true,
@@ -8967,7 +9093,7 @@
8967
9093
  "immutable": true,
8968
9094
  "locationInModule": {
8969
9095
  "filename": "src/providers/fargate.ts",
8970
- "line": 174
9096
+ "line": 175
8971
9097
  },
8972
9098
  "name": "spot",
8973
9099
  "optional": true,
@@ -8985,7 +9111,7 @@
8985
9111
  "immutable": true,
8986
9112
  "locationInModule": {
8987
9113
  "filename": "src/providers/fargate.ts",
8988
- "line": 86
9114
+ "line": 87
8989
9115
  },
8990
9116
  "name": "subnetSelection",
8991
9117
  "optional": true,
@@ -9003,7 +9129,7 @@
9003
9129
  "immutable": true,
9004
9130
  "locationInModule": {
9005
9131
  "filename": "src/providers/fargate.ts",
9006
- "line": 79
9132
+ "line": 80
9007
9133
  },
9008
9134
  "name": "vpc",
9009
9135
  "optional": true,
@@ -9025,7 +9151,7 @@
9025
9151
  "kind": "interface",
9026
9152
  "locationInModule": {
9027
9153
  "filename": "src/image-builders/aws-image-builder/builder.ts",
9028
- "line": 64
9154
+ "line": 63
9029
9155
  },
9030
9156
  "name": "FastLaunchOptions",
9031
9157
  "properties": [
@@ -9043,7 +9169,7 @@
9043
9169
  "immutable": true,
9044
9170
  "locationInModule": {
9045
9171
  "filename": "src/image-builders/aws-image-builder/builder.ts",
9046
- "line": 75
9172
+ "line": 74
9047
9173
  },
9048
9174
  "name": "enabled",
9049
9175
  "optional": true,
@@ -9062,7 +9188,7 @@
9062
9188
  "immutable": true,
9063
9189
  "locationInModule": {
9064
9190
  "filename": "src/image-builders/aws-image-builder/builder.ts",
9065
- "line": 84
9191
+ "line": 83
9066
9192
  },
9067
9193
  "name": "maxParallelLaunches",
9068
9194
  "optional": true,
@@ -9080,7 +9206,7 @@
9080
9206
  "immutable": true,
9081
9207
  "locationInModule": {
9082
9208
  "filename": "src/image-builders/aws-image-builder/builder.ts",
9083
- "line": 91
9209
+ "line": 90
9084
9210
  },
9085
9211
  "name": "targetResourceCount",
9086
9212
  "optional": true,
@@ -9106,7 +9232,7 @@
9106
9232
  },
9107
9233
  "locationInModule": {
9108
9234
  "filename": "src/runner.ts",
9109
- "line": 272
9235
+ "line": 290
9110
9236
  },
9111
9237
  "parameters": [
9112
9238
  {
@@ -9136,7 +9262,7 @@
9136
9262
  "kind": "class",
9137
9263
  "locationInModule": {
9138
9264
  "filename": "src/runner.ts",
9139
- "line": 245
9265
+ "line": 263
9140
9266
  },
9141
9267
  "methods": [
9142
9268
  {
@@ -9147,7 +9273,7 @@
9147
9273
  },
9148
9274
  "locationInModule": {
9149
9275
  "filename": "src/runner.ts",
9150
- "line": 793
9276
+ "line": 842
9151
9277
  },
9152
9278
  "name": "createLogsInsightsQueries"
9153
9279
  },
@@ -9159,7 +9285,7 @@
9159
9285
  },
9160
9286
  "locationInModule": {
9161
9287
  "filename": "src/runner.ts",
9162
- "line": 773
9288
+ "line": 822
9163
9289
  },
9164
9290
  "name": "failedImageBuildsTopic",
9165
9291
  "returns": {
@@ -9176,7 +9302,7 @@
9176
9302
  },
9177
9303
  "locationInModule": {
9178
9304
  "filename": "src/runner.ts",
9179
- "line": 755
9305
+ "line": 804
9180
9306
  },
9181
9307
  "name": "metricFailed",
9182
9308
  "parameters": [
@@ -9202,7 +9328,7 @@
9202
9328
  },
9203
9329
  "locationInModule": {
9204
9330
  "filename": "src/runner.ts",
9205
- "line": 700
9331
+ "line": 748
9206
9332
  },
9207
9333
  "name": "metricJobCompleted",
9208
9334
  "parameters": [
@@ -9228,7 +9354,7 @@
9228
9354
  },
9229
9355
  "locationInModule": {
9230
9356
  "filename": "src/runner.ts",
9231
- "line": 746
9357
+ "line": 795
9232
9358
  },
9233
9359
  "name": "metricSucceeded",
9234
9360
  "parameters": [
@@ -9254,7 +9380,7 @@
9254
9380
  },
9255
9381
  "locationInModule": {
9256
9382
  "filename": "src/runner.ts",
9257
- "line": 762
9383
+ "line": 811
9258
9384
  },
9259
9385
  "name": "metricTime",
9260
9386
  "parameters": [
@@ -9284,7 +9410,7 @@
9284
9410
  "immutable": true,
9285
9411
  "locationInModule": {
9286
9412
  "filename": "src/runner.ts",
9287
- "line": 261
9413
+ "line": 279
9288
9414
  },
9289
9415
  "name": "connections",
9290
9416
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -9300,13 +9426,22 @@
9300
9426
  "immutable": true,
9301
9427
  "locationInModule": {
9302
9428
  "filename": "src/runner.ts",
9303
- "line": 249
9429
+ "line": 267
9304
9430
  },
9305
9431
  "name": "providers",
9306
9432
  "type": {
9307
9433
  "collection": {
9308
9434
  "elementtype": {
9309
- "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
9435
+ "union": {
9436
+ "types": [
9437
+ {
9438
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
9439
+ },
9440
+ {
9441
+ "fqn": "@cloudsnorkel/cdk-github-runners.ICompositeProvider"
9442
+ }
9443
+ ]
9444
+ }
9310
9445
  },
9311
9446
  "kind": "array"
9312
9447
  }
@@ -9320,7 +9455,7 @@
9320
9455
  "immutable": true,
9321
9456
  "locationInModule": {
9322
9457
  "filename": "src/runner.ts",
9323
- "line": 254
9458
+ "line": 272
9324
9459
  },
9325
9460
  "name": "secrets",
9326
9461
  "type": {
@@ -9334,7 +9469,7 @@
9334
9469
  "immutable": true,
9335
9470
  "locationInModule": {
9336
9471
  "filename": "src/runner.ts",
9337
- "line": 272
9472
+ "line": 290
9338
9473
  },
9339
9474
  "name": "props",
9340
9475
  "optional": true,
@@ -9452,12 +9587,39 @@
9452
9587
  "type": {
9453
9588
  "collection": {
9454
9589
  "elementtype": {
9455
- "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
9590
+ "union": {
9591
+ "types": [
9592
+ {
9593
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
9594
+ },
9595
+ {
9596
+ "fqn": "@cloudsnorkel/cdk-github-runners.ICompositeProvider"
9597
+ }
9598
+ ]
9599
+ }
9456
9600
  },
9457
9601
  "kind": "array"
9458
9602
  }
9459
9603
  }
9460
9604
  },
9605
+ {
9606
+ "abstract": true,
9607
+ "docs": {
9608
+ "remarks": "* The function receives the webhook payload along with default provider and its labels as {@link ProviderSelectorInput }\n* The function returns a selected provider and its labels as {@link ProviderSelectorResult }\n* You can decline to provision a runner by returning undefined as the provider selector result\n* You can fully customize the labels for the about-to-be-provisioned runner (add, remove, modify, dynamic labels, etc.)\n* Labels don't have to match the labels originally configured for the provider, but see warnings below\n* This function will be called synchronously during webhook processing, so it should be fast and efficient (webhook limit is 30 seconds total)\n\n**WARNING: It is your responsibility to ensure the selected provider's labels match the job's required labels. If you return the wrong labels, the runner will be created but GitHub Actions will not assign the job to it.**\n\n**WARNING: Provider selection is not a guarantee that a specific provider will be assigned for the job. GitHub Actions may assign the job to any runner with matching labels. The provider selector only determines which provider's runner will be *created*, but GitHub Actions may route the job to any available runner with the required labels.**\n\n**For reliable provider assignment based on job characteristics, consider using repo-level runner registration where you can control which runners are available for specific repositories. See {@link SETUP_GITHUB.md } for more details on the different registration levels. This information is also available while using the setup wizard.",
9609
+ "stability": "experimental",
9610
+ "summary": "Optional Lambda function to customize provider selection logic and label assignment."
9611
+ },
9612
+ "immutable": true,
9613
+ "locationInModule": {
9614
+ "filename": "src/runner.ts",
9615
+ "line": 187
9616
+ },
9617
+ "name": "providerSelector",
9618
+ "optional": true,
9619
+ "type": {
9620
+ "fqn": "aws-cdk-lib.aws_lambda.IFunction"
9621
+ }
9622
+ },
9461
9623
  {
9462
9624
  "abstract": true,
9463
9625
  "docs": {
@@ -9634,7 +9796,161 @@
9634
9796
  ],
9635
9797
  "symbolId": "src/runner:GitHubRunnersProps"
9636
9798
  },
9637
- "@cloudsnorkel/cdk-github-runners.IConfigurableRunnerImageBuilder": {
9799
+ "@cloudsnorkel/cdk-github-runners.ICompositeProvider": {
9800
+ "assembly": "@cloudsnorkel/cdk-github-runners",
9801
+ "docs": {
9802
+ "remarks": "Unlike IRunnerProvider, composite providers do not have connections, grant capabilities,\nlog groups, or retryable errors as they delegate to their sub-providers.",
9803
+ "stability": "experimental",
9804
+ "summary": "Interface for composite runner providers that interact with multiple sub-providers."
9805
+ },
9806
+ "fqn": "@cloudsnorkel/cdk-github-runners.ICompositeProvider",
9807
+ "interfaces": [
9808
+ "constructs.IConstruct"
9809
+ ],
9810
+ "kind": "interface",
9811
+ "locationInModule": {
9812
+ "filename": "src/providers/common.ts",
9813
+ "line": 524
9814
+ },
9815
+ "methods": [
9816
+ {
9817
+ "abstract": true,
9818
+ "docs": {
9819
+ "remarks": "Called by GithubRunners and shouldn't be called manually.",
9820
+ "stability": "experimental",
9821
+ "summary": "Generate step function tasks that execute the runner."
9822
+ },
9823
+ "locationInModule": {
9824
+ "filename": "src/providers/common.ts",
9825
+ "line": 547
9826
+ },
9827
+ "name": "getStepFunctionTask",
9828
+ "parameters": [
9829
+ {
9830
+ "docs": {
9831
+ "summary": "specific build parameters."
9832
+ },
9833
+ "name": "parameters",
9834
+ "type": {
9835
+ "fqn": "@cloudsnorkel/cdk-github-runners.RunnerRuntimeParameters"
9836
+ }
9837
+ }
9838
+ ],
9839
+ "returns": {
9840
+ "type": {
9841
+ "fqn": "aws-cdk-lib.aws_stepfunctions.IChainable"
9842
+ }
9843
+ }
9844
+ },
9845
+ {
9846
+ "abstract": true,
9847
+ "docs": {
9848
+ "remarks": "This can be used to add additional policy\nstatements to the state machine role that are not automatically added by the task returned from {@link getStepFunctionTask}.",
9849
+ "stability": "experimental",
9850
+ "summary": "An optional method that modifies the role of the state machine after all the tasks have been generated."
9851
+ },
9852
+ "locationInModule": {
9853
+ "filename": "src/providers/common.ts",
9854
+ "line": 555
9855
+ },
9856
+ "name": "grantStateMachine",
9857
+ "parameters": [
9858
+ {
9859
+ "docs": {
9860
+ "summary": "role for the state machine that executes the task returned from {@link getStepFunctionTask}."
9861
+ },
9862
+ "name": "stateMachineRole",
9863
+ "type": {
9864
+ "fqn": "aws-cdk-lib.aws_iam.IGrantable"
9865
+ }
9866
+ }
9867
+ ]
9868
+ },
9869
+ {
9870
+ "abstract": true,
9871
+ "docs": {
9872
+ "remarks": "Also gives the status function any needed permissions to query the Docker images or AMIs.",
9873
+ "stability": "experimental",
9874
+ "summary": "Return statuses of all sub-providers to be used in the main status function."
9875
+ },
9876
+ "locationInModule": {
9877
+ "filename": "src/providers/common.ts",
9878
+ "line": 562
9879
+ },
9880
+ "name": "status",
9881
+ "parameters": [
9882
+ {
9883
+ "docs": {
9884
+ "summary": "grantable for the status function."
9885
+ },
9886
+ "name": "statusFunctionRole",
9887
+ "type": {
9888
+ "fqn": "aws-cdk-lib.aws_iam.IGrantable"
9889
+ }
9890
+ }
9891
+ ],
9892
+ "returns": {
9893
+ "type": {
9894
+ "collection": {
9895
+ "elementtype": {
9896
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProviderStatus"
9897
+ },
9898
+ "kind": "array"
9899
+ }
9900
+ }
9901
+ }
9902
+ }
9903
+ ],
9904
+ "name": "ICompositeProvider",
9905
+ "properties": [
9906
+ {
9907
+ "abstract": true,
9908
+ "docs": {
9909
+ "remarks": "These labels are used to identify which provider should spawn a new on-demand runner. Every job sends a webhook with the labels it's looking for\nbased on runs-on. We use match the labels from the webhook with the labels specified here. If all the labels specified here are present in the\njob's labels, this provider will be chosen and spawn a new runner.",
9910
+ "stability": "experimental",
9911
+ "summary": "GitHub Actions labels used for this provider."
9912
+ },
9913
+ "immutable": true,
9914
+ "locationInModule": {
9915
+ "filename": "src/providers/common.ts",
9916
+ "line": 532
9917
+ },
9918
+ "name": "labels",
9919
+ "type": {
9920
+ "collection": {
9921
+ "elementtype": {
9922
+ "primitive": "string"
9923
+ },
9924
+ "kind": "array"
9925
+ }
9926
+ }
9927
+ },
9928
+ {
9929
+ "abstract": true,
9930
+ "docs": {
9931
+ "remarks": "This is used to extract providers for metric filters and other operations.",
9932
+ "stability": "experimental",
9933
+ "summary": "All sub-providers contained in this composite provider."
9934
+ },
9935
+ "immutable": true,
9936
+ "locationInModule": {
9937
+ "filename": "src/providers/common.ts",
9938
+ "line": 538
9939
+ },
9940
+ "name": "providers",
9941
+ "type": {
9942
+ "collection": {
9943
+ "elementtype": {
9944
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
9945
+ },
9946
+ "kind": "array"
9947
+ }
9948
+ }
9949
+ }
9950
+ ],
9951
+ "symbolId": "src/providers/common:ICompositeProvider"
9952
+ },
9953
+ "@cloudsnorkel/cdk-github-runners.IConfigurableRunnerImageBuilder": {
9638
9954
  "assembly": "@cloudsnorkel/cdk-github-runners",
9639
9955
  "docs": {
9640
9956
  "remarks": "The image can be configured by adding or removing components. The image builder can be configured by adding grants or allowing connections.\n\nAn image can be a Docker image or AMI.",
@@ -9715,7 +10031,7 @@
9715
10031
  "kind": "interface",
9716
10032
  "locationInModule": {
9717
10033
  "filename": "src/providers/common.ts",
9718
- "line": 400
10034
+ "line": 405
9719
10035
  },
9720
10036
  "name": "IRunnerAmiStatus",
9721
10037
  "properties": [
@@ -9728,7 +10044,7 @@
9728
10044
  "immutable": true,
9729
10045
  "locationInModule": {
9730
10046
  "filename": "src/providers/common.ts",
9731
- "line": 404
10047
+ "line": 409
9732
10048
  },
9733
10049
  "name": "launchTemplate",
9734
10050
  "type": {
@@ -9744,7 +10060,7 @@
9744
10060
  "immutable": true,
9745
10061
  "locationInModule": {
9746
10062
  "filename": "src/providers/common.ts",
9747
- "line": 409
10063
+ "line": 414
9748
10064
  },
9749
10065
  "name": "amiBuilderLogGroup",
9750
10066
  "optional": true,
@@ -9819,7 +10135,7 @@
9819
10135
  "kind": "interface",
9820
10136
  "locationInModule": {
9821
10137
  "filename": "src/providers/common.ts",
9822
- "line": 380
10138
+ "line": 385
9823
10139
  },
9824
10140
  "name": "IRunnerImageStatus",
9825
10141
  "properties": [
@@ -9832,7 +10148,7 @@
9832
10148
  "immutable": true,
9833
10149
  "locationInModule": {
9834
10150
  "filename": "src/providers/common.ts",
9835
- "line": 384
10151
+ "line": 389
9836
10152
  },
9837
10153
  "name": "imageRepository",
9838
10154
  "type": {
@@ -9848,7 +10164,7 @@
9848
10164
  "immutable": true,
9849
10165
  "locationInModule": {
9850
10166
  "filename": "src/providers/common.ts",
9851
- "line": 389
10167
+ "line": 394
9852
10168
  },
9853
10169
  "name": "imageTag",
9854
10170
  "type": {
@@ -9864,7 +10180,7 @@
9864
10180
  "immutable": true,
9865
10181
  "locationInModule": {
9866
10182
  "filename": "src/providers/common.ts",
9867
- "line": 394
10183
+ "line": 399
9868
10184
  },
9869
10185
  "name": "imageBuilderLogGroup",
9870
10186
  "optional": true,
@@ -9891,7 +10207,7 @@
9891
10207
  "kind": "interface",
9892
10208
  "locationInModule": {
9893
10209
  "filename": "src/providers/common.ts",
9894
- "line": 460
10210
+ "line": 470
9895
10211
  },
9896
10212
  "methods": [
9897
10213
  {
@@ -9903,7 +10219,7 @@
9903
10219
  },
9904
10220
  "locationInModule": {
9905
10221
  "filename": "src/providers/common.ts",
9906
- "line": 491
10222
+ "line": 501
9907
10223
  },
9908
10224
  "name": "getStepFunctionTask",
9909
10225
  "parameters": [
@@ -9932,7 +10248,7 @@
9932
10248
  },
9933
10249
  "locationInModule": {
9934
10250
  "filename": "src/providers/common.ts",
9935
- "line": 499
10251
+ "line": 509
9936
10252
  },
9937
10253
  "name": "grantStateMachine",
9938
10254
  "parameters": [
@@ -9956,7 +10272,7 @@
9956
10272
  },
9957
10273
  "locationInModule": {
9958
10274
  "filename": "src/providers/common.ts",
9959
- "line": 506
10275
+ "line": 516
9960
10276
  },
9961
10277
  "name": "status",
9962
10278
  "parameters": [
@@ -9989,7 +10305,7 @@
9989
10305
  "immutable": true,
9990
10306
  "locationInModule": {
9991
10307
  "filename": "src/providers/common.ts",
9992
- "line": 468
10308
+ "line": 478
9993
10309
  },
9994
10310
  "name": "labels",
9995
10311
  "type": {
@@ -10011,7 +10327,7 @@
10011
10327
  "immutable": true,
10012
10328
  "locationInModule": {
10013
10329
  "filename": "src/providers/common.ts",
10014
- "line": 475
10330
+ "line": 485
10015
10331
  },
10016
10332
  "name": "logGroup",
10017
10333
  "type": {
@@ -10028,7 +10344,7 @@
10028
10344
  "immutable": true,
10029
10345
  "locationInModule": {
10030
10346
  "filename": "src/providers/common.ts",
10031
- "line": 482
10347
+ "line": 492
10032
10348
  },
10033
10349
  "name": "retryableErrors",
10034
10350
  "type": {
@@ -10053,7 +10369,7 @@
10053
10369
  "kind": "interface",
10054
10370
  "locationInModule": {
10055
10371
  "filename": "src/providers/common.ts",
10056
- "line": 415
10372
+ "line": 420
10057
10373
  },
10058
10374
  "name": "IRunnerProviderStatus",
10059
10375
  "properties": [
@@ -10066,7 +10382,7 @@
10066
10382
  "immutable": true,
10067
10383
  "locationInModule": {
10068
10384
  "filename": "src/providers/common.ts",
10069
- "line": 424
10385
+ "line": 429
10070
10386
  },
10071
10387
  "name": "labels",
10072
10388
  "type": {
@@ -10087,7 +10403,7 @@
10087
10403
  "immutable": true,
10088
10404
  "locationInModule": {
10089
10405
  "filename": "src/providers/common.ts",
10090
- "line": 419
10406
+ "line": 424
10091
10407
  },
10092
10408
  "name": "type",
10093
10409
  "type": {
@@ -10103,7 +10419,7 @@
10103
10419
  "immutable": true,
10104
10420
  "locationInModule": {
10105
10421
  "filename": "src/providers/common.ts",
10106
- "line": 449
10422
+ "line": 459
10107
10423
  },
10108
10424
  "name": "ami",
10109
10425
  "optional": true,
@@ -10111,6 +10427,23 @@
10111
10427
  "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerAmiStatus"
10112
10428
  }
10113
10429
  },
10430
+ {
10431
+ "abstract": true,
10432
+ "docs": {
10433
+ "stability": "experimental",
10434
+ "summary": "CDK construct node path for this provider."
10435
+ },
10436
+ "immutable": true,
10437
+ "locationInModule": {
10438
+ "filename": "src/providers/common.ts",
10439
+ "line": 434
10440
+ },
10441
+ "name": "constructPath",
10442
+ "optional": true,
10443
+ "type": {
10444
+ "primitive": "string"
10445
+ }
10446
+ },
10114
10447
  {
10115
10448
  "abstract": true,
10116
10449
  "docs": {
@@ -10120,7 +10453,7 @@
10120
10453
  "immutable": true,
10121
10454
  "locationInModule": {
10122
10455
  "filename": "src/providers/common.ts",
10123
- "line": 444
10456
+ "line": 454
10124
10457
  },
10125
10458
  "name": "image",
10126
10459
  "optional": true,
@@ -10137,7 +10470,7 @@
10137
10470
  "immutable": true,
10138
10471
  "locationInModule": {
10139
10472
  "filename": "src/providers/common.ts",
10140
- "line": 454
10473
+ "line": 464
10141
10474
  },
10142
10475
  "name": "logGroup",
10143
10476
  "optional": true,
@@ -10154,7 +10487,7 @@
10154
10487
  "immutable": true,
10155
10488
  "locationInModule": {
10156
10489
  "filename": "src/providers/common.ts",
10157
- "line": 439
10490
+ "line": 449
10158
10491
  },
10159
10492
  "name": "roleArn",
10160
10493
  "optional": true,
@@ -10171,7 +10504,7 @@
10171
10504
  "immutable": true,
10172
10505
  "locationInModule": {
10173
10506
  "filename": "src/providers/common.ts",
10174
- "line": 434
10507
+ "line": 444
10175
10508
  },
10176
10509
  "name": "securityGroups",
10177
10510
  "optional": true,
@@ -10193,7 +10526,7 @@
10193
10526
  "immutable": true,
10194
10527
  "locationInModule": {
10195
10528
  "filename": "src/providers/common.ts",
10196
- "line": 429
10529
+ "line": 439
10197
10530
  },
10198
10531
  "name": "vpcArn",
10199
10532
  "optional": true,
@@ -10215,7 +10548,7 @@
10215
10548
  "kind": "interface",
10216
10549
  "locationInModule": {
10217
10550
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10218
- "line": 97
10551
+ "line": 96
10219
10552
  },
10220
10553
  "name": "ImageBuilderAsset",
10221
10554
  "properties": [
@@ -10228,7 +10561,7 @@
10228
10561
  "immutable": true,
10229
10562
  "locationInModule": {
10230
10563
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10231
- "line": 106
10564
+ "line": 105
10232
10565
  },
10233
10566
  "name": "asset",
10234
10567
  "type": {
@@ -10244,7 +10577,7 @@
10244
10577
  "immutable": true,
10245
10578
  "locationInModule": {
10246
10579
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10247
- "line": 101
10580
+ "line": 100
10248
10581
  },
10249
10582
  "name": "path",
10250
10583
  "type": {
@@ -10270,7 +10603,7 @@
10270
10603
  },
10271
10604
  "locationInModule": {
10272
10605
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10273
- "line": 180
10606
+ "line": 179
10274
10607
  },
10275
10608
  "parameters": [
10276
10609
  {
@@ -10296,45 +10629,9 @@
10296
10629
  "kind": "class",
10297
10630
  "locationInModule": {
10298
10631
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10299
- "line": 167
10632
+ "line": 166
10300
10633
  },
10301
10634
  "methods": [
10302
- {
10303
- "docs": {
10304
- "stability": "deprecated"
10305
- },
10306
- "locationInModule": {
10307
- "filename": "src/image-builders/aws-image-builder/common.ts",
10308
- "line": 15
10309
- },
10310
- "name": "generateVersion",
10311
- "parameters": [
10312
- {
10313
- "name": "type",
10314
- "type": {
10315
- "primitive": "string"
10316
- }
10317
- },
10318
- {
10319
- "name": "name",
10320
- "type": {
10321
- "primitive": "string"
10322
- }
10323
- },
10324
- {
10325
- "name": "data",
10326
- "type": {
10327
- "primitive": "any"
10328
- }
10329
- }
10330
- ],
10331
- "protected": true,
10332
- "returns": {
10333
- "type": {
10334
- "primitive": "string"
10335
- }
10336
- }
10337
- },
10338
10635
  {
10339
10636
  "docs": {
10340
10637
  "stability": "deprecated",
@@ -10342,7 +10639,7 @@
10342
10639
  },
10343
10640
  "locationInModule": {
10344
10641
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10345
- "line": 282
10642
+ "line": 277
10346
10643
  },
10347
10644
  "name": "grantAssetsRead",
10348
10645
  "parameters": [
@@ -10360,7 +10657,7 @@
10360
10657
  },
10361
10658
  "locationInModule": {
10362
10659
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10363
- "line": 288
10660
+ "line": 283
10364
10661
  },
10365
10662
  "name": "prefixCommandsWithErrorHandling",
10366
10663
  "parameters": [
@@ -10404,7 +10701,7 @@
10404
10701
  "immutable": true,
10405
10702
  "locationInModule": {
10406
10703
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10407
- "line": 171
10704
+ "line": 170
10408
10705
  },
10409
10706
  "name": "arn",
10410
10707
  "type": {
@@ -10419,7 +10716,7 @@
10419
10716
  "immutable": true,
10420
10717
  "locationInModule": {
10421
10718
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10422
- "line": 176
10719
+ "line": 175
10423
10720
  },
10424
10721
  "name": "platform",
10425
10722
  "type": {
@@ -10440,7 +10737,7 @@
10440
10737
  "kind": "interface",
10441
10738
  "locationInModule": {
10442
10739
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10443
- "line": 112
10740
+ "line": 111
10444
10741
  },
10445
10742
  "name": "ImageBuilderComponentProperties",
10446
10743
  "properties": [
@@ -10454,7 +10751,7 @@
10454
10751
  "immutable": true,
10455
10752
  "locationInModule": {
10456
10753
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10457
- "line": 133
10754
+ "line": 132
10458
10755
  },
10459
10756
  "name": "commands",
10460
10757
  "type": {
@@ -10475,7 +10772,7 @@
10475
10772
  "immutable": true,
10476
10773
  "locationInModule": {
10477
10774
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10478
- "line": 126
10775
+ "line": 125
10479
10776
  },
10480
10777
  "name": "description",
10481
10778
  "type": {
@@ -10491,7 +10788,7 @@
10491
10788
  "immutable": true,
10492
10789
  "locationInModule": {
10493
10790
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10494
- "line": 121
10791
+ "line": 120
10495
10792
  },
10496
10793
  "name": "displayName",
10497
10794
  "type": {
@@ -10508,7 +10805,7 @@
10508
10805
  "immutable": true,
10509
10806
  "locationInModule": {
10510
10807
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10511
- "line": 116
10808
+ "line": 115
10512
10809
  },
10513
10810
  "name": "platform",
10514
10811
  "type": {
@@ -10524,7 +10821,7 @@
10524
10821
  "immutable": true,
10525
10822
  "locationInModule": {
10526
10823
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10527
- "line": 138
10824
+ "line": 137
10528
10825
  },
10529
10826
  "name": "assets",
10530
10827
  "optional": true,
@@ -10547,7 +10844,7 @@
10547
10844
  "immutable": true,
10548
10845
  "locationInModule": {
10549
10846
  "filename": "src/image-builders/aws-image-builder/builder.ts",
10550
- "line": 145
10847
+ "line": 144
10551
10848
  },
10552
10849
  "name": "reboot",
10553
10850
  "optional": true,
@@ -10720,7 +11017,7 @@
10720
11017
  },
10721
11018
  "locationInModule": {
10722
11019
  "filename": "src/providers/lambda.ts",
10723
- "line": 238
11020
+ "line": 239
10724
11021
  },
10725
11022
  "parameters": [
10726
11023
  {
@@ -10747,7 +11044,7 @@
10747
11044
  "kind": "class",
10748
11045
  "locationInModule": {
10749
11046
  "filename": "src/providers/lambda.ts",
10750
- "line": 478
11047
+ "line": 480
10751
11048
  },
10752
11049
  "name": "LambdaRunner",
10753
11050
  "symbolId": "src/providers/lambda:LambdaRunner"
@@ -10767,7 +11064,7 @@
10767
11064
  },
10768
11065
  "locationInModule": {
10769
11066
  "filename": "src/providers/lambda.ts",
10770
- "line": 238
11067
+ "line": 239
10771
11068
  },
10772
11069
  "parameters": [
10773
11070
  {
@@ -10797,7 +11094,7 @@
10797
11094
  "kind": "class",
10798
11095
  "locationInModule": {
10799
11096
  "filename": "src/providers/lambda.ts",
10800
- "line": 140
11097
+ "line": 141
10801
11098
  },
10802
11099
  "methods": [
10803
11100
  {
@@ -10808,7 +11105,7 @@
10808
11105
  },
10809
11106
  "locationInModule": {
10810
11107
  "filename": "src/providers/lambda.ts",
10811
- "line": 181
11108
+ "line": 182
10812
11109
  },
10813
11110
  "name": "imageBuilder",
10814
11111
  "parameters": [
@@ -10847,7 +11144,7 @@
10847
11144
  },
10848
11145
  "locationInModule": {
10849
11146
  "filename": "src/providers/lambda.ts",
10850
- "line": 332
11147
+ "line": 333
10851
11148
  },
10852
11149
  "name": "getStepFunctionTask",
10853
11150
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -10876,7 +11173,7 @@
10876
11173
  },
10877
11174
  "locationInModule": {
10878
11175
  "filename": "src/providers/lambda.ts",
10879
- "line": 395
11176
+ "line": 396
10880
11177
  },
10881
11178
  "name": "grantStateMachine",
10882
11179
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -10895,7 +11192,7 @@
10895
11192
  },
10896
11193
  "locationInModule": {
10897
11194
  "filename": "src/providers/common.ts",
10898
- "line": 556
11195
+ "line": 612
10899
11196
  },
10900
11197
  "name": "labelsFromProperties",
10901
11198
  "parameters": [
@@ -10945,7 +11242,7 @@
10945
11242
  },
10946
11243
  "locationInModule": {
10947
11244
  "filename": "src/providers/lambda.ts",
10948
- "line": 398
11245
+ "line": 399
10949
11246
  },
10950
11247
  "name": "status",
10951
11248
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -10977,7 +11274,7 @@
10977
11274
  "immutable": true,
10978
11275
  "locationInModule": {
10979
11276
  "filename": "src/providers/lambda.ts",
10980
- "line": 161
11277
+ "line": 162
10981
11278
  },
10982
11279
  "name": "LINUX_ARM64_DOCKERFILE_PATH",
10983
11280
  "static": true,
@@ -10996,7 +11293,7 @@
10996
11293
  "immutable": true,
10997
11294
  "locationInModule": {
10998
11295
  "filename": "src/providers/lambda.ts",
10999
- "line": 150
11296
+ "line": 151
11000
11297
  },
11001
11298
  "name": "LINUX_X64_DOCKERFILE_PATH",
11002
11299
  "static": true,
@@ -11012,7 +11309,7 @@
11012
11309
  "immutable": true,
11013
11310
  "locationInModule": {
11014
11311
  "filename": "src/providers/lambda.ts",
11015
- "line": 321
11312
+ "line": 322
11016
11313
  },
11017
11314
  "name": "connections",
11018
11315
  "overrides": "aws-cdk-lib.aws_ec2.IConnectable",
@@ -11028,7 +11325,7 @@
11028
11325
  "immutable": true,
11029
11326
  "locationInModule": {
11030
11327
  "filename": "src/providers/lambda.ts",
11031
- "line": 201
11328
+ "line": 202
11032
11329
  },
11033
11330
  "name": "function",
11034
11331
  "type": {
@@ -11043,7 +11340,7 @@
11043
11340
  "immutable": true,
11044
11341
  "locationInModule": {
11045
11342
  "filename": "src/providers/lambda.ts",
11046
- "line": 211
11343
+ "line": 212
11047
11344
  },
11048
11345
  "name": "grantPrincipal",
11049
11346
  "overrides": "aws-cdk-lib.aws_iam.IGrantable",
@@ -11060,7 +11357,7 @@
11060
11357
  "immutable": true,
11061
11358
  "locationInModule": {
11062
11359
  "filename": "src/providers/lambda.ts",
11063
- "line": 216
11360
+ "line": 217
11064
11361
  },
11065
11362
  "name": "image",
11066
11363
  "type": {
@@ -11075,7 +11372,7 @@
11075
11372
  "immutable": true,
11076
11373
  "locationInModule": {
11077
11374
  "filename": "src/providers/lambda.ts",
11078
- "line": 206
11375
+ "line": 207
11079
11376
  },
11080
11377
  "name": "labels",
11081
11378
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -11097,7 +11394,7 @@
11097
11394
  "immutable": true,
11098
11395
  "locationInModule": {
11099
11396
  "filename": "src/providers/lambda.ts",
11100
- "line": 223
11397
+ "line": 224
11101
11398
  },
11102
11399
  "name": "logGroup",
11103
11400
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -11113,7 +11410,7 @@
11113
11410
  "immutable": true,
11114
11411
  "locationInModule": {
11115
11412
  "filename": "src/providers/lambda.ts",
11116
- "line": 225
11413
+ "line": 226
11117
11414
  },
11118
11415
  "name": "retryableErrors",
11119
11416
  "overrides": "@cloudsnorkel/cdk-github-runners.IRunnerProvider",
@@ -11142,7 +11439,7 @@
11142
11439
  "kind": "interface",
11143
11440
  "locationInModule": {
11144
11441
  "filename": "src/providers/lambda.ts",
11145
- "line": 31
11442
+ "line": 32
11146
11443
  },
11147
11444
  "name": "LambdaRunnerProviderProps",
11148
11445
  "properties": [
@@ -11156,7 +11453,7 @@
11156
11453
  "immutable": true,
11157
11454
  "locationInModule": {
11158
11455
  "filename": "src/providers/lambda.ts",
11159
- "line": 91
11456
+ "line": 92
11160
11457
  },
11161
11458
  "name": "ephemeralStorageSize",
11162
11459
  "optional": true,
@@ -11175,7 +11472,7 @@
11175
11472
  "immutable": true,
11176
11473
  "locationInModule": {
11177
11474
  "filename": "src/providers/lambda.ts",
11178
- "line": 74
11475
+ "line": 75
11179
11476
  },
11180
11477
  "name": "group",
11181
11478
  "optional": true,
@@ -11194,7 +11491,7 @@
11194
11491
  "immutable": true,
11195
11492
  "locationInModule": {
11196
11493
  "filename": "src/providers/lambda.ts",
11197
- "line": 41
11494
+ "line": 42
11198
11495
  },
11199
11496
  "name": "imageBuilder",
11200
11497
  "optional": true,
@@ -11213,7 +11510,7 @@
11213
11510
  "immutable": true,
11214
11511
  "locationInModule": {
11215
11512
  "filename": "src/providers/lambda.ts",
11216
- "line": 49
11513
+ "line": 50
11217
11514
  },
11218
11515
  "name": "label",
11219
11516
  "optional": true,
@@ -11232,7 +11529,7 @@
11232
11529
  "immutable": true,
11233
11530
  "locationInModule": {
11234
11531
  "filename": "src/providers/lambda.ts",
11235
- "line": 60
11532
+ "line": 61
11236
11533
  },
11237
11534
  "name": "labels",
11238
11535
  "optional": true,
@@ -11256,7 +11553,7 @@
11256
11553
  "immutable": true,
11257
11554
  "locationInModule": {
11258
11555
  "filename": "src/providers/lambda.ts",
11259
- "line": 84
11556
+ "line": 85
11260
11557
  },
11261
11558
  "name": "memorySize",
11262
11559
  "optional": true,
@@ -11275,7 +11572,7 @@
11275
11572
  "immutable": true,
11276
11573
  "locationInModule": {
11277
11574
  "filename": "src/providers/lambda.ts",
11278
- "line": 116
11575
+ "line": 117
11279
11576
  },
11280
11577
  "name": "securityGroup",
11281
11578
  "optional": true,
@@ -11293,7 +11590,7 @@
11293
11590
  "immutable": true,
11294
11591
  "locationInModule": {
11295
11592
  "filename": "src/providers/lambda.ts",
11296
- "line": 123
11593
+ "line": 124
11297
11594
  },
11298
11595
  "name": "securityGroups",
11299
11596
  "optional": true,
@@ -11316,7 +11613,7 @@
11316
11613
  "immutable": true,
11317
11614
  "locationInModule": {
11318
11615
  "filename": "src/providers/lambda.ts",
11319
- "line": 130
11616
+ "line": 131
11320
11617
  },
11321
11618
  "name": "subnetSelection",
11322
11619
  "optional": true,
@@ -11335,7 +11632,7 @@
11335
11632
  "immutable": true,
11336
11633
  "locationInModule": {
11337
11634
  "filename": "src/providers/lambda.ts",
11338
- "line": 100
11635
+ "line": 101
11339
11636
  },
11340
11637
  "name": "timeout",
11341
11638
  "optional": true,
@@ -11353,7 +11650,7 @@
11353
11650
  "immutable": true,
11354
11651
  "locationInModule": {
11355
11652
  "filename": "src/providers/lambda.ts",
11356
- "line": 107
11653
+ "line": 108
11357
11654
  },
11358
11655
  "name": "vpc",
11359
11656
  "optional": true,
@@ -11693,7 +11990,7 @@
11693
11990
  "kind": "interface",
11694
11991
  "locationInModule": {
11695
11992
  "filename": "src/runner.ts",
11696
- "line": 175
11993
+ "line": 193
11697
11994
  },
11698
11995
  "name": "LogOptions",
11699
11996
  "properties": [
@@ -11707,7 +12004,7 @@
11707
12004
  "immutable": true,
11708
12005
  "locationInModule": {
11709
12006
  "filename": "src/runner.ts",
11710
- "line": 186
12007
+ "line": 204
11711
12008
  },
11712
12009
  "name": "includeExecutionData",
11713
12010
  "optional": true,
@@ -11725,7 +12022,7 @@
11725
12022
  "immutable": true,
11726
12023
  "locationInModule": {
11727
12024
  "filename": "src/runner.ts",
11728
- "line": 193
12025
+ "line": 211
11729
12026
  },
11730
12027
  "name": "level",
11731
12028
  "optional": true,
@@ -11742,7 +12039,7 @@
11742
12039
  "immutable": true,
11743
12040
  "locationInModule": {
11744
12041
  "filename": "src/runner.ts",
11745
- "line": 179
12042
+ "line": 197
11746
12043
  },
11747
12044
  "name": "logGroupName",
11748
12045
  "optional": true,
@@ -11761,7 +12058,7 @@
11761
12058
  "immutable": true,
11762
12059
  "locationInModule": {
11763
12060
  "filename": "src/runner.ts",
11764
- "line": 202
12061
+ "line": 220
11765
12062
  },
11766
12063
  "name": "logRetention",
11767
12064
  "optional": true,
@@ -12077,6 +12374,168 @@
12077
12374
  ],
12078
12375
  "symbolId": "src/providers/common:ProviderRetryOptions"
12079
12376
  },
12377
+ "@cloudsnorkel/cdk-github-runners.ProviderSelectorInput": {
12378
+ "assembly": "@cloudsnorkel/cdk-github-runners",
12379
+ "datatype": true,
12380
+ "docs": {
12381
+ "stability": "experimental",
12382
+ "summary": "Input to the provider selector Lambda function."
12383
+ },
12384
+ "fqn": "@cloudsnorkel/cdk-github-runners.ProviderSelectorInput",
12385
+ "kind": "interface",
12386
+ "locationInModule": {
12387
+ "filename": "src/webhook.ts",
12388
+ "line": 12
12389
+ },
12390
+ "name": "ProviderSelectorInput",
12391
+ "properties": [
12392
+ {
12393
+ "abstract": true,
12394
+ "docs": {
12395
+ "remarks": "* Original labels requested by the workflow job can be found at `payload.workflow_job.labels`.\n* Repository path (e.g. CloudSnorkel/cdk-github-runners) is at `payload.repository.full_name`.\n* Commit hash is at `payload.workflow_job.head_sha`.",
12396
+ "see": "https://docs.github.com/en/webhooks/webhook-events-and-payloads?actionType=queued#workflow_job",
12397
+ "stability": "experimental",
12398
+ "summary": "Full GitHub webhook payload (workflow_job event structure with action=\"queued\")."
12399
+ },
12400
+ "immutable": true,
12401
+ "locationInModule": {
12402
+ "filename": "src/webhook.ts",
12403
+ "line": 22
12404
+ },
12405
+ "name": "payload",
12406
+ "type": {
12407
+ "primitive": "any"
12408
+ }
12409
+ },
12410
+ {
12411
+ "abstract": true,
12412
+ "docs": {
12413
+ "remarks": "Example: { \"MyStack/Small\": [\"linux\", \"small\"], \"MyStack/Large\": [\"linux\", \"large\"] }",
12414
+ "stability": "experimental",
12415
+ "summary": "Map of available provider node paths to their configured labels."
12416
+ },
12417
+ "immutable": true,
12418
+ "locationInModule": {
12419
+ "filename": "src/webhook.ts",
12420
+ "line": 28
12421
+ },
12422
+ "name": "providers",
12423
+ "type": {
12424
+ "collection": {
12425
+ "elementtype": {
12426
+ "collection": {
12427
+ "elementtype": {
12428
+ "primitive": "string"
12429
+ },
12430
+ "kind": "array"
12431
+ }
12432
+ },
12433
+ "kind": "map"
12434
+ }
12435
+ }
12436
+ },
12437
+ {
12438
+ "abstract": true,
12439
+ "docs": {
12440
+ "remarks": "May be undefined if no provider matched by default.",
12441
+ "stability": "experimental",
12442
+ "summary": "Labels that would have been used by default (the selected provider's labels)."
12443
+ },
12444
+ "immutable": true,
12445
+ "locationInModule": {
12446
+ "filename": "src/webhook.ts",
12447
+ "line": 41
12448
+ },
12449
+ "name": "defaultLabels",
12450
+ "optional": true,
12451
+ "type": {
12452
+ "collection": {
12453
+ "elementtype": {
12454
+ "primitive": "string"
12455
+ },
12456
+ "kind": "array"
12457
+ }
12458
+ }
12459
+ },
12460
+ {
12461
+ "abstract": true,
12462
+ "docs": {
12463
+ "remarks": "Use this to easily return the default selection: `{ provider: input.defaultProvider, labels: input.defaultLabels }`\nMay be undefined if no provider matched by default.",
12464
+ "stability": "experimental",
12465
+ "summary": "Provider node path that would have been selected by default label matching."
12466
+ },
12467
+ "immutable": true,
12468
+ "locationInModule": {
12469
+ "filename": "src/webhook.ts",
12470
+ "line": 35
12471
+ },
12472
+ "name": "defaultProvider",
12473
+ "optional": true,
12474
+ "type": {
12475
+ "primitive": "string"
12476
+ }
12477
+ }
12478
+ ],
12479
+ "symbolId": "src/webhook:ProviderSelectorInput"
12480
+ },
12481
+ "@cloudsnorkel/cdk-github-runners.ProviderSelectorResult": {
12482
+ "assembly": "@cloudsnorkel/cdk-github-runners",
12483
+ "datatype": true,
12484
+ "docs": {
12485
+ "stability": "experimental",
12486
+ "summary": "Result from the provider selector Lambda function."
12487
+ },
12488
+ "fqn": "@cloudsnorkel/cdk-github-runners.ProviderSelectorResult",
12489
+ "kind": "interface",
12490
+ "locationInModule": {
12491
+ "filename": "src/webhook.ts",
12492
+ "line": 47
12493
+ },
12494
+ "name": "ProviderSelectorResult",
12495
+ "properties": [
12496
+ {
12497
+ "abstract": true,
12498
+ "docs": {
12499
+ "remarks": "Must be returned when a provider is selected.\nCan be used to add, remove, or modify labels.",
12500
+ "stability": "experimental",
12501
+ "summary": "Labels to use when registering the runner."
12502
+ },
12503
+ "immutable": true,
12504
+ "locationInModule": {
12505
+ "filename": "src/webhook.ts",
12506
+ "line": 60
12507
+ },
12508
+ "name": "labels",
12509
+ "optional": true,
12510
+ "type": {
12511
+ "collection": {
12512
+ "elementtype": {
12513
+ "primitive": "string"
12514
+ },
12515
+ "kind": "array"
12516
+ }
12517
+ }
12518
+ },
12519
+ {
12520
+ "abstract": true,
12521
+ "docs": {
12522
+ "stability": "experimental",
12523
+ "summary": "Node path of the provider to use (e.g., \"MyStack/MyProvider\"). Must match one of the configured provider node paths from the input. If not provided, the job will be skipped (no runner created)."
12524
+ },
12525
+ "immutable": true,
12526
+ "locationInModule": {
12527
+ "filename": "src/webhook.ts",
12528
+ "line": 53
12529
+ },
12530
+ "name": "provider",
12531
+ "optional": true,
12532
+ "type": {
12533
+ "primitive": "string"
12534
+ }
12535
+ }
12536
+ ],
12537
+ "symbolId": "src/webhook:ProviderSelectorResult"
12538
+ },
12080
12539
  "@cloudsnorkel/cdk-github-runners.RunnerAmi": {
12081
12540
  "assembly": "@cloudsnorkel/cdk-github-runners",
12082
12541
  "datatype": true,
@@ -13617,6 +14076,22 @@
13617
14076
  "primitive": "string"
13618
14077
  }
13619
14078
  },
14079
+ {
14080
+ "abstract": true,
14081
+ "docs": {
14082
+ "stability": "experimental",
14083
+ "summary": "Path to comma-separated labels string to use for runner."
14084
+ },
14085
+ "immutable": true,
14086
+ "locationInModule": {
14087
+ "filename": "src/providers/common.ts",
14088
+ "line": 378
14089
+ },
14090
+ "name": "labelsPath",
14091
+ "type": {
14092
+ "primitive": "string"
14093
+ }
14094
+ },
13620
14095
  {
13621
14096
  "abstract": true,
13622
14097
  "docs": {
@@ -14082,7 +14557,7 @@
14082
14557
  "kind": "interface",
14083
14558
  "locationInModule": {
14084
14559
  "filename": "src/providers/common.ts",
14085
- "line": 512
14560
+ "line": 568
14086
14561
  },
14087
14562
  "name": "StorageOptions",
14088
14563
  "properties": [
@@ -14098,7 +14573,7 @@
14098
14573
  "immutable": true,
14099
14574
  "locationInModule": {
14100
14575
  "filename": "src/providers/common.ts",
14101
- "line": 533
14576
+ "line": 589
14102
14577
  },
14103
14578
  "name": "iops",
14104
14579
  "optional": true,
@@ -14117,7 +14592,7 @@
14117
14592
  "immutable": true,
14118
14593
  "locationInModule": {
14119
14594
  "filename": "src/providers/common.ts",
14120
- "line": 541
14595
+ "line": 597
14121
14596
  },
14122
14597
  "name": "throughput",
14123
14598
  "optional": true,
@@ -14136,7 +14611,7 @@
14136
14611
  "immutable": true,
14137
14612
  "locationInModule": {
14138
14613
  "filename": "src/providers/common.ts",
14139
- "line": 519
14614
+ "line": 575
14140
14615
  },
14141
14616
  "name": "volumeType",
14142
14617
  "optional": true,
@@ -14147,6 +14622,57 @@
14147
14622
  ],
14148
14623
  "symbolId": "src/providers/common:StorageOptions"
14149
14624
  },
14625
+ "@cloudsnorkel/cdk-github-runners.WeightedRunnerProvider": {
14626
+ "assembly": "@cloudsnorkel/cdk-github-runners",
14627
+ "datatype": true,
14628
+ "docs": {
14629
+ "stability": "experimental",
14630
+ "summary": "Configuration for weighted distribution of runners."
14631
+ },
14632
+ "fqn": "@cloudsnorkel/cdk-github-runners.WeightedRunnerProvider",
14633
+ "kind": "interface",
14634
+ "locationInModule": {
14635
+ "filename": "src/providers/composite.ts",
14636
+ "line": 8
14637
+ },
14638
+ "name": "WeightedRunnerProvider",
14639
+ "properties": [
14640
+ {
14641
+ "abstract": true,
14642
+ "docs": {
14643
+ "stability": "experimental",
14644
+ "summary": "The runner provider to use."
14645
+ },
14646
+ "immutable": true,
14647
+ "locationInModule": {
14648
+ "filename": "src/providers/composite.ts",
14649
+ "line": 12
14650
+ },
14651
+ "name": "provider",
14652
+ "type": {
14653
+ "fqn": "@cloudsnorkel/cdk-github-runners.IRunnerProvider"
14654
+ }
14655
+ },
14656
+ {
14657
+ "abstract": true,
14658
+ "docs": {
14659
+ "remarks": "Higher weights mean higher probability of selection.\nMust be a positive number.",
14660
+ "stability": "experimental",
14661
+ "summary": "Weight for this provider."
14662
+ },
14663
+ "immutable": true,
14664
+ "locationInModule": {
14665
+ "filename": "src/providers/composite.ts",
14666
+ "line": 18
14667
+ },
14668
+ "name": "weight",
14669
+ "type": {
14670
+ "primitive": "number"
14671
+ }
14672
+ }
14673
+ ],
14674
+ "symbolId": "src/providers/composite:WeightedRunnerProvider"
14675
+ },
14150
14676
  "@cloudsnorkel/cdk-github-runners.WindowsComponents": {
14151
14677
  "assembly": "@cloudsnorkel/cdk-github-runners",
14152
14678
  "docs": {
@@ -14394,6 +14920,6 @@
14394
14920
  "symbolId": "src/image-builders/aws-image-builder/deprecated/windows-components:WindowsComponents"
14395
14921
  }
14396
14922
  },
14397
- "version": "0.14.15",
14398
- "fingerprint": "UmJj6oqVe7RG4sJvVrVK0jhMUqWxZ3FaF11lDGThQBo="
14923
+ "version": "0.14.16",
14924
+ "fingerprint": "K3YC8i/UkN8BMqI1iZlamDA0QRDRLflIUTSDTMQFhyA="
14399
14925
  }