Compare commits

..

10 Commits

Author SHA1 Message Date
oysteikt 0fd41c214a flake.{nix,lock}: bump deps
Eval nix flake / evals (push) Successful in 4m7s
Build topology graph / evals (push) Successful in 6m27s
2026-05-13 01:19:35 +09:00
oysteikt 5c1ee958ea flake.{nix,lock}: bump roowho2
Build topology graph / evals (push) Successful in 2m34s
Eval nix flake / evals (push) Successful in 4m7s
2026-05-12 00:25:55 +09:00
oysteikt d8e97715c9 flake.lock: bump pvv-nettsiden 2026-05-12 00:24:56 +09:00
oysteikt 33297b0436 treewide: lib.cli.toGNUCommandLineShell -> lib.cli.toCommandLineShellGNU
Build topology graph / evals (push) Successful in 2m33s
Eval nix flake / evals (push) Successful in 4m7s
2026-05-11 23:09:50 +09:00
oysteikt be33c95c83 bekkalokk/website: more logging, specify timeouts, ban spooky funcs, fake sendmail
Build topology graph / evals (push) Successful in 2m33s
Eval nix flake / evals (push) Successful in 4m5s
2026-05-11 21:14:08 +09:00
oysteikt 2abf36a9af packages/simplesamlphp: 2.4.3 -> 2.5.0
Build topology graph / evals (push) Successful in 2m52s
Eval nix flake / evals (push) Successful in 4m1s
2026-05-11 16:12:15 +09:00
oysteikt a60be532ce packages/mediawiki-extensions: bump all 2026-05-11 16:11:10 +09:00
oysteikt 9c142fd56f kommode/gitea: remove deprecated config options
Build topology graph / evals (push) Successful in 2m34s
Eval nix flake / evals (push) Successful in 4m37s
2026-05-11 16:00:51 +09:00
oysteikt b98e8679e6 temmie/userweb: set same phpOptions for env and apache
Build topology graph / evals (push) Successful in 2m30s
Eval nix flake / evals (push) Successful in 4m3s
2026-05-11 14:54:56 +09:00
oysteikt ea092ec0b3 temmie/userweb: pass userdir user to sendmail through custom envvar
Build topology graph / evals (push) Successful in 2m49s
Eval nix flake / evals (push) Successful in 4m38s
2026-05-11 14:26:47 +09:00
10 changed files with 96 additions and 85 deletions
Generated
+20 -20
View File
@@ -232,11 +232,11 @@
]
},
"locked": {
"lastModified": 1777808420,
"narHash": "sha256-hh9XBz0K1ypZ+neezgIPCSsnWFKEq8VfV/1aUSPu3OA=",
"lastModified": 1778407980,
"narHash": "sha256-r980BhsReZQe6FkmyNZkwCZpvzARo5jZgTl8HxjAssY=",
"owner": "oddlama",
"repo": "nix-topology",
"rev": "28e9dc901ff38a8fa2d24bccd5f89511d6d8324e",
"rev": "ca0a602f650306d00d6f3e3c76d0f4c48a5c5adc",
"type": "github"
},
"original": {
@@ -248,11 +248,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1778125667,
"narHash": "sha256-swcxqlW+XrZFBqjcV3AV8AR64/eI234AZRFKs6q4DFo=",
"rev": "75636a69ad3115ff64d4cb3090e66c8275dda9c2",
"lastModified": 1778544512,
"narHash": "sha256-VIsPgfIpZ/01XUO6WN+o1NZbP5iKPKPHdHPWqfm4XIg=",
"rev": "c417517f9d525181ee5619c683419d308ee29fe8",
"type": "tarball",
"url": "https://releases.nixos.org/nixos/25.11-small/nixos-25.11.10534.75636a69ad31/nixexprs.tar.xz"
"url": "https://releases.nixos.org/nixos/25.11-small/nixos-25.11.10745.c417517f9d52/nixexprs.tar.xz"
},
"original": {
"type": "tarball",
@@ -276,11 +276,11 @@
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1778157832,
"narHash": "sha256-lSl05j1UzI5MioSJWUa7oUp5a88zzv3sXMwWC4d1N70=",
"rev": "ec299c6a33eee9baf5b4d72881ca2f15c06b4f01",
"lastModified": 1778586796,
"narHash": "sha256-XmDljcG4x8slQDlsWOc77pCA1YVuYn8JGumkYlhfTxI=",
"rev": "b25e938b89759b5f9466fc53c4a970244f84dc39",
"type": "tarball",
"url": "https://releases.nixos.org/nixos/unstable-small/nixos-26.05pre993859.ec299c6a33ee/nixexprs.tar.xz"
"url": "https://releases.nixos.org/nixos/unstable-small/nixos-26.05pre996582.b25e938b8975/nixexprs.tar.xz"
},
"original": {
"type": "tarball",
@@ -315,11 +315,11 @@
]
},
"locked": {
"lastModified": 1769009806,
"narHash": "sha256-52xTtAOc9B+MBRMRZ8HI6ybNsRLMlHHLh+qwAbaJjRY=",
"lastModified": 1778506874,
"narHash": "sha256-s6ihgpgvaCDQsQQNfqNEDvh/oVHmrOhX1dDRsrA3qyI=",
"ref": "main",
"rev": "aa8adfc6a4d5b6222752e2d15d4a6d3b3b85252e",
"revCount": 575,
"rev": "07d132575a9aeb4939c70d40e1b7e493c40427fa",
"revCount": 580,
"type": "git",
"url": "https://git.pvv.ntnu.no/Projects/nettsiden.git"
},
@@ -380,17 +380,17 @@
"rust-overlay": "rust-overlay_3"
},
"locked": {
"lastModified": 1777418851,
"narHash": "sha256-M6LntO3jkxwgcKkaa9de1Vqu+LsV12Yz8Bv3/9/k018=",
"lastModified": 1778600367,
"narHash": "sha256-YB0b2xUf4D8792D5Ay//7C3AjHyv+9yoy8K1mTe+wvE=",
"ref": "main",
"rev": "16b2bc5c2759e20ecb952374509f1e1f9d6c06e7",
"revCount": 83,
"rev": "8e5f2849ff7c9616100fe928261512a7ad647939",
"revCount": 91,
"type": "git",
"url": "https://git.pvv.ntnu.no/Projects/roowho2.git"
},
"original": {
"ref": "main",
"rev": "16b2bc5c2759e20ecb952374509f1e1f9d6c06e7",
"rev": "8e5f2849ff7c9616100fe928261512a7ad647939",
"type": "git",
"url": "https://git.pvv.ntnu.no/Projects/roowho2.git"
}
+1 -1
View File
@@ -32,7 +32,7 @@
minecraft-heatmap.url = "git+https://git.pvv.ntnu.no/Projects/minecraft-heatmap.git?ref=main";
minecraft-heatmap.inputs.nixpkgs.follows = "nixpkgs";
roowho2.url = "git+https://git.pvv.ntnu.no/Projects/roowho2.git?ref=main&rev=16b2bc5c2759e20ecb952374509f1e1f9d6c06e7";
roowho2.url = "git+https://git.pvv.ntnu.no/Projects/roowho2.git?ref=main&rev=8e5f2849ff7c9616100fe928261512a7ad647939";
roowho2.inputs.nixpkgs.follows = "nixpkgs";
greg-ng.url = "git+https://git.pvv.ntnu.no/Grzegorz/greg-ng.git?ref=main";
+32 -1
View File
@@ -80,9 +80,40 @@ in {
};
services.phpfpm.pools."pvv-nettsiden".settings = {
# "php_admin_value[error_log]" = "stderr";
"php_admin_value[error_log]" = "syslog";
"php_admin_flag[log_errors]" = true;
"catch_workers_output" = true;
"php_admin_value[max_execution_time]" = "30";
"request_terminate_timeout" = "60s";
"php_admin_value[sendmail_path]" = let
fakeSendmail = pkgs.writeShellApplication {
name = "fake-sendmail";
text = ''
TIMESTAMP="$(date +%Y-%m-%d-%H-%M-%S-%N)"
(
echo "SENDMAIL ARGS:"
echo "$@"
echo "SENDMAIL STDIN:"
cat -
) > "/var/lib/pvv-nettsiden/emails/$TIMESTAMP.mail"
'';
};
in lib.getExe fakeSendmail;
"php_admin_value[disable_functions]" = lib.concatStringsSep "," [
"curl_exec"
"curl_multi_exec"
"exec"
"parse_ini_file"
"passthru"
"popen"
"proc_open"
"shell_exec"
"show_source"
"system"
];
};
services.nginx.virtualHosts."pvv.ntnu.no" = {
@@ -40,7 +40,7 @@ in {
path = with pkgs; [ imagemagick gnutar gzip ];
script = ''
tar ${lib.cli.toGNUCommandLineShell {} {
tar ${lib.cli.toCommandLineShellGNU { } {
extract = true;
file = "${transferDir}/gallery.tar.gz";
directory = ".";
+1 -4
View File
@@ -134,9 +134,6 @@ in {
ALLOW_FORK_INTO_SAME_OWNER = true;
};
picture = {
DISABLE_GRAVATAR = true;
ENABLE_FEDERATED_AVATAR = false;
AVATAR_MAX_FILE_SIZE = 1024 * 1024 * 5;
# NOTE: go any bigger than this, and gitea will freeze your gif >:(
AVATAR_MAX_ORIGIN_SIZE = 1024 * 1024 * 2;
@@ -217,7 +214,7 @@ in {
systemd.services.gitea-dump = {
serviceConfig.ExecStart = let
args = lib.cli.toGNUCommandLineShell { } {
args = lib.cli.toCommandLineShellGNU { } {
type = cfg.dump.type;
# This should be declarative on nixos, no need to backup.
@@ -53,7 +53,7 @@ in
Slice = "system-giteaweb.slice";
Type = "oneshot";
ExecStart = let
args = lib.cli.toGNUCommandLineShell { } {
args = lib.cli.toCommandLineShellGNU { } {
org = "%i";
token-path = "%d/token";
api-url = "${giteaCfg.settings.server.ROOT_URL}api/v1";
+12 -7
View File
@@ -4,6 +4,13 @@ let
homeLetters = [ "a" "b" "c" "d" "h" "i" "j" "k" "l" "m" "z" ];
phpOptions = lib.concatStringsSep "\n" (lib.mapAttrsToList (k: v: "${k} = ${v}"){
display_errors = "Off";
display_startup_errors = "Off";
post_max_size = "40M";
upload_max_filesize = "40M";
});
# https://nixos.org/manual/nixpkgs/stable/#ssec-php-user-guide-installing-with-extensions
phpEnv = pkgs.php.buildEnv {
extensions = { all, ... }: with all; [
@@ -29,11 +36,7 @@ let
pdo_sqlite
];
extraConfig = ''
display_errors=0
post_max_size = 40M
upload_max_filesize = 40M
'';
extraConfig = phpOptions;
};
perlEnv = pkgs.perl.withPackages (ps: with ps; [
@@ -70,9 +73,9 @@ let
text = ''
args=("$@")
if [[ "''${PWD:-}" =~ ^/home/pvv/[^/]+/([^/]+) ]] && [[ "''${BASH_REMATCH[1]}" != "pvv" ]]; then
if [[ -z "$USERDIR_USER" ]] && [[ "$USERDIR_USER" != "pvv" ]]; then
# Prepend -fusername to the argument list, so bounces go to the user
args=("-f''${BASH_REMATCH[1]}" "''${args[@]}")
args=("-f$USERDIR_USER" "''${args[@]}")
fi
exec '${lib.getExe pkgs.system-sendmail}' "''${args[@]}"
@@ -173,6 +176,7 @@ in
enablePHP = true;
phpPackage = phpEnv;
inherit phpOptions;
enablePerl = true;
@@ -209,6 +213,7 @@ in
UserDir disabled root
AddHandler cgi-script .cgi
DirectoryIndex index.html index.html.var index.php index.php3 index.cgi index.phtml index.shtml meg.html
SetEnvIf Request_URI "^/~([^/]+)" USERDIR_USER=$1
<Directory "/home/pvv/?/*/web-docs">
Options MultiViews Indexes SymLinksIfOwnerMatch ExecCGI IncludesNoExec
+1 -23
View File
@@ -1,4 +1,4 @@
{ config, lib, pkgs, ... }:
{ config, lib, ... }:
{
services.postfix.enable = lib.mkForce false;
@@ -9,26 +9,4 @@
remotes = "mail.pvv.ntnu.no smtp --port=25";
};
};
systemd.sockets.userweb-sendmail-sandbox-proxy = {
wantedBy = [ "sockets.target" ];
listenStreams = [ "/run/userweb-sendmail-sandbox-proxy.sock" ];
socketConfig = {
# Accept = true;
SocketUser = "httpd";
SocketGroup = "httpd"; # TODO: is wwwrun(54) in this group?
SocketMode = "0660";
};
};
systemd.services.userweb-sendmail-sandbox-proxy = {
serviceConfig = {
User = "root";
Group = "root";
Sockets = [
"userweb-sendmail-sandbox-proxy.socket"
];
ExecStart = "${lib.getExe pkgs.hello}";
};
};
}
+24 -24
View File
@@ -33,63 +33,63 @@ in
lib.mergeAttrsList [
(mw-ext {
name = "CodeEditor";
commit = "83e1d0c13f34746f0d7049e38b00e9ab0a47c23f";
hash = "sha256-qH9fSQZGA+z6tBSh1DaTKLcujqA6K/vQmZML9w5X8mU=";
commit = "2db9c9cef35d88a0696b926e8e4ea2d479d0d73a";
hash = "sha256-f0tWJl/4hml+RCp7OoIpQ4WSGKE3/z8DTYOAOHbLA9A=";
})
(mw-ext {
name = "CodeMirror";
commit = "af2b08b9ad2b89a64b2626cf80b026c5b45e9922";
hash = "sha256-CxXPwCKUlF9Tg4JhwLaKQyvt43owq75jCugVtb3VX+I=";
commit = "b16e614c3c4ba68c346b8dd7393ab005ab127441";
hash = "sha256-J/TJPo5Oxgpy6UQINivLKl8jzJp4k/mKv6br3kcCSMQ=";
})
(mw-ext {
name = "DeleteBatch";
commit = "3d6f2fd0e3efdae1087dd0cc8b1f96fe0edf734f";
hash = "sha256-iD9EjDIW7AGpZan74SIRcr54dV8W7xMKIDjatjdVkKs=";
commit = "1b947c0f80249cf052b58138f830b379edf080bc";
hash = "sha256-629RCz+38m2pfyJe/CrYutRoDyN1HzD0KzDdC2wwqlI=";
})
(mw-ext {
name = "PluggableAuth";
commit = "85e96acd1ac0ebcdaa29c20eae721767a938f426";
hash = "sha256-bMVhrg8FsfWhXF605Cj5TgI0A6Jy/MIQ5aaUcLQQ0Ss=";
commit = "56893b8ee9ecd03eaee256e08c38bc82657ee0a1";
hash = "sha256-gvoJey7YLMk+toutQTdWxpaedNDr59E+3xXWmXWCGl0=";
})
(mw-ext {
name = "Popups";
commit = "410e2343c32a7b18dcdc2bbd995b0bfdf3bf5f37";
hash = "sha256-u2AlR75x54rCpiK9Mz00D9odJCn8fmi6DRU4QKmKqSc=";
commit = "6732d8d195bd8312779d8514e92bad372ef63096";
hash = "sha256-XZzhA9UjAOUMcoGYYwiqRg2uInZ927JOZ9/IrZtarJU=";
})
(mw-ext {
name = "Scribunto";
commit = "904f323f343dba5ff6a6cdd143c4a8ef5b7d2c55";
hash = "sha256-ZOVYhjMMyWbqwZOBb39hMIRmzzCPEnz2y8Q2jgyeERw=";
commit = "fc9658623bd37fad352e326ce81b2a08ef55f04d";
hash = "sha256-P9WQk8O9qP+vXsBS9A5eXX+bRhnfqHetbkXwU3+c1Vk=";
})
(mw-ext {
name = "SimpleSAMLphp";
kebab-name = "simple-saml-php";
commit = "a2f77374713473d594e368de24539aebcc1a800a";
hash = "sha256-5+t3VQFKcrIffDNPJ4RWBIWS6K1gTOcEleYWmM6xWms=";
commit = "4c615a9203860bb908f2476a5467573e3287d224";
hash = "sha256-zNKvzInhdW3B101Hcghk/8m0Y+Qk/7XN7n0i/x/5hSE=";
})
(mw-ext {
name = "TemplateData";
commit = "76a6a04bd13a606923847ba68750b5d98372cacd";
hash = "sha256-X2+U5PMqzkSljw2ypIvJUSaPDaonTkQx89OgKzf5scw=";
commit = "6884b10e603dce82ee39632f839ee5ccd8a6fbe3";
hash = "sha256-jcLe3r5fPIrQlp89N+PdIUSC7bkdd7pTmiYppSpdKVQ=";
})
(mw-ext {
name = "TemplateStyles";
commit = "7de60a8da6576d7930f293d19ef83529abf52704";
hash = "sha256-iPmFDoO5V4964CVyd1mBSQcNlW34odbvpm2CfDBlPBU=";
commit = "f0401a6b82528c8fd5a0375f1e55e72d1211f2ab";
hash = "sha256-tEcCNBz/i9OaE3mNrqw0J2K336BAf6it30TLhQkbtKs=";
})
(mw-ext {
name = "UserMerge";
commit = "71eb53ff4289ac4efaa31685ab8b6483c165a584";
hash = "sha256-OfKSEPgctfr659oh5jf99T0Rzqn+60JhNaZq+2gfubk=";
commit = "6c138ffc65991766fd58ff4739fcb7febf097146";
hash = "sha256-366Nb0ilmXixWgk5NgCuoxj82Mf0iRu1bC/L/eofAxU=";
})
(mw-ext {
name = "VisualEditor";
commit = "a6a63f53605c4d596c3df1dcc2583ffd3eb8d929";
hash = "sha256-4d8picO66uzKoxh1TdyvKLHebc6ZL7N2DdXLV2vgBL4=";
commit = "9cfcca3195bf88225844f136da90ab7a1f6dd0b9";
hash = "sha256-jHw3RnUB3bQa1OvmzhEBqadZlFPWH62iGl5BLXi3nZ4=";
})
(mw-ext {
name = "WikiEditor";
commit = "0a5719bb95326123dd0fee1f88658358321ed7be";
hash = "sha256-eQMyjhdm1E6TkktIHad1NMeMo8QNoO8z4A05FYOMCwQ=";
commit = "fe5329ba7a8c71ac8236cd0e940a64de2645b780";
hash = "sha256-no6kH7esqKiZv34btidzy2zLd75SBVb8EaYVhfRPQSI=";
})
]
+3 -3
View File
@@ -8,18 +8,18 @@
php.buildComposerProject rec {
pname = "simplesamlphp";
version = "2.4.3";
version = "2.5.0";
src = fetchFromGitHub {
owner = "simplesamlphp";
repo = "simplesamlphp";
tag = "v${version}";
hash = "sha256-vv4gzcnPfMapd8gER2Vsng1SBloHKWrJJltnw2HUnX4=";
hash = "sha256-Md07vWhB/5MDUH+SPQEs8PYiUrkEgAyqQl+LO+ap0Sw=";
};
composerStrictValidation = false;
vendorHash = "sha256-vu3Iz6fRk3Gnh9Psn46jgRYKkmqGte+5xHBRmvdgKG4=";
vendorHash = "sha256-GrEoGJXEyI1Ib+06GIuo5eRwxQ0UMKeX5RswShu2CHM=";
# TODO: metadata could be fetched automagically with these:
# - https://simplesamlphp.org/docs/contrib_modules/metarefresh/simplesamlphp-automated_metadata.html