summaryrefslogtreecommitdiff
path: root/nixos-iso/zoom-iso.nix
blob: 74b1e8d3ed06edbeb66caf65b7abae04f9b826b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# This generates a NixOS-based ISO image for use in situations
# when a zoom-based meeting is unavoidable.
#
# Build it with:
#   nix-build zoom-iso.nix
# Then use `dd` or similar to push it onto a usb flash drive and
# boot from it (assumes a x86-64 system).
#
# It uses the gnome shell, since I'm familiar with it and zoom
# likes throwing lots of windows around that irritate most tiling
# window managers I've tried.

{pkgPath ? <nixpkgs>, ...}:

let
  config = { config, lib, pkgs, ... }: {
    imports = [
      ("${pkgPath}/nixos/modules/installer/cd-dvd/installation-cd-graphical-gnome.nix")
    ];

    environment.systemPackages = with pkgs; [
      # as fallback for the zoom app
      chromium
      # the zoom app
      zoom-us
      # for censoring screenshots of meetings when
      # screensharing doesn't work.
      gimp
      # generally useful utilities if things break
      inetutils
      dnsutils
      htop iftop
      # useful if gnome is weird
      gnome3.gnome-tweaks
    ];

    # Select internationalisation properties.
    i18n.defaultLocale = "de_DE.UTF-8";
    console = {
      font = "Lat2-Terminus16";
      keyMap = "de";
    };

    time.timeZone = "Europe/Prague";

    # necessary for zoom
    nixpkgs.config.allowUnfree = true;

  };
  nixlib = import ("${pkgPath}/nixos/default.nix") {
    configuration = config;
  };
in nixlib.config.system.build.isoImage