@cloudsnorkel/cdk-github-runners 0.14.7 → 0.14.9

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 (49) hide show
  1. package/.jsii +107 -73
  2. package/API.md +29 -3
  3. package/README.md +6 -0
  4. package/assets/delete-failed-runner.lambda/index.js +72 -46
  5. package/assets/idle-runner-repear.lambda/index.js +72 -46
  6. package/assets/image-builders/aws-image-builder/versioner.lambda/index.js +25 -10
  7. package/assets/setup.lambda/index.html +8 -8
  8. package/assets/status.lambda/index.js +72 -46
  9. package/assets/token-retriever.lambda/index.js +72 -46
  10. package/assets/webhook-handler.lambda/index.js +80 -49
  11. package/lib/access.js +1 -1
  12. package/lib/delete-failed-runner-function.js +2 -2
  13. package/lib/idle-runner-repear-function.js +2 -2
  14. package/lib/image-builders/api.js +1 -1
  15. package/lib/image-builders/aws-image-builder/ami.js +10 -2
  16. package/lib/image-builders/aws-image-builder/builder.js +1 -1
  17. package/lib/image-builders/aws-image-builder/container.d.ts +1 -1
  18. package/lib/image-builders/aws-image-builder/container.js +5 -2
  19. package/lib/image-builders/aws-image-builder/delete-resources-function.js +2 -2
  20. package/lib/image-builders/aws-image-builder/deprecated/ami.js +4 -4
  21. package/lib/image-builders/aws-image-builder/deprecated/container.js +1 -1
  22. package/lib/image-builders/aws-image-builder/deprecated/linux-components.js +1 -1
  23. package/lib/image-builders/aws-image-builder/deprecated/windows-components.js +1 -1
  24. package/lib/image-builders/aws-image-builder/filter-failed-builds-function.js +2 -2
  25. package/lib/image-builders/aws-image-builder/versioner-function.js +2 -2
  26. package/lib/image-builders/build-image-function.js +2 -2
  27. package/lib/image-builders/codebuild-deprecated.js +1 -1
  28. package/lib/image-builders/common.d.ts +2 -2
  29. package/lib/image-builders/common.js +1 -1
  30. package/lib/image-builders/components.js +16 -16
  31. package/lib/image-builders/static.js +1 -1
  32. package/lib/providers/ami-root-device-function.js +2 -2
  33. package/lib/providers/codebuild.js +2 -2
  34. package/lib/providers/common.d.ts +17 -1
  35. package/lib/providers/common.js +22 -6
  36. package/lib/providers/ec2.js +2 -2
  37. package/lib/providers/ecs.js +1 -1
  38. package/lib/providers/fargate.js +2 -2
  39. package/lib/providers/lambda.js +2 -2
  40. package/lib/providers/update-lambda-function.js +2 -2
  41. package/lib/runner.js +2 -2
  42. package/lib/secrets.js +1 -1
  43. package/lib/setup-function.js +2 -2
  44. package/lib/status-function.js +2 -2
  45. package/lib/token-retriever-function.js +2 -2
  46. package/lib/webhook-handler-function.js +2 -2
  47. package/lib/webhook-handler.lambda.d.ts +8 -0
  48. package/lib/webhook-handler.lambda.js +15 -5
  49. package/package.json +22 -22
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.5.10 (build 224bf90)",
3837
+ "jsiiVersion": "5.8.13 (build 2043962)",
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## 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## 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",
@@ -5665,7 +5665,7 @@
5665
5665
  },
5666
5666
  "locationInModule": {
5667
5667
  "filename": "src/providers/common.ts",
5668
- "line": 528
5668
+ "line": 549
5669
5669
  },
5670
5670
  "name": "labelsFromProperties",
5671
5671
  "parameters": [
@@ -6996,7 +6996,7 @@
6996
6996
  },
6997
6997
  "locationInModule": {
6998
6998
  "filename": "src/providers/common.ts",
6999
- "line": 528
6999
+ "line": 549
7000
7000
  },
7001
7001
  "name": "labelsFromProperties",
7002
7002
  "parameters": [
@@ -7593,7 +7593,7 @@
7593
7593
  },
7594
7594
  "locationInModule": {
7595
7595
  "filename": "src/providers/common.ts",
7596
- "line": 528
7596
+ "line": 549
7597
7597
  },
7598
7598
  "name": "labelsFromProperties",
