1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-17 19:21:04 +00:00
Commit graph

323 commits

Author SHA1 Message Date
Robert Hensing a034fb50f7 Format 2024-10-08 11:27:01 +02:00
Robert Hensing 00355648f0 nixos/modules/profiles/macos-builder.nix: Restore as alias 2024-10-08 10:27:11 +02:00
Robert Hensing 4687820524 Document nixos/modules/profiles/nix-builder-vm.nix 2024-10-08 10:27:11 +02:00
Robert Hensing 1d76033154 Rename nixos/modules/profiles/{macos-builder.nix -> nix-builder-vm.nix} 2024-10-08 10:27:11 +02:00
Robert Hensing 2d11924c9a
macos-builder: readd Nix CLI for debugging (#347205) 2024-10-08 09:58:17 +02:00
Michael Hoang 10bad16926 macos-builder: readd Nix CLI for debugging
See https://github.com/NixOS/nixpkgs/pull/268574#discussion_r1788966194
2024-10-08 12:41:55 +11:00
nicoo 6f26c88376
nixos/macos-builder: pin stateVersion (#342380)
Closes #325610, #325674
2024-10-04 16:09:56 +02:00
Artturin e0464e4788 treewide: replace stdenv.is with stdenv.hostPlatform.is
In preparation for the deprecation of `stdenv.isX`.

These shorthands are not conducive to cross-compilation because they
hide the platforms.

Darwin might get cross-compilation for which the continued usage of `stdenv.isDarwin` will get in the way

One example of why this is bad and especially affects compiler packages
https://www.github.com/NixOS/nixpkgs/pull/343059

There are too many files to go through manually but a treewide should
get users thinking when they see a `hostPlatform.isX` in a place where it
doesn't make sense.

```
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv.is" "stdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenv'.is" "stdenv'.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "clangStdenv.is" "clangStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "gccStdenv.is" "gccStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "stdenvNoCC.is" "stdenvNoCC.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "inherit (stdenv) is" "inherit (stdenv.hostPlatform) is"
fd --type f "\.nix" | xargs sd --fixed-strings "buildStdenv.is" "buildStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "effectiveStdenv.is" "effectiveStdenv.hostPlatform.is"
fd --type f "\.nix" | xargs sd --fixed-strings "originalStdenv.is" "originalStdenv.hostPlatform.is"
```
2024-09-25 00:04:37 +03:00
Geoffrey Thomas 82978a85c6 Revert "nixos/profiles/base: install vim w/nix-syntax plugin"
Adding custom plugins causes the `vim` command to be a wrapper script
running `vim -u ...`, which makes it not load the default ~/.vimrc.
(This is analogous to #177375 about neovim.)

As of Vim 9, the syntax-highlighting portion of the nix plugin is
upstream; the full plugin is only needed for indentation etc. (see also
e261eb152b). So, using regular pkgs.vim
works around this behavior/bug and causes any ~/.vimrc to get loaded,
without regressing the syntax highlighting support that motivated the
change being reverted here.

This reverts commit 0b5a0cbc69.
2024-09-22 15:16:39 -04:00
Sandro d7a90aab71
nixos/profiles/minimal: set fonts.enableDefaultPackages which was previously set by environment.noXLibs 2024-09-22 20:21:16 +02:00
Sandro da1b2b5adb
nixos/profiles/minimal: drop noXLibs
noXLibs is an advanced option for advanced users which know how to recognize and debug build failures which might be caused by the added overlays.

The minimal profile should be minimal but also save to use for many people and not cause build failures in packages it really shouldn't.
2024-09-14 00:59:14 +02:00
Martin Weinelt 4cec81a995
Revert "modules/virtualisation: add shared options, merge various diskSize options" (#340894)
Breaks evaluation of all nixos tests, and is therefore a channel blocker.
2024-09-10 03:12:55 +02:00
Jonas Chevalier 7c4dde339a
modules/virtualisation: add shared options, merge various diskSize options (#339535) 2024-09-09 21:23:11 +02:00
Emily 866a8e220c nixos/perlless: remove redundant system.switch.enableNg
This is now on by default.
2024-09-06 08:35:43 +01:00
Emily 7b9bb0a9a1 nixos/installer: drop support for ReiserFS and JFS
ReiserFS has not been actively maintained for many years. It has been
marked as obsolete since Linux 6.6, and is scheduled for removal
in 2025. A warning is logged informing users of this every time a
ReiserFS file system is mounted. It suffers from unfixable issues
like the year 2038 problem.

JFS is a slightly more ambiguous case. It also has not been actively
maintained for years; even in 2008 questions were being raised
about its maintenance state  and IBM’s commitment to it, and some
enterprise distributions were opting not to ship support for it as
a result. It will [indefinitely postpone journal writes], leading
to data loss over potentially arbitrary amounts of time. Kernel
developers [considered marking it as deprecated] last year, but
no concrete decision was made. There have been [occasional fixes]
to the code since then, but even the developer of much of those was
not opposed to deprecating it.

[considered marking it as deprecated]: https://lore.kernel.org/lkml/Y8DvK281ii6yPRcW@infradead.org/
[indefinitely postpone journal writes]: https://www.usenix.org/legacy/events/usenix05/tech/general/full_papers/prabhakaran/prabhakaran.pdf
[occasional fixes]: https://www.phoronix.com/news/JFS-Linux-6.7-Improvements

Regardless of whether JFS should be removed from the kernel, with all
the implications for existing installations that entails, I think
it’s safe to say that no new Linux installation should be using
either of these file systems, and that it’s a waste of space and
potential footgun to be shipping support for them on our standard
installation media. We’re lagging behind other distributions on
this decision; neither is supported by Fedora’s installation media.

(It also just so happens that `jfsutils` is the one remaining package
in the minimal installer ISO that has reproducibility issues, due to
some cursed toolchain bug, but I’m not trying to Goodhart’s law
this or anything. I just think we shouldn’t be shipping it anyway.)
2024-09-05 16:00:35 +01:00
phaer 94634e82f8 macos-builder: use virtualisation.diskSize...
...and drop virtualisation.darwin-builder.diskSize.

This makes negative diskSizes illegal.
2024-09-05 15:56:24 +02:00
phaer 04fadac429 run nixfmt-rfc-style 2024-09-05 15:56:22 +02:00
K900 644cf688b3 nixos/graphical: don't enable Pulseaudio 2024-09-04 13:56:42 +03:00
K900 878922a902 nixos/installation-device: use a bigger hammer
Untrimmed mbrola-voices is leaking into the installer images again.
Instead of trying to manually squash every path it could possibly
leak through, use a very big hammer.
2024-09-03 10:53:25 +03:00
WilliButz c169763c30
userborn: init at 0.1.0 (#332719) 2024-08-30 12:22:54 +02:00
Sandro Jäckel d50e23f0a4
glxinfo: replace with mesa-demos 2024-08-28 14:38:12 +02:00
nikstur aded1bccf2 nixos/profiles/perlless: systemd-sysusers -> userborn 2024-08-26 13:53:45 +02:00
nikstur 0b6c394f3a
Merge pull request #328513 from isabelroses/docs/perlless
nixos/perlless: correct documented warning
2024-08-22 11:50:08 +02:00
isabel 750663add9
nixos/perlless: correct documented warning 2024-08-21 20:11:48 +01:00
Sandro Jäckel 280e9a5ca4
nixos/nix: move trusted-user to config
This avoids having to define root when trying to add another user as
trusted user, similar to the other options.
2024-07-30 18:18:57 +02:00
Martin Weinelt 93f4195fe0
Merge remote-tracking branch 'origin/master' into staging-next
Conflicts:
- pkgs/applications/graphics/seamly2d/default.nix
2024-07-26 18:05:04 +02:00
K900 fd662230c4 nixos/installer: ship only one mbrola voice per language
This reduces the size of mbrola-voices by 387M (647M -> 260M) for all
installers that ship with speechd, to make sure that they fit the output
limits of hydra while not compromising too much on accessbility.

Co-authored-by: Martin Weinelt <hexa@darmstadt.ccc.de>
2024-07-26 16:12:55 +03:00
Sigmanificient 6dd44107ac treewide: remove unused lib (and other) arguments 2024-07-26 11:18:09 +02:00
Sandro fa5abfe559
Merge pull request #317623 from jmbaur/stc-ng-followup 2024-07-18 11:33:59 +02:00
Hugh O'Brien 66b896630d
profiles/qemu_guest: add virtio_gpu to initrd 2024-07-07 19:35:32 -04:00
Franz Pletz 440ea06e3b
Merge pull request #276507 from clefru/no-hwclock 2024-07-04 18:32:39 +02:00
Jared Baur 6f1f3c810d
nixos/perlless: fix perl showing up!
The install-grub script is perl, so the perlless profile should disable
it by default.
2024-06-21 23:27:58 -07:00
Jared Baur a7e1ea970b
nixos/perlless: enable switch-to-configuration-ng for perlless profile
The switch-to-configuration-ng program provides a perl-free way of
switching nixos systems, we can use it for the perlless profile.
2024-06-21 23:22:55 -07:00
Christian Kampka 8814c364a3 nixos/top-level: Rename system.forbiddenDependenciesRegex to system.forbiddenDependenciesRegexes
and turn it in to a list.

The current setting of system.forbiddenDependenciesRegex is a string, meaning only one such regex as any additional setting would result in conflicts.

As maintainers have already started using this setting eg. in profiles, it would be good if this setting would accept a list of regex to allow the end
user to make use of it in addition to package maintainers.
2024-05-02 21:08:39 +03:00
Sandro Jäckel cb8b6a5d00
treewide: reanme renamed libinput options 2024-04-17 23:34:07 +02:00
Julian Stecklina 1f97715767 profiles/graphical:rename services.xserver.displayManager 2024-04-16 13:42:29 +02:00
Julian Stecklina 92415267c6 profiles/demo: rename services.xserver.displayManager 2024-04-16 13:42:02 +02:00
stuebinm 6afb255d97 nixos: remove all uses of lib.mdDoc
these changes were generated with nixq 0.0.2, by running

  nixq ">> lib.mdDoc[remove] Argument[keep]" --batchmode nixos/**.nix
  nixq ">> mdDoc[remove] Argument[keep]" --batchmode nixos/**.nix
  nixq ">> Inherit >> mdDoc[remove]" --batchmode nixos/**.nix

two mentions of the mdDoc function remain in nixos/, both of which
are inside of comments.

Since lib.mdDoc is already defined as just id, this commit is a no-op as
far as Nix (and the built manual) is concerned.
2024-04-13 10:07:35 -07:00
Robert Hensing ecbeabd182
Merge pull request #293846 from amarshall/darwin-linux-builder-fail-on-error
darwin.linux-builder: Exit scripts on error
2024-03-25 12:20:58 +01:00
K900 5fbc094393 nixos/profile/all-hardware: remove simplefb
It's simpledrm now and it's compiled in.
2024-03-24 18:44:19 +03:00
Andrew Marshall 24ae983076 darwin.linux-builder: Exit scripts on error
For example, if the user decided to ctrl-c upon getting the sudo
password prompt, the script previously continued on to start the VM, but
that should not be the case.
2024-03-15 08:52:30 -04:00
Tamara Schmitz b80c3284d5
nixos/hardened: update hardened profile to new recommendations
Borrowing from here to match hardened profile with more recent kernels:
* https://madaidans-insecurities.github.io/guides/linux-hardening.html?#boot-parameters
* https://github.com/a13xp0p0v/kernel-hardening-checker/

Removed "slub_debug" as that option disables kernel memory address
hashing. You also see a big warning about this in the dmesg:
"This system shows unhashed kernel memory addresses via the console, logs, and other interfaces."

"init_on_alloc=1" and "init_on_free=1" zeroes all SLAB and SLUB allocations. Introduced in 6471384af2a6530696fc0203bafe4de41a23c9ef. Also the default for the Android Google kernel btw. It is on by default through the KConfig.

"slab_nomerge" prevents the merging of slab/slub caches. These are
effectively slab/slub pools.

"LEGACY_VSYSCALL_NONE" disables the older vsyscall mechanic that relies on
static address. It got superseeded by vdsos a decade ago. Read some
LWN.net to learn more ;)

"debugfs=off" I'm sure there are some few userspace programs that rely on
debugfs, but they shouldn't.

Most other things mentioned on the blog where already the default on a
running machine or may not be applicable.

Most other Kconfigs changes come from the kernel hardening checker and
were added, when they were not applied to the kernel already.

Unsure about CONFIG_STATIC_USERMODEHELPER. Would need testing.
2024-01-27 20:43:58 +00:00
Ryan Lahfa 37832d237e
Merge pull request #283244 from bjornfor/nixos-add-polkit-to-installation-device
nixos/installation-device: enable polkit
2024-01-26 14:46:48 +01:00
Bjørn Forsman dadc54aabe nixos/installation-device: enable polkit
Polkit enables running 'reboot' and 'poweroff' in the installer without
being root, and non-root is the default login for a few NixOS releases
now.

There's no size increase in the minimal ISO:

  $ git checkout nixpkgs-unstable
  $ nix-build -A config.system.build.isoImage -I nixos-config=nixos/modules/installer/cd-dvd/installation-cd-minimal.nix nixos/default.nix && du -sc ./result/iso/*.iso
  /nix/store/bfvbvrrqjmnqqhyqyxc0w32gagdz2rya-nixos-24.05.git.1149dab64e7-x86_64-linux.iso
  998404  ./result/iso/nixos-24.05.git.1149dab64e7-x86_64-linux.iso
  998404  total

  $ git checkout THIS_COMMIT
  $ nix-build -A config.system.build.isoImage -I nixos-config=nixos/modules/installer/cd-dvd/installation-cd-minimal.nix nixos/default.nix && du -sc ./result/iso/*.iso
  /nix/store/l9x9rwlvfddnri70h1ifx865q0cvka5l-nixos-24.05.git.1149dab64e7-x86_64-linux.iso
  998404  ./result/iso/nixos-24.05.git.1149dab64e7-x86_64-linux.iso
  998404  total
2024-01-23 16:10:31 +01:00
nikstur 8710a27bc6 nixos/profiles/perlless: init 2024-01-22 00:54:13 +01:00
Linus Heckemann 5494aa21c7
Merge pull request #273308 from Stunkymonkey/install-device-fix-mdadm
nixos/installation-device: remove warning about mdadm
2023-12-25 23:41:10 +01:00
Clemens Fruhwirth 82d48bb4f9 qemu-guest: Remove hwclock workaround as it breaks xtime on VMs. 2023-12-24 14:21:13 +01:00
Jeff Huffman 0863f6d2da
nixos/stub-ld: init module 2023-12-11 05:47:23 -05:00
Felix Buehler 9537527389 nixos/installation-device: remove warning about mdadm 2023-12-10 13:06:25 +01:00
Atemu 6fc4c1c40c
Merge pull request #268574 from hercules-ci/linux-builder-no-eval
darwin.linux-builder: Disable evaluation
2023-11-28 17:31:08 +01:00