Skip to content

Instantly share code, notes, and snippets.

@pinkisemils
Created March 2, 2021 14:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pinkisemils/b616f4f3b7d42919e3b2f82cd9c5eff0 to your computer and use it in GitHub Desktop.
Save pinkisemils/b616f4f3b7d42919e3b2f82cd9c5eff0 to your computer and use it in GitHub Desktop.
{ config, pkgs, ... }:
{
imports =
[
<nixpkgs/nixos/modules/profiles/qemu-guest.nix>
<nixpkgs/nixos/modules/profiles/headless.nix>
];
boot.growPartition = true;
boot.kernelParams = [ "console=ttyS0" ];
boot.loader.grub.device = "/dev/vda";
boot.loader.timeout = 0;
fileSystems."/" = {
device = "/dev/disk/by-label/nixos";
fsType = "ext4";
autoResize = true;
};
networking.hostName = "mvd-nixos-test-vm";
time.timeZone = "Europe/London";
networking.useDHCP = true;
networking.firewall.enable = false;
environment.systemPackages = [ pkgs.vim ];
users.users.root = {
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAi4sGU65izdN3gTbLAEizwpvzaxfu10Bx/XtEHd6yy9 openpgp:0xA608175B"
];
};
services.sshd.enable = true;
services.mullvad-vpn.enable = true;
services.dnscache.enable = false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment