To develop dotmesh on NixOS, use a configuration that enables ZFS, sets a specific hostId, and installs the required system packages. You must also configure the Docker storage driver to overlay2 and allow insecure registries for your local hostname.
Required System Configuration:
boot.supportedFilesystems = [ "zfs" ];networking.hostId = "cafecafe"; (or a random one)virtualisation.docker.storageDriver = "overlay2";virtualisation.docker.extraOptions = "--insecure-registry ${config.networking.hostName}.local:80";boot.kernel.sysctl."vm.max_map_count" = 262144; (required for elasticsearch)
Required Packages:
wget, vim, docker, docker_compose, universal-ctags, mtr, go, jq, tmux, tmate, gnumake, git, moreutils.
boot.supportedFilesystems = [ "zfs" ];
networking.hostId = "cafecafe"; # Make a random one.
networking.hostName = "devmachine"; # Define your hostname.
networking.extraHosts = "127.0.0.1 ${config.networking.hostName}.local";
#nixpkgs.config.allowUnfree = true;
environment.systemPackages = with pkgs; [
# chromium
# slack
wget
vim
docker
docker_compose
universal-ctags
mtr
go
jq
tmux
tmate
gnumake
git
moreutils
];
boot.kernel.sysctl."vm.max_map_count" = 262144; # for elasticsearch
virtualisation.docker = {
enable = true;
storageDriver = "overlay2";
extraOptions = "--insecure-registry ${config.networking.hostName}.local:80";
};
system.activationScripts.binbash = {
text = "ln -sf /run/current-system/sw/bin/bash /bin/bash";
deps = [];
};
networking.firewall.enable = false;
Then apply the configuration:
sudo nixos-rebuild switch