forked from Bos55/nix-config
Compare commits
2 commits
6a0fdca3aa
...
91221c93d7
| Author | SHA1 | Date | |
|---|---|---|---|
| 91221c93d7 | |||
| 16b72ed6e0 |
2 changed files with 50 additions and 0 deletions
34
.github/workflows/build.yml
vendored
Normal file
34
.github/workflows/build.yml
vendored
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
name: "Build"
|
||||
on:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
determine_hosts:
|
||||
name: "Determining hosts to build"
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: catthehacker/ubuntu:act-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: https://github.com/cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
- name: "List hosts"
|
||||
id: hosts
|
||||
run: nix eval .#nixosConfigurations --apply builtins.attrNames --json
|
||||
outputs:
|
||||
hosts: ${{ steps.hosts.outputs }}
|
||||
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: catthehacker/ubuntu:act-latest
|
||||
needs: determine_hosts
|
||||
strategy:
|
||||
matrix:
|
||||
hostname: ${{ fromJSON(needs.determine_hosts.outputs.hosts) }}
|
||||
|
||||
steps:
|
||||
- run: echo "${{ matrix.hostname }}"
|
||||
|
||||
16
.github/workflows/test.yml
vendored
Normal file
16
.github/workflows/test.yml
vendored
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
name: "Test"
|
||||
on:
|
||||
pull_request:
|
||||
push:
|
||||
jobs:
|
||||
tests:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: catthehacker/ubuntu:act-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v5
|
||||
- uses: https://github.com/cachix/install-nix-action@v31
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
- name: "My custom step"
|
||||
run: nix run nixpkgs#hello
|
||||
Loading…
Add table
Add a link
Reference in a new issue