|
@@ -2,48 +2,20 @@
|
2
|
2
|
|
3
|
3
|
{
|
4
|
4
|
imports =
|
5
|
|
- [ <nixpkgs/nixos/modules/profiles/minimal.nix>
|
|
5
|
+ [ ../../../lib/lxc-container.nix
|
|
6
|
+ ../../../lib/shared.nix
|
6
|
7
|
];
|
7
|
|
- nix.useSandbox = false;
|
8
|
|
- nix.maxJobs = lib.mkDefault 2;
|
9
|
|
- nix.buildCores = lib.mkDefault 16;
|
10
|
|
-
|
11
|
|
- boot.isContainer = true;
|
12
|
|
- # /sbin/init
|
13
|
|
- boot.loader.initScript.enable = true;
|
14
|
|
- boot.loader.grub.enable = false;
|
15
|
|
-
|
16
|
|
- fileSystems."/" = { fsType = "rootfs"; device = "rootfs"; };
|
17
|
8
|
|
18
|
9
|
networking.hostName = "grafana";
|
19
|
10
|
networking.useNetworkd = true;
|
20
|
11
|
networking.defaultGateway = "172.22.99.4";
|
21
|
12
|
|
22
|
|
- # Set your time zone.
|
23
|
|
- time.timeZone = "Europe/Berlin";
|
24
|
|
- # Select internationalisation properties.
|
25
|
|
- i18n = {
|
26
|
|
- defaultLocale = "en_US.UTF-8";
|
27
|
|
- supportedLocales = lib.mkForce [ "en_US.UTF-8/UTF-8" ];
|
28
|
|
- };
|
29
|
|
-
|
30
|
13
|
# List packages installed in system profile. To search, run:
|
31
|
14
|
# $ nix search wget
|
32
|
15
|
environment.systemPackages = with pkgs; [
|
33
|
16
|
vim
|
34
|
17
|
];
|
35
|
18
|
|
36
|
|
- # Create a few files early before packing tarball for Proxmox
|
37
|
|
- # architecture/OS detection.
|
38
|
|
- system.extraSystemBuilderCmds =
|
39
|
|
- ''
|
40
|
|
- mkdir -m 0755 -p $out/bin
|
41
|
|
- ln -s ${pkgs.bash}/bin/bash $out/bin/sh
|
42
|
|
- mkdir -m 0755 -p $out/sbin
|
43
|
|
- ln -s ../init $out/sbin/init
|
44
|
|
- '';
|
45
|
|
-
|
46
|
|
-
|
47
|
19
|
# http https
|
48
|
20
|
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
49
|
21
|
# collectd
|