Skip to content

Commit

Permalink
Try building for aarch64
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasGuilloux committed Oct 21, 2024
1 parent 7fe5a42 commit 4d0223c
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 11 deletions.
48 changes: 41 additions & 7 deletions .github/workflows/artifact.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,48 @@ on:
pull_request:

jobs:
check:
# check:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3

# - name: Install Nix
# uses: DeterminateSystems/nix-installer-action@main

# - name: Setup caches
# uses: DeterminateSystems/magic-nix-cache-action@main

# - name: Building tarball
# run: nix build

# - name: Uploading artifacts
# uses: actions/upload-artifact@v3
# with:
# name: nixos-system-x86_64-linux.tar.xz
# path: result/tarball/nixos-system-x86_64-linux.tar.xz

build:
runs-on: ubuntu-latest
strategy:
matrix:
arch: ['x86_64', 'aarch64']
steps:
- uses: actions/checkout@v3
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- run: nix build
- uses: actions/upload-artifact@v3
- run: sudo apt-get install -y qemu-user-static

- uses: cachix/install-nix-action@v21
with:
extra_nix_config: |
system = ${{ matrix.arch }}-linux
- name: Building tarball for ${{ matrix.arch }}
run: nix build

- name: Test
run: ls ./result/tarball/*

- name: Uploading artifacts
uses: actions/upload-artifact@v3
with:
name: nixos-system-x86_64-linux.tar.xz
path: result/tarball/nixos-system-x86_64-linux.tar.xz
name: nixos-system-${{ matrix.arch }}-linux.tar.xz
path: result/tarball/nixos-system-${{ matrix.arch }}-linux.tar.xz
2 changes: 1 addition & 1 deletion configuration.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
wget
];

system.stateVersion = "23.11";
system.stateVersion = "24.05";

# Set an initial password here or at runtime do `machinectl shell nixos` and
# run `passwd` there.
Expand Down
2 changes: 1 addition & 1 deletion flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

inputs = {
flake-parts.url = "github:hercules-ci/flake-parts";
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
treefmt-nix.inputs.nixpkgs.follows = "nixpkgs";
treefmt-nix.url = "github:numtide/treefmt-nix";
};
Expand Down
2 changes: 1 addition & 1 deletion nspawn-tarball.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ let

flakeFile = builtins.toFile "flake.nix" ''
{
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
outputs = inputs@{ self, nixpkgs, ...}: {
nixosConfigurations.${config.system.name} = nixpkgs.lib.nixosSystem {
Expand Down

0 comments on commit 4d0223c

Please sign in to comment.