mirror of
https://github.com/dump-dvb/nix-config.git
synced 2024-06-18 05:36:05 +02:00
adding mobile box as seperate system
This commit is contained in:
parent
dbc17e047a
commit
2ca93eb2e8
56
flake.lock
56
flake.lock
|
@ -28,7 +28,7 @@
|
|||
"decode-server": {
|
||||
"inputs": {
|
||||
"naersk": "naersk",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"utils": "utils_2"
|
||||
},
|
||||
"locked": {
|
||||
|
@ -48,7 +48,7 @@
|
|||
"dvb-api": {
|
||||
"inputs": {
|
||||
"naersk": "naersk_2",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nixpkgs": "nixpkgs_4",
|
||||
"utils": "utils_3"
|
||||
},
|
||||
"locked": {
|
||||
|
@ -67,10 +67,7 @@
|
|||
},
|
||||
"naersk": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"decode-server",
|
||||
"nixpkgs"
|
||||
]
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1651574473,
|
||||
|
@ -88,10 +85,7 @@
|
|||
},
|
||||
"naersk_2": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"dvb-api",
|
||||
"nixpkgs"
|
||||
]
|
||||
"nixpkgs": "nixpkgs_3"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1650265945,
|
||||
|
@ -128,6 +122,20 @@
|
|||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1651927509,
|
||||
"narHash": "sha256-fGVGUdEsriuAL1vkUh29FlOQmEkPRnSfRGImWYaVjos=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "2fdb6f2e08e7989b03a2a1aa8538d99e3eeea881",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1651571855,
|
||||
"narHash": "sha256-KZie6c2J2DUPLjG2PkYSwGLvD6RygA3TxZSPQpctbNI=",
|
||||
|
@ -143,7 +151,21 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"nixpkgs_3": {
|
||||
"locked": {
|
||||
"lastModified": 1651927509,
|
||||
"narHash": "sha256-fGVGUdEsriuAL1vkUh29FlOQmEkPRnSfRGImWYaVjos=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "2fdb6f2e08e7989b03a2a1aa8538d99e3eeea881",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs_4": {
|
||||
"locked": {
|
||||
"lastModified": 1651007983,
|
||||
"narHash": "sha256-GNay7yDPtLcRcKCNHldug85AhAvBpTtPEJWSSDYBw8U=",
|
||||
|
@ -159,7 +181,7 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_3": {
|
||||
"nixpkgs_5": {
|
||||
"locked": {
|
||||
"lastModified": 1651848520,
|
||||
"narHash": "sha256-KkJ28fShdd78+zal5HlHsXUICOCtO7Bdvylc5zlp5Mk=",
|
||||
|
@ -175,7 +197,7 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_4": {
|
||||
"nixpkgs_6": {
|
||||
"locked": {
|
||||
"lastModified": 1651571855,
|
||||
"narHash": "sha256-KZie6c2J2DUPLjG2PkYSwGLvD6RygA3TxZSPQpctbNI=",
|
||||
|
@ -191,7 +213,7 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_5": {
|
||||
"nixpkgs_7": {
|
||||
"locked": {
|
||||
"lastModified": 1651007983,
|
||||
"narHash": "sha256-GNay7yDPtLcRcKCNHldug85AhAvBpTtPEJWSSDYBw8U=",
|
||||
|
@ -209,7 +231,7 @@
|
|||
},
|
||||
"radio-conf": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_4",
|
||||
"nixpkgs": "nixpkgs_6",
|
||||
"utils": "utils_4"
|
||||
},
|
||||
"locked": {
|
||||
|
@ -232,7 +254,7 @@
|
|||
"decode-server": "decode-server",
|
||||
"dvb-api": "dvb-api",
|
||||
"naersk": "naersk_3",
|
||||
"nixpkgs": "nixpkgs_3",
|
||||
"nixpkgs": "nixpkgs_5",
|
||||
"radio-conf": "radio-conf",
|
||||
"stops": "stops_2",
|
||||
"windshield": "windshield"
|
||||
|
@ -347,7 +369,7 @@
|
|||
},
|
||||
"windshield": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_5",
|
||||
"nixpkgs": "nixpkgs_7",
|
||||
"utils": "utils_5"
|
||||
},
|
||||
"locked": {
|
||||
|
|
11
flake.nix
11
flake.nix
|
@ -44,8 +44,8 @@
|
|||
specialArgs = { inherit inputs; };
|
||||
modules = [
|
||||
./hosts/traffic-stop-box/configuration.nix
|
||||
(./hosts/traffic-stop-box/hardware-configuration.nix)
|
||||
./hosts/traffic-stop-box/configuration-dell-wyse-3040.nix
|
||||
./hosts/traffic-stop-box/hardware-configuration.nix
|
||||
./hardware/configuration-dell-wyse-3040.nix
|
||||
./modules/gnuradio.nix
|
||||
./modules/radio_wireguard_client.nix
|
||||
./modules/numbering.nix
|
||||
|
@ -82,9 +82,11 @@
|
|||
specialArgs = { inherit inputs; };
|
||||
modules = [
|
||||
"${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-base.nix"
|
||||
./hosts/traffic-stop-box/configuration.nix
|
||||
./hosts/traffic-stop-box/configuration-dell-wyse-3040.nix
|
||||
./hosts/mobile-box/configuration.nix
|
||||
./hosts/mobile-box/hardware-configuration.nix
|
||||
./hardware/configuration-dell-wyse-3040.nix
|
||||
./modules/numbering.nix
|
||||
./modules/mobile-box.nix
|
||||
{
|
||||
nixpkgs.overlays = [
|
||||
radio-conf.overlay."x86_64-linux"
|
||||
|
@ -92,6 +94,7 @@
|
|||
data-accumulator.overlay."x86_64-linux"
|
||||
];
|
||||
dvb-dump.stopsJson = "${stops}/stops.json";
|
||||
dvb-dump.systemNumber = 130;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
|
54
hosts/mobile-box/configuration.nix
Normal file
54
hosts/mobile-box/configuration.nix
Normal file
|
@ -0,0 +1,54 @@
|
|||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{ config, pkgs, inputs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
# Enabled modules
|
||||
../../modules/base.nix
|
||||
];
|
||||
|
||||
boot.tmpOnTmpfs = true;
|
||||
|
||||
hardware.hackrf.enable = true;
|
||||
|
||||
networking.hostName = "mobile-box"; # Define your hostname.
|
||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Berlin";
|
||||
|
||||
documentation.enable = false;
|
||||
|
||||
nix.gc = {
|
||||
automatic = true;
|
||||
dates = "daily";
|
||||
};
|
||||
|
||||
services.journald.extraConfig = ''
|
||||
SystemMaxUse=5M
|
||||
'';
|
||||
|
||||
# Configure network proxy if necessary
|
||||
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
||||
|
||||
|
||||
# Open ports in the firewall.
|
||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||
# Or disable the firewall altogether.
|
||||
# networking.firewall.enable = false;
|
||||
|
||||
# This value determines the NixOS release from which the default
|
||||
# settings for stateful data, like file locations and database versions
|
||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "21.11"; # Did you read the comment?
|
||||
|
||||
}
|
36
hosts/mobile-box/hardware-configuration.nix
Normal file
36
hosts/mobile-box/hardware-configuration.nix
Normal file
|
@ -0,0 +1,36 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "usbhid" "usb_storage" "sd_mod" "sdhci_pci" "sdhci_acpi" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{
|
||||
device = "/dev/disk/by-label/nixos";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{
|
||||
device = "/dev/disk/by-label/boot";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{
|
||||
device = "/dev/mmcblk0p1";
|
||||
}
|
||||
];
|
||||
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
|
@ -6,7 +6,7 @@
|
|||
virtualHosts = {
|
||||
"files.dvb.solutions" = {
|
||||
enableACME = true;
|
||||
enableSSL = true;
|
||||
onlySSL = true;
|
||||
root = "/var/lib/data-accumulator/";
|
||||
extraConfig = ''
|
||||
autoindex on;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{pkgs, config, lib}:
|
||||
{pkgs, config, lib, ...}:
|
||||
let
|
||||
file = ../configs/mobile_box.json;
|
||||
in
|
||||
|
@ -34,6 +34,7 @@ in
|
|||
StartLimitIntervalSec = "150s";
|
||||
};
|
||||
};
|
||||
|
||||
"data-accumulator" = {
|
||||
enable = true;
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
|
@ -52,6 +53,7 @@ in
|
|||
Restart = "always";
|
||||
};
|
||||
};
|
||||
|
||||
"start-wifi-hotspot" = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
|
|
Loading…
Reference in New Issue
Block a user