Commit graph

19570 commits

Author SHA1 Message Date
Jörg Thalheim c2fca99f97
Revert "Merge branch 'master' into staging-next"
This reverts commit f19b7b03a0, reversing
changes made to 572a864d02.

Sorry. I pushed the wrong staging-next (the one that had my master
merged in). This was not intended.
2020-12-31 08:50:36 +01:00
Jörg Thalheim f19b7b03a0
Merge branch 'master' into staging-next 2020-12-31 07:31:38 +01:00
github-actions[bot] e75c8744cb
Merge master into staging-next 2020-12-30 18:40:45 +00:00
Kevin Cox 58f3c19b78
Merge pull request #107638 from thiagokokada/opentabletdriver-init
opentabletdriver: init at 0.4.2/add module
2020-12-30 09:18:26 -05:00
Thiago Kenji Okada 791ef2e848 nixos/hardware: add opentabletdriver module 2020-12-30 10:14:30 -03:00
Julien Moutinho 8866576300
nixos/tor: improve type-checking and hardening
Fixes #77395.
Fixes #82790.
2020-12-30 07:50:44 +01:00
Jörg Thalheim 1024571d35
nixos/nscd: start in early boot
Services that have dynamic users require nscd to resolve users
via pam_systemd. Those services might not even create
their own dynamic users itself i.e. iptables.
To make sure nscd is always started when this is happening we move
nscd to sysinit.target and make sure that it is always started before
starting/reloading/restarting any other service.
2020-12-30 07:50:34 +01:00
h0m1 330218e69a
stage-1: create temporary secrets directory in /tmp and not in cwd 2020-12-30 07:50:34 +01:00
Jörg Thalheim 4caaec36dd
amazon-ec2-utils: 0.5.1 -> 1.3 2020-12-30 07:50:33 +01:00
Jörg Thalheim 64a7e509d7
nixos/nix-daemon: fix unknown sandbox warnings 2020-12-30 07:50:32 +01:00
Jörg Thalheim f84f71e1e0
nixos/nginx: add streamConfig option 2020-12-30 07:50:31 +01:00
Jörg Thalheim f536901693
nixos/filesystems: don't allow mountpoints with trailing slash
They are semantically the same as the non-slash version and therefore
are potential source of duplicates.

Also fixes https://github.com/NixOS/nixpkgs/issues/78951
2020-12-30 07:50:31 +01:00
Jörg Thalheim 19bf53f143
nixos/filesystems: faster nonEmtpyStr check
regexes should be faster than nix functions
2020-12-30 07:50:30 +01:00
Jörg Thalheim b8a19ca2bc
nixos-rebuild: add --impure flag
There are two use case for this flag:

1. NixOS developer usually use a nixpkgs checkout for development.
Copying nixpkgs everytime when rebuilding NixOS is way to slow, even
with NVME disks.

