Skip to content

Use a specific revision to see if we're stale #60

Use a specific revision to see if we're stale

Use a specific revision to see if we're stale #60

Workflow file for this run

on:
pull_request:
workflow_dispatch:
push:
branches:
- main
- master
tags:
- "v?[0-9]+.[0-9]+.[0-9]+*"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
BuildPublish:
runs-on: ubuntu-latest
outputs:
flakeref_exact: ${{ steps.flakehubpush.outputs.flakeref_exact }}
permissions:
id-token: "write"
contents: "read"
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
with:
flakehub: true
- uses: DeterminateSystems/magic-nix-cache-action@main
with:
source-pr: 103
use-gha-cache: false
- run: nix build .#nixosConfigurations.ethercalc-demo.config.system.build.toplevel
- uses: "DeterminateSystems/flakehub-push@main"
id: flakehubpush
with:
name: "DeterminateSystems/demo"
rolling: true
visibility: "private"
include-output-paths: true
source-revision: e0b268807af73d9e85608b72fe29887d068c7ede
Deploy:
if: github.ref == 'refs/heads/main'
needs: BuildPublish
runs-on: ubuntu-latest
permissions:
id-token: "write"
contents: "read"
steps:
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
aws-region: us-east-2
role-to-assume: arn:aws:iam::194722411868:role/github-actions/FlakeHubDeployDemo
- name: Deploy Ethercalc
run: |
aws ssm send-command \
--region us-east-2 \
--targets Key=tag:Name,Values=FlakeHubDemo \
--document-name "FlakeHub-ApplyNixOS" \
--parameters flakeref="${{ needs.BuildPublish.outputs.flakeref_exact }}#nixosConfigurations.ethercalc-demo"
- name: Breakpoint if tests failed
if: failure()
uses: namespacelabs/breakpoint-action@v0
with:
duration: 30m
authorized-users: grahamc