Commit Graph

373 Commits

Author SHA1 Message Date
figsoda
6bb0dbf91f nixos: fix typos 2022-12-17 19:31:14 -05:00
Daniel Nagy
ad866e565d
treewide: switch to port type for nixos modules 2022-12-08 00:00:00 +01:00
Daniel Nagy
b4674b39c1
treewide: use mkEnableOption in nixos modules 2022-11-10 09:30:00 +01:00
Sandro
432e5e65a9
Merge pull request #197104 from Luflosi/kubo-RFC42 2022-10-27 23:48:33 +02:00
KFears
9f963f36e5 nixos/grafana: refactor settings for RFC42 2022-10-22 23:56:14 +04:00
Luflosi
a255c43f44
nixos/kubo: convert to RFC42-style settings 2022-10-21 20:54:00 +02:00
Luflosi
eefaaf41d6
kubo: rename from ipfs
Go-IPFS was renamed to Kubo in version 0.14.0, see https://github.com/ipfs/kubo/issues/8959.
2022-10-02 16:00:22 +02:00
pennae
f2ea09ecbe nixos/*: convert options with listings
minor rendering changes.
2022-08-31 17:27:36 +02:00
pennae
722b99bc0e nixos/*: convert options with admonitions to MD
rendering changes only slightly, most changes are in spacing.
2022-08-31 16:36:16 +02:00
pennae
ef176dcf7e nixos/*: automatically convert option descriptions
conversions were done using https://github.com/pennae/nix-doc-munge
using (probably) rev f34e145 running

    nix-doc-munge nixos/**/*.nix
    nix-doc-munge --import nixos/**/*.nix

