Skip to content

Collect AWS reports #475

Collect AWS reports

Collect AWS reports #475

Workflow file for this run

name: Collect AWS reports
on:
schedule:
- cron: '12 9 * * *'
workflow_dispatch:
inputs:
instanceTypes:
description: 'Instance types pattern'
required: true
default: 't*'
type: string
spotCap:
description: 'Spot pricing cap as percentage of full price (0 to 1)'
required: true
default: '0.35'
type: string
jobs:
report:
name: Collect AWS reports
runs-on: ubuntu-latest
permissions:
id-token: write
contents: read
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1-node16
with:
role-to-assume: ${{ secrets.AWS_REPORT_ROLE }}
aws-region: us-east-1
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.18
cache: true
- name: Build script
run: |
go build scripts/collect-aws.go
- name: Run spot instances
run: |
./collect-aws --include ${{ inputs.instanceTypes || 't*' }} --spot-cap ${{ inputs.spotCap || '0.35' }}