Skip to content

feat(iso): add iso-build feature #12

feat(iso): add iso-build feature

feat(iso): add iso-build feature #12

jobs:
build-topology-and-commit:
environment:
name: dev
permissions:
contents: write
id-token: write
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@main
with:
fetch-depth: 1
persist-credentials: false
- name: Set env var
run: echo "OS_NIXCFG=$(pwd)" 1>> "$GITHUB_ENV"
- uses: DeterminateSystems/nix-installer-action@v21
- name: Magic Nix Cache(Use Github Actions Cache)
uses: DeterminateSystems/magic-nix-cache-action@main
- name: Configure to use personal binary cache @ Cachix
uses: cachix/cachix-action@master
with:
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
name: divitmittal
- name: SSH-agent with auth for private repos
uses: webfactory/ssh-agent@master
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Build topology visualization
run: nix -vL build --accept-flake-config .#topology.x86_64-linux.config.output
--impure --show-trace
- name: Create assets directory for topology
run: mkdir -p ./assets/topology
- name: Copy topology SVGs to assets
run: |-
# Copy all generated SVG files
cp -v result/*.svg ./assets/topology/ || true
# List what was copied
ls -lh ./assets/topology/
- env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
name: Commit topology visualizations
run: |-
git config --global user.name "GitHub Actions Bot"
git config --global user.email bot@github.com
git add assets/topology/
# Only commit if there are changes
git diff --staged --quiet || git commit -m "chore: update topology visualizations"
git push origin master || echo "No changes to push"
timeout-minutes: 90
'on':
pull_request:
branches:
- master
paths:
- topology/**
- flake/topology.nix
- hosts/nixos/**
push:
branches:
- master
paths:
- topology/**
- flake/topology.nix
- hosts/nixos/**
workflow_dispatch: {}