mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-12 04:35:41 +03:00
nixos/users: require one of users.users.name.{isSystemUser,isNormalUser}
As the only consequence of isSystemUser is that if the uid is null then it's allocated below 500, if a user has uid = something below 500 then we don't require isSystemUser to be set. Motivation: https://github.com/NixOS/nixpkgs/issues/112647
This commit is contained in:
parent
311ceed827
commit
7a87973b4c
23 changed files with 80 additions and 32 deletions
|
@ -9,8 +9,8 @@ import ./../make-test-python.nix ({ pkgs, ...} : {
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
users.users.testuser = { };
|
||||
users.users.testuser2 = { };
|
||||
users.users.testuser = { isSystemUser = true; };
|
||||
users.users.testuser2 = { isSystemUser = true; };
|
||||
services.mysql.enable = true;
|
||||
services.mysql.initialDatabases = [
|
||||
{ name = "testdb3"; schema = ./testdb.sql; }
|
||||
|
@ -44,8 +44,8 @@ import ./../make-test-python.nix ({ pkgs, ...} : {
|
|||
# Kernel panic - not syncing: Out of memory: compulsory panic_on_oom is enabled
|
||||
virtualisation.memorySize = 1024;
|
||||
|
||||
users.users.testuser = { };
|
||||
users.users.testuser2 = { };
|
||||
users.users.testuser = { isSystemUser = true; };
|
||||
users.users.testuser2 = { isSystemUser = true; };
|
||||
services.mysql.enable = true;
|
||||
services.mysql.initialDatabases = [
|
||||
{ name = "testdb3"; schema = ./testdb.sql; }
|
||||
|
@ -75,8 +75,8 @@ import ./../make-test-python.nix ({ pkgs, ...} : {
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
users.users.testuser = { };
|
||||
users.users.testuser2 = { };
|
||||
users.users.testuser = { isSystemUser = true; };
|
||||
users.users.testuser2 = { isSystemUser = true; };
|
||||
services.mysql.enable = true;
|
||||
services.mysql.initialScript = pkgs.writeText "mariadb-init.sql" ''
|
||||
ALTER USER root@localhost IDENTIFIED WITH unix_socket;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue