Skip to content

aws-eco-runner

Actions
AWS Eco Runner is a solution designed to optimize the cost of using GitHub Actions runners
v1.0.0-beta.3
Latest
Verified creator
Star (10)

Verified

GitHub has manually verified the creator of the action as an official partner organization. For more info see About badges in GitHub Marketplace.

AWS Eco Runner

Automate the management of your GitHub Actions runner on AWS to minimize costs

Overview

AWS Eco Runner is a solution designed to optimize the cost of using GitHub Actions runners on AWS. By automating the activation and deactivation of the instance, it ensures that you only incur costs when necessary. The runner is kept active every 2 days (to not be removed as a Github Runner) and turned off when not in use, providing a cost-effective approach to managing GitHub Actions workflows.

Usage

    steps:
      # Configure AWS Credentials
      - name: Configure AWS Credentials
        uses: aws-actions/configure-aws-credentials@v4
        with:
          aws-region: us-west-2
          role-to-assume: $ARN_IAM_ROLE

      - name: Start Runner
        uses: nodesource/aws-eco-runner@v1
        with:
          instance_id: '["i-01", "i-02"]'
          action: 'start'
          aws_default_region: 'us-west-2'

        ...

      - name: Stop Runner
        uses: nodesource/aws-eco-runner@v1
        with:
          instance_id: '["i-01"]'
          action: 'stop'
          aws_default_region: 'us-west-2'

This action requires a minimal permission to start and stop the instance: This is an example IAM policy, you must adapt it to your needs.

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Sid": "VisualEditor0",
      "Effect": "Allow",
      "Action": ["ec2:StartInstances", "ec2:StopInstances"],
      "Resource": ["arn:aws:ec2:${REGION}:${ACCOUNT_ID}:instance/${INSTANCE_ID}"]
    }
  ]
}

aws-eco-runner is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

AWS Eco Runner is a solution designed to optimize the cost of using GitHub Actions runners
v1.0.0-beta.3
Latest

Verified

GitHub has manually verified the creator of the action as an official partner organization. For more info see About badges in GitHub Marketplace.

aws-eco-runner is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.