Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash
outputPaths=$(nix-build --no-out-link - <<'EOF'
let
pkgs = (import <nixpkgs> {});
# The book source
src = let
second-edition = fetchBook {
rev = "6354bb99d3834303693658890426a7ec6d4c104e";
@KoviRobi
KoviRobi / nixos-container.nix
Last active June 7, 2023 11:11
NixOS container example, for a web browser container. Use "sudo systemctl start container@browser" to start.
# vim: set softtabstop=2 tabstop=2 shiftwidth=2 expandtab autoindent syntax=nix nocompatible :
# Containers
{ config, pkgs, ... }:
{ containers.browser =
let hostAddr = "192.168.100.10";
in
{ privateNetwork = true;
hostAddress = hostAddr;