the tool ensures that only changes that could affect the generated
manual *but don't* are committed, other changes require manual review
and are discarded.
2022-08-31 16:32:53 +02:00
pennae
6039648c50 nixos/*: automatically convert option docs 2022-08-19 22:40:58 +02:00
pennae
7e7d68a250 nixos/*: mark pre-existing markdown descriptions as mdDoc 2022-08-19 22:40:58 +02:00
pennae
b51f8036c2 nixos/*: use properly indented strings for option docs
using regular strings works well for docbook because docbook is not as
whitespace-sensitive as markdown. markdown would render all of these as
code blocks when given the chance.
2022-08-19 22:40:58 +02:00
pennae
087472b1e5 nixos/*: automatically convert option docs 2022-08-06 20:39:12 +02:00
pennae
423545fe48 nixos/*: normalize manpage references to single-line form
now nix-doc-munge will not introduce whitespace changes when it replaces
manpage references with the MD equivalent.

no change to the manpage, changes to the HTML manual are whitespace only.
2022-08-05 18:34:50 +02:00
pennae
2e751c0772 treewide: automatically md-convert option descriptions
the conversion procedure is simple:

 - find all things that look like options, ie calls to either `mkOption`
   or `lib.mkOption` that take an attrset. remember the attrset as the
   option
 - for all options, find a `description` attribute who's value is not a
   call to `mdDoc` or `lib.mdDoc`
 - textually convert the entire value of the attribute to MD with a few
   simple regexes (the set from mdize-module.sh)
 - if the change produced a change in the manual output, discard
 - if the change kept the manual unchanged, add some text to the
   description to make sure we've actually found an option. if the
   manual changes this time, keep the converted description

this procedure converts 80% of nixos options to markdown. around 2000
options remain to be inspected, but most of those fail the "does not
change the manual output check": currently the MD conversion process
does not faithfully convert docbook tags like <code> and <package>, so
any option using such tags will not be converted at all.
2022-07-30 15:16:34 +02:00
Sandro
f7f8721b1e
Merge pull request #162689 from astro/glusterfs
nixos/glusterfs: exclude hook "S10selinux-label-brick.sh"
2022-07-21 22:15:00 +02:00
Artturi
3cff3f75b4
Merge pull request #166340 from max-privatevoid/patch-6 2022-06-28 19:55:10 +03:00
Max
2a8bf9777d nixos/ipfs: do not leak config to journal on startup
The preStart script for the IPFS service will print parts of the configuration
to stdout (and therefore, the journal) when applying profiles on startup. This
may lead to unwanted disclosure of private information, such as remote pinning
service API keys. Fix by sending stdout to /dev/null.
2022-06-17 23:41:27 +02:00
Max
72d6d73e37 nixos/ipfs: Only set ReadWritePaths when hardened
Co-authored-by: Luflosi <Luflosi@users.noreply.github.com>
2022-04-16 20:48:28 +02:00
Luflosi
faad370edc nixos/ipfs: fix the services.ipfs.autoMigrate option
Apparently this was never properly tested and never worked. When the IPFS repo needs upgrading, the first call to ipfs, which is run before running the migration, fails with the error message "Error: ipfs repo needs migration".
To fix this, simply run the migration before any `ipfs config` calls but don't run it when `dataDir` is empty and we need to call `ipfs init`.
Writing a NixOS test for this would require keeping at least two versions of IPFS in Nixpkgs, which we don't currently do.
2022-04-16 07:38:13 -04:00
Luflosi
8a5e51525d nixos/ipfs: add Luflosi as maintainer 2022-04-16 07:38:13 -04:00
Luflosi
6b2eca8d56 nixos/ipfs: remove unused code
This code became obsolete with 4044d81d5c, just a couple days after it was introduced.
2022-04-16 07:38:13 -04:00
Robert Hensing
39e0bd705b
Merge pull request #165259 from Luflosi/ipfs-recursiveUpdate
nixos/ipfs: use lib.recursiveUpdate instead of // operator
2022-04-05 19:16:39 +02:00
Luflosi
ec415055ba nixos/ipfs: improve how the commandline flags are generated
Use `utils.escapeSystemdExecArgs` instead of relying on the exact way in which `toString` formats a list.
In https://github.com/NixOS/nixpkgs/pull/156706#discussion_r795867283 a suggestion was made and then implemented to replace `toString` with `concatStringsSep " "`.
@pennae then suggested to use `utils.escapeSystemdExecArgs` instead in https://github.com/NixOS/nixpkgs/pull/164846#issuecomment-1073001848.
2022-03-24 20:42:07 +00:00
Luflosi
38f1576ba9
nixos/ipfs: use lib.recursiveUpdate instead of // operator
Use `recursiveUpdate` instead of the // operator, as recommended in https://nix.dev/anti-patterns/language#attr1-attr2-merge-operator. Without this change, setting `services.ipfs.extraConfig.Addresses.NoAnnounce` for example will cause `services.ipfs.apiAddress`, `services.ipfs.gatewayAddress` and `services.ipfs.swarmAddress` to be ignored.
2022-03-22 13:01:35 +01:00
Luflosi
41d45d674a
nixos/ipfs: add systemd hardening
Use the hardened systemd unit from upstream.
2022-03-22 11:12:14 +01:00
Pascal Bach
4c3c80df54
Merge pull request #114393 from DarkDNA/feature/samba/network-online
nixos/samba: Add a wants=network-online.target to the target.
2022-03-21 19:25:50 +01:00
Astro
06ea5e780b nixos/glusterfs: exclude hook "S10selinux-label-brick.sh"
fails due to missing selinux binaries
2022-03-06 21:09:05 +01:00
Luflosi
0eb1d070c8 ipfs-migrator: 1.7.1 -> 2.0.2
https://github.com/ipfs/fs-repo-migrations/releases/tag/v2.0.2

This is pretty much a complete rewrite of the ipfs-migrator package.
In version 2.0.0 a major change was made to the way the migrator works. Before, there was one binary that contained every migration. Now every migration has its own binary. If fs-repo-migrations can't find a required binary in the PATH, it will download it off the internet. To prevent that, build every migration individually, symlink them all into one package and then wrap fs-repo-migrations so it finds the package with all the migrations.
The change to the IPFS NixOS module and the IPFS package is needed because without explicitly specifying a repo version to migrate to, fs-repo-migrations will query the internet to find the latest version. This fails in the sandbox, for example when testing the ipfs passthru tests.
While it may seem like the repoVersion and IPFS version are in sync and the code could be simplified, this is not the case. See https://github.com/ipfs/fs-repo-migrations#when-should-i-migrate for a table with the IPFS versions and corresponding repo versions.
Go 1.17 breaks the migrations, so use Go 1.16 instead. This is also the Go version used in their CI, see 3dc218e300/.github/workflows/test.yml (L4). See https://github.com/ipfs/fs-repo-migrations/pull/140#issuecomment-982715907 for a previous mention of this issue. The issue manifests itself when doing anything with a migration, for example `fs-repo-11-to-12 --help`:
```
panic: qtls.ClientHelloInfo doesn't match

goroutine 1 [running]:
github.com/marten-seemann/qtls-go1-15.init.0()
	github.com/marten-seemann/qtls-go1-15@v0.1.1/unsafe.go:20 +0x132
```
Also add myself as a maintainer for this package.
This fixes the test failure discovered in https://github.com/NixOS/nixpkgs/pull/160914.
See https://github.com/ipfs/fs-repo-migrations/issues/148 to read some of my struggles with updating this package.
2022-02-25 11:12:19 -08:00
Jonathan Ringer
39669ea2b6
Merge remote-tracking branch 'origin/master' into staging-next
Conflicts:
	pkgs/top-level/aliases.nix
2022-02-09 19:58:40 -08:00
Jörg Thalheim
30d7dbc2be
nixos/rsyncd: fix module eval 2022-02-09 08:21:00 +01:00
github-actions[bot]
4e2cf99754
Merge master into staging-next 2022-02-07 12:01:12 +00:00
markuskowa
768dd74738
Merge pull request #140891 from markuskowa/os-moosefs
nixos: init moosefs module and test
2022-02-07 10:48:33 +01:00
Jonathan Ringer
46fd0afcb3
Merge remote-tracking branch 'origin/master' into staging-next
Conflicts:
	pkgs/development/python-modules/pysdl2/default.nix
	pkgs/top-level/aliases.nix
2022-02-06 18:36:59 -08:00
Kevin Cox
c2038731e4
Merge pull request #158348 from schnusch/ipfs
nixos/ipfs: use ipfs config replace
2022-02-06 18:11:36 -05:00
schnusch
97f809dc87 nixos/ipfs: use ipfs config replace 2022-02-06 21:42:56 +01:00
Markus Kowalewski
d86fef1a57
nixos/doc: add moosefs module to release notes 2022-02-03 12:33:44 +01:00
Markus Kowalewski
b302bda010
nixos: init moosefs module 2022-02-03 12:31:31 +01:00
Sandro Jäckel
b20ad47fa3 nixos/ceph: mime-types -> mailcap 2022-01-26 14:30:10 -08:00
Pascal Bach
e6217908a3 nixos/glusterfs: remove syslog.target from services 2021-12-11 22:43:02 +01:00
spacefrogg
fe44db8271
openafsServer: remove dependency on syslog.target (#150294)
syslog.target has been deprecated and removed
2021-12-11 14:46:23 -05:00
Robert Hensing
862d167f17
Merge pull request #147441 from pennae/option-doc-staticizing
nixos/*: add trivial defaultText to options where applicable
2021-12-06 01:35:38 +01:00
pennae
2512455639 nixos/*: add trivial defaultText for options with simple defaults 2021-12-02 22:35:04 +01:00
Ryan Mulligan
aa37441c3e nixos/drbd: fix
- fix environment.etc."drbd.conf"
- don't generate an ExecStart script for just one command
2021-11-30 21:43:51 +01:00
Peng Mei Yu
4abccb5466 nixos/webdav: set uid and gid 2021-11-30 10:19:14 +08:00
Peng Mei Yu
ce4ad53e6a nixos/webdav-server-rs: init 2021-11-30 10:19:14 +08:00
Peng Mei Yu
640e54cda9 maintainers: Rename pengmeiyu to pmy 2021-11-29 18:39:31 +08:00
Peng Mei Yu
5609f84d1b nixos/webdav: init 2021-11-08 23:56:27 +08:00
Michael Hoang
43d2eefea6 nixos/samba: Add openFirewall option 2021-10-19 19:11:02 +11:00
Naïm Favier
2ddc335e6f
nixos/doc: clean up defaults and examples 2021-10-04 12:47:20 +02:00
Guillaume Girol
3592034595
Merge pull request #133166 from symphorien/nonogroup
Don't default to nogroup for the primary group of users.
2021-09-13 18:29:21 +00:00
Guillaume Girol
bc3bca822a nixos: define the primary group of users where needed 2021-09-12 14:59:30 +02:00
Kevin Cox
a49a3d97ac
Merge pull request #137113 from kevincox/ipfs-profile-fix
nixos.ipfs: Fix startup after unclean shutdown.
2021-09-10 08:26:04 -04:00
happysalada
6a51087bba ipfs: default to not listen on the local network 2021-09-10 09:39:55 +09:00
Kevin Cox
af354d2049
nixos.ipfs: Fix startup after unclean shutdown.
Fixes https://github.com/NixOS/nixpkgs/issues/135684
2021-09-08 12:17:22 -04:00
Kevin Cox
3106d032f7
Merge pull request #136261 from happysalada/ipfs_auto_migrations
Ipfs auto migrations
2021-08-31 09:33:20 -04:00
happysalada
8bce3034fd ipfs: add autoMigrate option 2021-08-31 22:22:36 +09:00
happysalada
4502d6386e ipfs: nixpkgs-fmt 2021-08-31 12:55:31 +09:00
happysalada
977ac07fed ipfs: increase UDP buffer size 2021-08-31 09:50:59 +09:00
happysalada
54dbdcbcbb ipfs: nixpkgs-fmt 2021-08-31 09:50:59 +09:00
Max
8f36abb528
nixos/ipfs: run profile applications offline 2021-08-30 01:00:44 +02:00
Jarosław Wygoda
1dcfd1e329 nixos/litestream: init 2021-07-30 17:41:54 +02:00
Luflosi
2b02b34029
nixos/ipfs: replace deprecated command line option
According to https://docs.ipfs.io/reference/cli/#ipfs the --local command line option is deprecated and should be replaced with --offline.
2021-06-30 17:32:38 +02:00
Florian Klink
ea4e8724f8
Merge pull request #122455 from ju1m/davfs2
nixos/davfs2: wrap {,u}mount.davfs with setuid=true
2021-06-08 16:22:06 +02:00
Emery Hemingway
520b4a8496 nixos: convert netatalk to settings-style configuration
Also, set StateDirectory in systemd.….serviceConfig.
2021-05-20 17:39:28 +02:00
Izorkin
feebe402f5
treewide: remove duplicates SystemCallFilters 2021-05-13 15:44:56 +03:00
Julien Moutinho
7e794a1da2 nixos/davfs2: wrap {,u}mount.davfs with setuid=true 2021-05-10 15:54:52 +02:00
Luflosi
b32b56cd54
nixos/ipfs: remove separate ipfs-init systemd unit
There is no need for a separate unit. Simplify the NixOS module by adding the shell code to preStart of the main unit, where the other initialization code already is.
2021-04-22 21:13:05 +02:00
Luflosi
5ff547e729
nixos/ipfs: fix typo in comment
This typo was introduced in 4044d81d5c.
2021-04-21 21:49:48 +02:00
Emery Hemingway
32a5b44b8d nixos/samba: remove bad example for "securityType" option
Setting "security = share" causes silent failures.
2021-04-07 14:18:01 +02:00
Amanda Cameron
50df42f0f3 nixos/samba: Add a wants=network-online.target to the target.
The linked units are all wants=network-online.target and I suspect an issue I've had
where nmbd was only announcing on a 169.x.x.x address is caused by this.
2021-02-25 14:09:32 -05:00
Leonard Pollak
a9a100adf6 nixos/ceph: fix ceph.client.extraOptions type 2021-02-15 14:56:26 +01:00
Sandro
a0829b1df8
Merge pull request #111455 from helsinki-systems/yandex
nixos/yandex-disk: add types
2021-01-31 15:25:10 +01:00
Sandro
1c71af8fd7
Merge pull request #111454 from helsinki-systems/xtreemfs
nixos/xtreemfs: add types
2021-01-31 15:24:55 +01:00
Sandro
cc80d6d5d4
Merge pull request #111425 from helsinki-systems/openafs
nixos/openafs: add types
2021-01-31 15:05:21 +01:00
Fritz Otlinghaus
9489f3450c
nixos/xtreemfs: add types 2021-01-31 13:23:26 +01:00
Fritz Otlinghaus
3ecf072d9b
nixos/yandex-disk: add types 2021-01-31 13:10:20 +01:00
Fritz Otlinghaus
b0113ee268
nixos/openafs: add types 2021-01-31 11:56:52 +01:00
Fritz Otlinghaus
74cfc4d692
nixos/netatalk: add types 2021-01-31 11:31:24 +01:00
Emery Hemingway
f32d7e4e03 nixos: add services.rsyncd.socketActivated option
Define systemd-socket activation using the upstream configuration
files as a reference. The "rsyncd" systemd unit has been renamed
to "rsync" for consistency with upstream.
2021-01-28 11:22:31 +01:00
volth
bc0d605cf1 treewide: fix double quoted strings in meta.description
Signed-off-by: Ben Siraphob <bensiraphob@gmail.com>
2021-01-24 19:56:59 +07:00
Izorkin
299f93dfdc
nixos/samba-wsdd: fix starting 2020-12-17 20:52:30 +03:00
Graham Christensen
bc49a0815a
utillinux: rename to util-linux 2020-11-24 12:42:06 -05:00
Florian Klink
bbf3c9483b
Merge pull request #104520 from Izorkin/wsdd
wsdd: init at 0.6.2
2020-11-23 23:18:23 +01:00
Izorkin
03760ab82e
nixos/samba-wsdd: init service samba-wsdd 2020-11-23 13:26:00 +03:00
zowoq
dbbd289982 nixos/*: fix indentation 2020-11-23 08:42:51 +10:00
Michael Raitza
1f323ec2b4 openafs: remove 1.6; point to openafs_1_8 2020-11-17 21:31:59 +01:00
Fabián Heredia Montiel
acd3d3dd20 nixos/modules/services/network-filesystems/ipfs: refactor
Add `package` option to change the package used for the service.
2020-11-03 17:35:06 -06:00
lf-
b37bbca521 nixos/modules: fix systemd start rate-limits
These were broken since 2016:
f0367da7d1
since StartLimitIntervalSec got moved into [Unit] from [Service].
StartLimitBurst has also been moved accordingly, so let's fix that one
too.

NixOS systems have been producing logs such as:
/nix/store/wf98r55aszi1bkmln1lvdbp7znsfr70i-unit-caddy.service/caddy.service:31:
Unknown key name 'StartLimitIntervalSec' in section 'Service', ignoring.

I have also removed some unnecessary duplication in units disabling
rate limiting since setting either interval or burst to zero disables it
(ad16158c10/src/basic/ratelimit.c (L16))
2020-10-31 01:35:56 -07:00
Doron Behar
9544c6078e
Merge pull request #96672 from doronbehar/module/samba
nixos/samba: remove upstream deprecated syncPasswordsByPam option
2020-10-04 11:29:56 +03:00
Emery Hemingway
e7d0500cb3 nixos/rsyncd: convert module to an INI generator 2020-09-29 08:07:53 +02:00
Sebastian Zivota
b619f322d3 nixos/samba: install package when module is enabled 2020-09-11 15:28:01 +02:00
Vladimír Čunát
538e558f48
Revert "Merge #96844: nixos/nfsd: run rpc-statd as a normal user"
This reverts commit 42eebd7ade, reversing
changes made to b169bfc9e2.

This breaks nfs3.simple test and even current PR #97656 wouldn't fix it.
Therefore let's revert for now to unblock the channels.
2020-09-10 21:31:35 +02:00
Peter Hoeg
42eebd7ade
Merge pull request #96844 from peterhoeg/m/nfs
nixos/nfsd: run rpc-statd as a normal user
2020-09-09 09:10:46 +08:00
Peter Hoeg
d6264419f5 nixos/nfsd: run rpc-statd as a normal user 2020-09-07 18:04:03 +08:00
Peter Hoeg
5483b1e216
Merge pull request #97123 from peterhoeg/m/fscache
nixos/cachefilesd: don't set up manually
2020-09-06 10:23:32 +08:00
Peter Hoeg
6ef2152b5d nixos/cachefilesd: don't set up manually
Use our available infrastructure instead of manually handling setup.
2020-09-04 16:11:55 +08:00
Doron Behar
8cd4d59a32 nixos/samba: remove upstream deprecated syncPasswordsByPam option 2020-08-30 14:29:13 +03:00
Lassulus
e453860b8f
Merge pull request #86236 from ThibautMarty/fix-nullOr-types
treewide: fix modules options types where the default is null
2020-08-26 18:21:29 +02:00