2. Folks migrating from impure configuration in a sufficient complex
infrastructure need this flag to gradually migrate to NixOS flakes.
2020-12-30 07:50:30 +01:00
Jörg Thalheim e1e412215d
nixos-rebuild: document all nix flags 2020-12-30 07:50:30 +01:00
Jörg Thalheim 8420dc923e
homeassistant: support for python_script automation 2020-12-30 07:50:29 +01:00
Jörg Thalheim 9c6f9c4068
redis: fix redis service 2020-12-30 07:50:29 +01:00
Jörg Thalheim 8a6c765832
command-not-found: rewrite in Rust
- drops perl + libraries dependencies
2020-12-30 07:50:28 +01:00
Jörg Thalheim 55eaa55922
nixos/redis: set TimeoutStartSec/TimeoutStopSec 2020-12-30 07:50:28 +01:00
github-actions[bot] 056304189c
Merge master into staging-next 2020-12-30 06:22:20 +00:00
Anderson Torres dff06f0c25
Merge pull request #102973 from pacien/matrix-appservice-discord-v1.0.0
matrix-appservice-discord: 0.5.2 -> 1.0.0
2020-12-30 01:09:24 -03:00
Anderson Torres d7cf89800e
Merge pull request #105831 from pacien/nixos-msmtp-module
nixos/msmtp: add msmtp module
2020-12-30 01:08:32 -03:00
Anderson Torres b17e9cbb8f
Merge pull request #105706 from pacien/ssmtp-config-generator
nixos/ssmtp: fix configuration generator to accomodate ssmtp
2020-12-30 01:07:47 -03:00
github-actions[bot] 31fc475812
Merge master into staging-next 2020-12-30 00:53:01 +00:00
Matt Layher 071c02a4b2
nixos/corerad: use pkgs.formats.toml to generate TOML configuration
Signed-off-by: Matt Layher <mdlayher@gmail.com>
2020-12-29 17:47:01 -05:00
github-actions[bot] ff873c7c21
Merge master into staging-next 2020-12-29 18:40:52 +00:00
Lassulus 86102ebe5e
Merge pull request #107127 from qzle/nixos-container-extraVeth-fix
Fix: nixos-container does not always apply extraVeth ips
2020-12-29 19:19:46 +01:00
WilliButz 6739d17f34
Merge pull request #99180 from 0x4A6F/master-prometheus-service
nixos/prometheus: remote_{read,write} support
2020-12-29 16:08:29 +01:00
0x4A6F c53a0c16e4
nixos/prometheus: remote_{read,write}
- add [remote_write](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#remote_write) and [remote_read](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#remote_read) support

Co-authored-by: Yorick van Pelt <yorickvanpelt@gmail.com>
2020-12-29 14:48:57 +00:00
github-actions[bot] c86ce50258
Merge master into staging-next 2020-12-29 00:51:31 +00:00
Florian Klink 316862f72b
Merge pull request #102106 from tadfisher/throttled-msr-warning
nixos/throttled: disable kernel msr warning
2020-12-29 01:28:09 +01:00
Peter Hoeg 7d07645cba nixos/sddm: use attrs instead of plain text
Instead of treating the sddm config a wall of text that doesn't allow us
to override anything, turn it into an attribute set.

We dump `extraConfig` and instead introduce `settings` that is merged
with the module defaults to provide the final configuration.

There is some additional noise in here due to nixpkgs-fmt.
2020-12-29 05:06:38 +08:00
github-actions[bot] ac03278035
Merge master into staging-next 2020-12-28 18:34:55 +00:00
Ivan b90c5cb703
XMonad: configured recompile (#107696)
* nixos/xmonad: xmonad config w/ghc+xmessage

When the "config" option isn't set, we use xmonad-with-packages to
provide xmonad with runtime access to an isolated ghc, ensuring it can
recompile and exec a user's local config (e.g. $HOME/.xmonad/xmonad.hs)
regardless of which ghc (if any) is on PATH.

When the "config" option is set, however, we compile a configured xmonad
executable upfront (during nixos-rebuild), and prior to this commit, it
was not provided with runtime access to an isolated ghc.

As a result, with the "config" option set, it was not possible
to recompile and exec a user's local config unless there was a
compatible version of ghc on PATH with the necessary packages (xmonad,
xmonad-contrib, etc.) in its package database. Adding such a ghc to
environment.systemPackages, e.g.

  (haskellPackages.ghcWithPackages (ps: with ps; [xmonad xmonad-contrib]))

is problematic because it adds both ghc and an unconfigured xmonad to
PATH, e.g.

  $ ls -l $(which xmonad ghc)
  lrwxrwxrwx ... /run/current-system/sw/bin/ghc -> /nix/store/...-ghc-8.10.2-with-packages/bin/ghc
  lrwxrwxrwx ... /run/current-system/sw/bin/xmonad -> /nix/store/...-ghc-8.10.2-with-packages/bin/xmonad

Having the unconfigured xmonad on PATH is particularly bad because
restarting xmonad will dump the user into the unconfigured version, and
if no local config exists (e.g. in $HOME/.xmonad/xmonad.hs), they'll be
left in this unconfigured state.

In this commmit, we give the configured xmonad runtime access to ghc
like xmonad-with-packages does for the unconfigured version. The aim
is to allow the user to switch between the nixos module's config and a
local config (e.g. $HOME/.xmonad/xmonad.hs) at will, so they can try out
config changes without performing a nixos-rebuild.

Since the xmonad on PATH is the configured executable, there's no
danger a user could unwittingly restart into the unconfigured version,
and because xmonad will refuse to recompile when no local config
exists, there's no danger a user could unwittingly recompile into an
unconfigured version.

Given that a local config exists, the recompile/restart behavior depends
on two factors:
- which entry point is used
  * 'XMonad.xmonad' (default)
  * 'XMonad.launch' (recommended in "config" option description)
- what operation is triggered (i.e. via mod+q)
  * `spawn "xmonad --recompile && xmonad --restart"` (default)
  * `restart "xmonad" True`
  * custom function

If the default 'XMonad.xmonad' entrypoint and default mod+q operation
are used, hitting mod+q will compile and exec the local config, which
will remain in use until next time the display manager is restarted.

If the entrypoint is changed to 'XMonad.launch' but mod+q left with its
default operation, hitting mod+q will have no visible effect. The logs
(as seen by running `journalctl --identifier xmonad --follow`) will show
an error,
  X Error of failed request:  BadAccess (attempt to access private resource denied)
which indicates that the shell was unable to start xmonad because
another window manager is already running (namely, the nixos-configured
xmonad).
https://wiki.haskell.org/Xmonad/Frequently_asked_questions#X_Error_of_failed_request:_BadAccess_.28attempt_to_access_private_resource_denied.29

Changing the mod+q operation to `restart "xmonad" True` (as recommended
in the "config" option's description) will allow a restart of the
nixos-configured xmonad to be triggeredy by hitting mod+q.

Finally, if the entrypoint is 'XMonad.launch', mod+q has been
bound to `restart "xmonad" True` and another key bound to a custom
recompile/restart function (e.g. `compileRestart` as shown in the
"config" option example), the user can switch between the nixos module's
config and their local config, with the custom key switching to the
local config and mod+q switching back.

* nixos/xmonad: refactor let binding

* nixos/xmonad: refactor (eliminate duplicate code)

* nixos/xmonad: install man pages

Prior to this commit, man pages were not installed if the "config"
option was set.

* nixos/xmonad: comment grammar fixups

* nixos/xmonad: writeStateToFile in example config

Calling writeStateToFile prior to recompiling and restarting allows
state (workspaces, etc.) to be preserved across the restart.

* nixos/xmonad: add ivanbrennan to maintainers

* nixos/xmonad: adjust compileRestart example

* nixos/xmonad: add missing import to example config
2020-12-28 17:27:36 +01:00
github-actions[bot] d5506c4c59
Merge master into staging-next 2020-12-28 12:24:08 +00:00
Florian Klink f71e439688 nixos/acme: fix typo in docs 2020-12-28 13:19:15 +01:00
Frederik Rietdijk 92cc19490e Merge staging into staging-next 2020-12-28 08:45:43 +01:00
Aaron Andersen a08ed097c9
Merge pull request #107064 from aanderse/nixos/zabbixWeb
nixos/zabbixWeb: include DOUBLE_IEEE754 directive
2020-12-28 00:22:35 -05:00
Maximilian Bosch e5e7c9b0f9
nixos/tests/loki: satisfy linter
Apparently, the linter used for python test-scripts just decided that
a reformat of the testscript is now necessary.
2020-12-28 00:37:13 +01:00
Pavol Rusnak b0121fcb03 trezord: TREZOR -> Trezor 2020-12-27 19:48:09 +01:00
pacien ea842627ce nixos/matrix-appservice-discord: update module for v1.0.0 2020-12-27 12:59:11 +01:00
Anderson Torres 086946df11
Merge pull request #91203 from davidak/zsa
nixos/zsa: init at unstable-2020-12-16
2020-12-26 23:53:48 -03:00
Jeff Slight 4bc2573a15
nixos/gitlab: move custom_hooks_dir into gitaly config (#107174) 2020-12-26 22:44:36 +01:00
Bernardo Meurer c4c899d3ef
Merge pull request #107613 from davidak/bcachefs-sha256
bcachefs: add sha256 kernel module
2020-12-26 21:37:26 +00:00
github-actions[bot] d4a33d75f2
Merge staging-next into staging 2020-12-26 18:28:57 +00:00
davidak 0d0ff21f2f nixos/zsa: init at unstable-2020-12-16
add support for ZSA keyboards

Co-authored-by: Julien Debon <julien.debon@pm.me>
2020-12-26 09:56:34 +01:00
Daniel Nagy f2ca4c8f1d
nixos/httpd: set lua paths
We conditionally set the lua paths for the Apache mod_lua module. This
allows executing Lua script handlers to require modules, that have been
packaged with the supplied Lua derivation of Apache.

For more information, see:

  https://httpd.apache.org/docs/2.4/mod/mod_lua.html#luapackagecpath
  https://httpd.apache.org/docs/2.4/mod/mod_lua.html#luapackagepath
2020-12-25 22:54:05 +01:00
davidak d42e2cc24e bcachefs: add sha256 kernel module
needed to mount as root fs
2020-12-25 21:28:50 +01:00
github-actions[bot] 7659201d58
Merge staging-next into staging 2020-12-25 18:28:52 +00:00
Florian Klink c674a51382 nixos/systemd: provide libidn2 for systemd-resolved
systemd started using dlopen() for some of their "optional"
dependencies.

Apparently, `libidn2` isn't so optional, and systemd-resolved doesn't
work without libidn2 present, breaking DNS resolution.

Fixes https://github.com/NixOS/nixpkgs/issues/107537

Upstream bug: https://github.com/systemd/systemd/issues/18078
2020-12-25 13:45:25 +01:00