Fix container allModules import
Some checks failed
Check Flake / check-flake (push) Failing after 4s
Some checks failed
Check Flake / check-flake (push) Failing after 4s
This commit is contained in:
parent
5cae715fe6
commit
8623b39dc2
@ -10,10 +10,6 @@ jobs:
|
|||||||
check-flake:
|
check-flake:
|
||||||
runs-on: nixos
|
runs-on: nixos
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
run: nix profile install nixpkgs#nodejs-18_x
|
|
||||||
|
|
||||||
- name: Checkout the repository
|
- name: Checkout the repository
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ config, pkgs, lib, ... }:
|
{ config, pkgs, lib, allModules, ... }:
|
||||||
|
|
||||||
# Gitea Actions Runner. Starts 'host' runner that runs directly on the host inside of a nixos container
|
# Gitea Actions Runner. Starts 'host' runner that runs directly on the host inside of a nixos container
|
||||||
# This is useful for providing a real Nix/OS builder to gitea.
|
# This is useful for providing a real Nix/OS builder to gitea.
|
||||||
@ -12,7 +12,7 @@ let
|
|||||||
thisMachineIsARunner = builtins.elem config.networking.hostName runners;
|
thisMachineIsARunner = builtins.elem config.networking.hostName runners;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
config = lib.mkIf thisMachineIsARunner {
|
config = lib.mkIf (thisMachineIsARunner && !config.boot.isContainer) {
|
||||||
containers.gitea-runner = {
|
containers.gitea-runner = {
|
||||||
ephemeral = true;
|
ephemeral = true;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
@ -35,15 +35,15 @@ in
|
|||||||
];
|
];
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
# TODO: figure out why importing 'allModules' fails
|
imports = allModules;
|
||||||
# imports = allModules;
|
|
||||||
|
|
||||||
# speeds up evaluation
|
# speeds up evaluation
|
||||||
nixpkgs.pkgs = pkgs;
|
nixpkgs.pkgs = pkgs;
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
nodejs
|
|
||||||
git
|
git
|
||||||
|
# Gitea Actions rely heavily on node. Include it because it would be installed anyway.
|
||||||
|
nodejs
|
||||||
];
|
];
|
||||||
|
|
||||||
services.gitea-actions-runner.instances.inst = {
|
services.gitea-actions-runner.instances.inst = {
|
||||||
@ -59,8 +59,6 @@ in
|
|||||||
|
|
||||||
virtualisation.podman.enable = true;
|
virtualisation.podman.enable = true;
|
||||||
boot.binfmt.emulatedSystems = [ "aarch64-linux" ];
|
boot.binfmt.emulatedSystems = [ "aarch64-linux" ];
|
||||||
|
|
||||||
system.stateVersion = "23.05";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user