Skip to content

nealfennimore/secure-nix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Secure Baseline NixOS

This is an opinionated secure base config for your nixos system.

Features

Hardening Score

With Lynis and this base config, the machine has a hardening score of 79/100.

System Requirements

Suggested 3GB of memory when using ClamAV, otherwise disable like so:

  services.clamav = {
    daemon.enable = false;
    updater.enable = false;
  };

Usage

Flake Import

{
  description = "Your Flake";

  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";

    secure-nix = {
      url = "github:nealfennimore/secure-nix";
      inputs.nixpkgs.follows = "nixpkgs";
    };
  };

  outputs = { self, nixpkgs, secure-nix }: {

    nixosConfigurations = {
      my_system = nixpkgs.lib.nixosSystem {
        system = "x86_64-linux";
        modules = secure-nix.modules ++ [
            ./configuration.nix
        ];
      };
    };
  };
}

Releases

No releases published

Packages

No packages published

Languages