7599
7599
  "parameters": [
@@ -8347,7 +8347,7 @@
8347
8347
  },
8348
8348
  "locationInModule": {
8349
8349
  "filename": "src/providers/common.ts",
8350
- "line": 528
8350
+ "line": 549
8351
8351
  },
8352
8352
  "name": "labelsFromProperties",
8353
8353
  "parameters": [
@@ -9667,7 +9667,7 @@
9667
9667
  "kind": "interface",
9668
9668
  "locationInModule": {
9669
9669
  "filename": "src/providers/common.ts",
9670
- "line": 372
9670
+ "line": 393
9671
9671
  },
9672
9672
  "name": "IRunnerAmiStatus",
9673
9673
  "properties": [
@@ -9680,7 +9680,7 @@
9680
9680
  "immutable": true,
9681
9681
  "locationInModule": {
9682
9682
  "filename": "src/providers/common.ts",
9683
- "line": 376
9683
+ "line": 397
9684
9684
  },
9685
9685
  "name": "launchTemplate",
9686
9686
  "type": {
@@ -9696,7 +9696,7 @@
9696
9696
  "immutable": true,
9697
9697
  "locationInModule": {
9698
9698
  "filename": "src/providers/common.ts",
9699
- "line": 381
9699
+ "line": 402
9700
9700
  },
9701
9701
  "name": "amiBuilderLogGroup",
9702
9702
  "optional": true,
@@ -9771,7 +9771,7 @@
9771
9771
  "kind": "interface",
9772
9772
  "locationInModule": {
9773
9773
  "filename": "src/providers/common.ts",
9774
- "line": 352
9774
+ "line": 373
9775
9775
  },
9776
9776
  "name": "IRunnerImageStatus",
9777
9777
  "properties": [
@@ -9784,7 +9784,7 @@
9784
9784
  "immutable": true,
9785
9785
  "locationInModule": {
9786
9786
  "filename": "src/providers/common.ts",
9787
- "line": 356
9787
+ "line": 377
9788
9788
  },
9789
9789
  "name": "imageRepository",
9790
9790
  "type": {
@@ -9800,7 +9800,7 @@
9800
9800
  "immutable": true,
9801
9801
  "locationInModule": {
9802
9802
  "filename": "src/providers/common.ts",
9803
- "line": 361
9803
+ "line": 382
9804
9804
  },
9805
9805
  "name": "imageTag",
9806
9806
  "type": {
@@ -9816,7 +9816,7 @@
9816
9816
  "immutable": true,
9817
9817
  "locationInModule": {
9818
9818
  "filename": "src/providers/common.ts",
9819
- "line": 366
9819
+ "line": 387
9820
9820
  },
9821
9821
  "name": "imageBuilderLogGroup",
9822
9822
  "optional": true,
@@ -9843,7 +9843,7 @@
9843
9843
  "kind": "interface",
9844
9844
  "locationInModule": {
9845
9845
  "filename": "src/providers/common.ts",
9846
- "line": 432
9846
+ "line": 453
9847
9847
  },
9848
9848
  "methods": [
9849
9849
  {
@@ -9855,7 +9855,7 @@
9855
9855
  },
9856
9856
  "locationInModule": {
9857
9857
  "filename": "src/providers/common.ts",
9858
- "line": 463
9858
+ "line": 484
9859
9859
  },
9860
9860
  "name": "getStepFunctionTask",
9861
9861
  "parameters": [
@@ -9884,7 +9884,7 @@
9884
9884
  },
9885
9885
  "locationInModule": {
9886
9886
  "filename": "src/providers/common.ts",
9887
- "line": 471
9887
+ "line": 492
9888
9888
  },
9889
9889
  "name": "grantStateMachine",
9890
9890
  "parameters": [
@@ -9908,7 +9908,7 @@
9908
9908
  },
9909
9909
  "locationInModule": {
9910
9910
  "filename": "src/providers/common.ts",
9911
- "line": 478
9911
+ "line": 499
9912
9912
  },
9913
9913
  "name": "status",
9914
9914
  "parameters": [
@@ -9941,7 +9941,7 @@
9941
9941
  "immutable": true,
9942
9942
  "locationInModule": {
9943
9943
  "filename": "src/providers/common.ts",
9944
- "line": 440
9944
+ "line": 461
9945
9945
  },
9946
9946
  "name": "labels",
9947
9947
  "type": {
@@ -9963,7 +9963,7 @@
9963
9963
  "immutable": true,
9964
9964
  "locationInModule": {
9965
9965
  "filename": "src/providers/common.ts",
9966
- "line": 447
9966
+ "line": 468
9967
9967
  },
9968
9968
  "name": "logGroup",
9969
9969
  "type": {
@@ -9980,7 +9980,7 @@
9980
9980
  "immutable": true,
9981
9981
  "locationInModule": {
9982
9982
  "filename": "src/providers/common.ts",
9983
- "line": 454
9983
+ "line": 475
9984
9984
  },
9985
9985
  "name": "retryableErrors",
9986
9986
  "type": {
@@ -10005,7 +10005,7 @@
10005
10005
  "kind": "interface",
10006
10006
  "locationInModule": {
10007
10007
  "filename": "src/providers/common.ts",
10008
- "line": 387
10008
+ "line": 408
10009
10009
  },
10010
10010
  "name": "IRunnerProviderStatus",
10011
10011
  "properties": [
@@ -10018,7 +10018,7 @@
10018
10018
  "immutable": true,
10019
10019
  "locationInModule": {
10020
10020
  "filename": "src/providers/common.ts",
10021
- "line": 396
10021
+ "line": 417
10022
10022
  },
10023
10023
  "name": "labels",
10024
10024
  "type": {
@@ -10039,7 +10039,7 @@
10039
10039
  "immutable": true,
10040
10040
  "locationInModule": {
10041
10041
  "filename": "src/providers/common.ts",
10042
- "line": 391
10042
+ "line": 412
10043
10043
  },
10044
10044
  "name": "type",
10045
10045
  "type": {
@@ -10055,7 +10055,7 @@
10055
10055
  "immutable": true,
10056
10056
  "locationInModule": {
10057
10057
  "filename": "src/providers/common.ts",
10058
- "line": 421
10058
+ "line": 442
10059
10059
  },
10060
10060
  "name": "ami",
10061
10061
  "optional": true,
@@ -10072,7 +10072,7 @@
10072
10072
  "immutable": true,
10073
10073
  "locationInModule": {
10074
10074
  "filename": "src/providers/common.ts",
10075
- "line": 416
10075
+ "line": 437
10076
10076
  },
10077
10077
  "name": "image",
10078
10078
  "optional": true,
@@ -10089,7 +10089,7 @@
10089
10089
  "immutable": true,
10090
10090
  "locationInModule": {
10091
10091
  "filename": "src/providers/common.ts",
10092
- "line": 426
10092
+ "line": 447
10093
10093
  },
10094
10094
  "name": "logGroup",
10095
10095
  "optional": true,
@@ -10106,7 +10106,7 @@
10106
10106
  "immutable": true,
10107
10107
  "locationInModule": {
10108
10108
  "filename": "src/providers/common.ts",
10109
- "line": 411
10109
+ "line": 432
10110
10110
  },
10111
10111
  "name": "roleArn",
10112
10112
  "optional": true,
@@ -10123,7 +10123,7 @@
10123
10123
  "immutable": true,
10124
10124
  "locationInModule": {
10125
10125
  "filename": "src/providers/common.ts",
10126
- "line": 406
10126
+ "line": 427
10127
10127
  },
10128
10128
  "name": "securityGroups",
10129
10129
  "optional": true,
@@ -10145,7 +10145,7 @@
10145
10145
  "immutable": true,
10146
10146
  "locationInModule": {
10147
10147
  "filename": "src/providers/common.ts",
10148
- "line": 401
10148
+ "line": 422
10149
10149
  },
10150
10150
  "name": "vpcArn",
10151
10151
  "optional": true,
@@ -10847,7 +10847,7 @@
10847
10847
  },
10848
10848
  "locationInModule": {
10849
10849
  "filename": "src/providers/common.ts",
10850
- "line": 528
10850
+ "line": 549
10851
10851
  },
10852
10852
  "name": "labelsFromProperties",
10853
10853
  "parameters": [
@@ -11744,7 +11744,7 @@
11744
11744
  },
11745
11745
  "locationInModule": {
11746
11746
  "filename": "src/providers/common.ts",
11747
- "line": 160
11747
+ "line": 181
11748
11748
  },
11749
11749
  "name": "is",
11750
11750
  "parameters": [
@@ -11771,7 +11771,7 @@
11771
11771
  },
11772
11772
  "locationInModule": {
11773
11773
  "filename": "src/providers/common.ts",
11774
- "line": 169
11774
+ "line": 190
11775
11775
  },
11776
11776
  "name": "isIn",
11777
11777
  "parameters": [
@@ -11802,7 +11802,7 @@
11802
11802
  {
11803
11803
  "const": true,
11804
11804
  "docs": {
11805
- "deprecated": "use {@link LINUX_UBUNTU } or {@link LINUX_AMAZON_2 } or {@link LINUX_AMAZON_2023 }",
11805
+ "deprecated": "use {@link LINUX_UBUNTU }, {@link LINUX_UBUNTU_2404 }, {@link LINUX_AMAZON_2 } or {@link LINUX_AMAZON_2023 }",
11806
11806
  "stability": "deprecated",
11807
11807
  "summary": "Linux."
11808
11808
  },
@@ -11826,7 +11826,7 @@
11826
11826
  "immutable": true,
11827
11827
  "locationInModule": {
11828
11828
  "filename": "src/providers/common.ts",
11829
- "line": 131
11829
+ "line": 141
11830
11830
  },
11831
11831
  "name": "LINUX_AMAZON_2",
11832
11832
  "static": true,
@@ -11843,7 +11843,7 @@
11843
11843
  "immutable": true,
11844
11844
  "locationInModule": {
11845
11845
  "filename": "src/providers/common.ts",
11846
- "line": 136
11846
+ "line": 146
11847
11847
  },
11848
11848
  "name": "LINUX_AMAZON_2023",
11849
11849
  "static": true,
@@ -11868,6 +11868,40 @@
11868
11868
  "fqn": "@cloudsnorkel/cdk-github-runners.Os"
11869
11869
  }
11870
11870
  },
11871
+ {
11872
+ "const": true,
11873
+ "docs": {
11874
+ "stability": "experimental",
11875
+ "summary": "Ubuntu Linux 22.04."
11876
+ },
11877
+ "immutable": true,
11878
+ "locationInModule": {
11879
+ "filename": "src/providers/common.ts",
11880
+ "line": 131
11881
+ },
11882
+ "name": "LINUX_UBUNTU_2204",
11883
+ "static": true,
11884
+ "type": {
11885
+ "fqn": "@cloudsnorkel/cdk-github-runners.Os"
11886
+ }
11887
+ },
11888
+ {
11889
+ "const": true,
11890
+ "docs": {
11891
+ "stability": "experimental",
11892
+ "summary": "Ubuntu Linux 24.04."
11893
+ },
11894
+ "immutable": true,
11895
+ "locationInModule": {
11896
+ "filename": "src/providers/common.ts",
11897
+ "line": 136
11898
+ },
11899
+ "name": "LINUX_UBUNTU_2404",
11900
+ "static": true,
11901
+ "type": {
11902
+ "fqn": "@cloudsnorkel/cdk-github-runners.Os"
11903
+ }
11904
+ },
11871
11905
  {
11872
11906
  "const": true,
11873
11907
  "docs": {
@@ -11877,7 +11911,7 @@
11877
11911
  "immutable": true,
11878
11912
  "locationInModule": {
11879
11913
  "filename": "src/providers/common.ts",
11880
- "line": 146
11914
+ "line": 167
11881
11915
  },
11882
11916
  "name": "WINDOWS",
11883
11917
  "static": true,
@@ -11892,7 +11926,7 @@
11892
11926
  "immutable": true,
11893
11927
  "locationInModule": {
11894
11928
  "filename": "src/providers/common.ts",
11895
- "line": 152
11929
+ "line": 173
11896
11930
  },
11897
11931
  "name": "name",
11898
11932
  "type": {
@@ -11914,7 +11948,7 @@
11914
11948
  "kind": "interface",
11915
11949
  "locationInModule": {
11916
11950
  "filename": "src/providers/common.ts",
11917
- "line": 258
11951
+ "line": 279
11918
11952
  },
11919
11953
  "name": "ProviderRetryOptions",
11920
11954
  "properties": [
@@ -11928,7 +11962,7 @@
11928
11962
  "immutable": true,
11929
11963
  "locationInModule": {
11930
11964
  "filename": "src/providers/common.ts",
11931
- "line": 285
11965
+ "line": 306
11932
11966
  },
11933
11967
  "name": "backoffRate",
11934
11968
  "optional": true,
@@ -11947,7 +11981,7 @@
11947
11981
  "immutable": true,
11948
11982
  "locationInModule": {
11949
11983
  "filename": "src/providers/common.ts",
11950
- "line": 271
11984
+ "line": 292
11951
11985
  },
11952
11986
  "name": "interval",
11953
11987
  "optional": true,
@@ -11965,7 +11999,7 @@
11965
11999
  "immutable": true,
11966
12000
  "locationInModule": {
11967
12001
  "filename": "src/providers/common.ts",
11968
- "line": 278
12002
+ "line": 299
11969
12003
  },
11970
12004
  "name": "maxAttempts",
11971
12005
  "optional": true,
@@ -11984,7 +12018,7 @@
11984
12018
  "immutable": true,
11985
12019
  "locationInModule": {
11986
12020
  "filename": "src/providers/common.ts",
11987
- "line": 264
12021
+ "line": 285
11988
12022
  },
11989
12023
  "name": "retry",
11990
12024
  "optional": true,
@@ -12006,7 +12040,7 @@
12006
12040
  "kind": "interface",
12007
12041
  "locationInModule": {
12008
12042
  "filename": "src/providers/common.ts",
12009
- "line": 226
12043
+ "line": 247
12010
12044
  },
12011
12045
  "name": "RunnerAmi",
12012
12046
  "properties": [
@@ -12019,7 +12053,7 @@
12019
12053
  "immutable": true,
12020
12054
  "locationInModule": {
12021
12055
  "filename": "src/providers/common.ts",
12022
- "line": 235
12056
+ "line": 256
12023
12057
  },
12024
12058
  "name": "architecture",
12025
12059
  "type": {
@@ -12035,7 +12069,7 @@
12035
12069
  "immutable": true,
12036
12070
  "locationInModule": {
12037
12071
  "filename": "src/providers/common.ts",
12038
- "line": 230
12072
+ "line": 251
12039
12073
  },
12040
12074
  "name": "launchTemplate",
12041
12075
  "type": {
@@ -12051,7 +12085,7 @@
12051
12085
  "immutable": true,
12052
12086
  "locationInModule": {
12053
12087
  "filename": "src/providers/common.ts",
12054
- "line": 240
12088
+ "line": 261
12055
12089
  },
12056
12090
  "name": "os",
12057
12091
  "type": {
@@ -12068,7 +12102,7 @@
12068
12102
  "immutable": true,
12069
12103
  "locationInModule": {
12070
12104
  "filename": "src/providers/common.ts",
12071
- "line": 252
12105
+ "line": 273
12072
12106
  },
12073
12107
  "name": "runnerVersion",
12074
12108
  "type": {
@@ -12084,7 +12118,7 @@
12084
12118
  "immutable": true,
12085
12119
  "locationInModule": {
12086
12120
  "filename": "src/providers/common.ts",
12087
- "line": 245
12121
+ "line": 266
12088
12122
  },
12089
12123
  "name": "logGroup",
12090
12124
  "optional": true,
@@ -12106,7 +12140,7 @@
12106
12140
  "kind": "interface",
12107
12141
  "locationInModule": {
12108
12142
  "filename": "src/providers/common.ts",
12109
- "line": 182
12143
+ "line": 203
12110
12144
  },
12111
12145
  "name": "RunnerImage",
12112
12146
  "properties": [
@@ -12119,7 +12153,7 @@
12119
12153
  "immutable": true,
12120
12154
  "locationInModule": {
12121
12155
  "filename": "src/providers/common.ts",
12122
- "line": 196
12156
+ "line": 217
12123
12157
  },
12124
12158
  "name": "architecture",
12125
12159
  "type": {
@@ -12135,7 +12169,7 @@
12135
12169
  "immutable": true,
12136
12170
  "locationInModule": {
12137
12171
  "filename": "src/providers/common.ts",
12138
- "line": 186
12172
+ "line": 207
12139
12173
  },
12140
12174
  "name": "imageRepository",
12141
12175
  "type": {
@@ -12151,7 +12185,7 @@
12151
12185
  "immutable": true,
12152
12186
  "locationInModule": {
12153
12187
  "filename": "src/providers/common.ts",
12154
- "line": 191
12188
+ "line": 212
12155
12189
  },
12156
12190
  "name": "imageTag",
12157
12191
  "type": {
@@ -12167,7 +12201,7 @@
12167
12201
  "immutable": true,
12168
12202
  "locationInModule": {
12169
12203
  "filename": "src/providers/common.ts",
12170
- "line": 201
12204
+ "line": 222
12171
12205
  },
12172
12206
  "name": "os",
12173
12207
  "type": {
@@ -12184,7 +12218,7 @@
12184
12218
  "immutable": true,
12185
12219
  "locationInModule": {
12186
12220
  "filename": "src/providers/common.ts",
12187
- "line": 213
12221
+ "line": 234
12188
12222
  },
12189
12223
  "name": "runnerVersion",
12190
12224
  "type": {
@@ -12200,7 +12234,7 @@
12200
12234
  "immutable": true,
12201
12235
  "locationInModule": {
12202
12236
  "filename": "src/providers/common.ts",
12203
- "line": 206
12237
+ "line": 227
12204
12238
  },
12205
12239
  "name": "logGroup",
12206
12240
  "optional": true,
@@ -12543,7 +12577,7 @@
12543
12577
  {
12544
12578
  "abstract": true,
12545
12579
  "docs": {
12546
- "default": "latest Ubuntu 22.04 AMI for Os.LINUX_UBUNTU, latest Amazon Linux 2 AMI for Os.LINUX_AMAZON_2, latest Windows Server 2022 AMI for Os.WINDOWS",
12580
+ "default": "latest Ubuntu 22.04 AMI for Os.LINUX_UBUNTU and Os.LINUX_UBUNTU_2204, Ubuntu 24.04 AMI for Os.LINUX_UBUNTU_2404, latest Amazon Linux 2 AMI for Os.LINUX_AMAZON_2, latest Windows Server 2022 AMI for Os.WINDOWS",
12547
12581
  "remarks": "This can be an actual AMI or an AWS Image Builder ARN that points to the latest AMI. For example `arn:aws:imagebuilder:us-east-1:aws:image/ubuntu-server-22-lts-x86/x.x.x` would always use the latest version of Ubuntu 22.04 in each build. If you want a specific version, you can replace `x.x.x` with that version.",
12548
12582
  "stability": "experimental",
12549
12583
  "summary": "Base AMI from which runner AMIs will be built."
@@ -12562,7 +12596,7 @@
12562
12596
  {
12563
12597
  "abstract": true,
12564
12598
  "docs": {
12565
- "default": "public.ecr.aws/lts/ubuntu:22.04 for Os.LINUX_UBUNTU, public.ecr.aws/amazonlinux/amazonlinux:2 for Os.LINUX_AMAZON_2, mcr.microsoft.com/windows/servercore:ltsc2019-amd64 for Os.WINDOWS",
12599
+ "default": "public.ecr.aws/lts/ubuntu:22.04 for Os.LINUX_UBUNTU and Os.LINUX_UBUNTU_2204, public.ecr.aws/lts/ubuntu:24.04 for Os.LINUX_UBUNTU_2404, public.ecr.aws/amazonlinux/amazonlinux:2 for Os.LINUX_AMAZON_2, mcr.microsoft.com/windows/servercore:ltsc2019-amd64 for Os.WINDOWS",
12566
12600
  "remarks": "When using private images from a different account or not on ECR, you may need to include additional setup commands with {@link dockerSetupCommands}.",
12567
12601
  "stability": "experimental",
12568
12602
  "summary": "Base image from which Docker runner images will be built."
@@ -13423,7 +13457,7 @@
13423
13457
  "kind": "interface",
13424
13458
  "locationInModule": {
13425
13459
  "filename": "src/providers/common.ts",
13426
- "line": 291
13460
+ "line": 312
13427
13461
  },
13428
13462
  "name": "RunnerProviderProps",
13429
13463
  "properties": [
@@ -13438,7 +13472,7 @@
13438
13472
  "immutable": true,
13439
13473
  "locationInModule": {
13440
13474
  "filename": "src/providers/common.ts",
13441
- "line": 299
13475
+ "line": 320
13442
13476
  },
13443
13477
  "name": "logRetention",
13444
13478
  "optional": true,
@@ -13455,7 +13489,7 @@
13455
13489
  "immutable": true,
13456
13490
  "locationInModule": {
13457
13491
  "filename": "src/providers/common.ts",
13458
- "line": 304
13492
+ "line": 325
13459
13493
  },
13460
13494
  "name": "retryOptions",
13461
13495
  "optional": true,
@@ -13478,7 +13512,7 @@
13478
13512
  "kind": "interface",
13479
13513
  "locationInModule": {
13480
13514
  "filename": "src/providers/common.ts",
13481
- "line": 316
13515
+ "line": 337
13482
13516
  },
13483
13517
  "name": "RunnerRuntimeParameters",
13484
13518
  "properties": [
@@ -13492,7 +13526,7 @@
13492
13526
  "immutable": true,
13493
13527
  "locationInModule": {
13494
13528
  "filename": "src/providers/common.ts",
13495
- "line": 330
13529
+ "line": 351
13496
13530
  },
13497
13531
  "name": "githubDomainPath",
13498
13532
  "type": {
@@ -13508,7 +13542,7 @@
13508
13542
  "immutable": true,
13509
13543
  "locationInModule": {
13510
13544
  "filename": "src/providers/common.ts",
13511
- "line": 335
13545
+ "line": 356
13512
13546
  },
13513
13547
  "name": "ownerPath",
13514
13548
  "type": {
@@ -13524,7 +13558,7 @@
13524
13558
  "immutable": true,
13525
13559
  "locationInModule": {
13526
13560
  "filename": "src/providers/common.ts",
13527
- "line": 345
13561
+ "line": 366
13528
13562
  },
13529
13563
  "name": "registrationUrl",
13530
13564
  "type": {
@@ -13540,7 +13574,7 @@
13540
13574
  "immutable": true,
13541
13575
  "locationInModule": {
13542
13576
  "filename": "src/providers/common.ts",
13543
- "line": 340
13577
+ "line": 361
13544
13578
  },
13545
13579
  "name": "repoPath",
13546
13580
  "type": {
@@ -13557,7 +13591,7 @@
13557
13591
  "immutable": true,
13558
13592
  "locationInModule": {
13559
13593
  "filename": "src/providers/common.ts",
13560
- "line": 325
13594
+ "line": 346
13561
13595
  },
13562
13596
  "name": "runnerNamePath",
13563
13597
  "type": {
@@ -13573,7 +13607,7 @@
13573
13607
  "immutable": true,
13574
13608
  "locationInModule": {
13575
13609
  "filename": "src/providers/common.ts",
13576
- "line": 320
13610
+ "line": 341
13577
13611
  },
13578
13612
  "name": "runnerTokenPath",
13579
13613
  "type": {
@@ -13964,7 +13998,7 @@
13964
13998
  "kind": "interface",
13965
13999
  "locationInModule": {
13966
14000
  "filename": "src/providers/common.ts",
13967
- "line": 484
14001
+ "line": 505
13968
14002
  },
13969
14003
  "name": "StorageOptions",
13970
14004
  "properties": [
@@ -13980,7 +14014,7 @@
13980
14014
  "immutable": true,
13981
14015
  "locationInModule": {
13982
14016
  "filename": "src/providers/common.ts",
13983
- "line": 505
14017
+ "line": 526
13984
14018
  },
13985
14019
  "name": "iops",
13986
14020
  "optional": true,
@@ -13999,7 +14033,7 @@
13999
14033
  "immutable": true,
14000
14034
  "locationInModule": {
14001
14035
  "filename": "src/providers/common.ts",
14002
- "line": 513
14036
+ "line": 534
14003
14037
  },
14004
14038
  "name": "throughput",
14005
14039
  "optional": true,
@@ -14018,7 +14052,7 @@
14018
14052
  "immutable": true,
14019
14053
  "locationInModule": {
14020
14054
  "filename": "src/providers/common.ts",
14021
- "line": 491
14055
+ "line": 512
14022
14056
  },
14023
14057
  "name": "volumeType",
14024
14058
  "optional": true,
@@ -14276,6 +14310,6 @@
14276
14310
  "symbolId": "src/image-builders/aws-image-builder/deprecated/windows-components:WindowsComponents"
14277
14311
  }
14278
14312
  },
14279
- "version": "0.14.7",
14280
- "fingerprint": "A1ND9oGi1xUz0Bd+QrivB9z+DfH3HRLAy0BYjqNaBxA="
14313
+ "version": "0.14.9",
14314
+ "fingerprint": "VyMDMYlRN7iPG1XXNQpOV9RjxOJciYeli5ro3vm5Dj4="
14281
14315
  }