From 543ba03fed5bc945da716bfd816386668386296d Mon Sep 17 00:00:00 2001 From: phanirithvij Date: Fri, 10 Jul 2026 10:21:14 +0530 Subject: [PATCH] nixosTests.pdfding: fix on aarch64-linux Signed-off-by: phanirithvij --- nixos/tests/web-apps/pdfding/basic.nix | 6 ++++++ nixos/tests/web-apps/pdfding/postgres.nix | 10 ++++++++++ nixos/tests/web-apps/pdfding/s3-backups.nix | 10 ++++++++++ 3 files changed, 26 insertions(+) diff --git a/nixos/tests/web-apps/pdfding/basic.nix b/nixos/tests/web-apps/pdfding/basic.nix index 5dec3de378e3..10db93c5203b 100644 --- a/nixos/tests/web-apps/pdfding/basic.nix +++ b/nixos/tests/web-apps/pdfding/basic.nix @@ -17,6 +17,11 @@ secretKeyFile = pkgs.writeText "secretKeyFile" "test123"; }; + # NOTE: on aarch64-linux github actions runer due to lack of kvm, we need to delay pdfding start and give it more time to finish + systemd.services.pdfding.wantedBy = lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 (lib.mkForce [ ]); + systemd.services.pdfding.serviceConfig.TimeoutStartSec = + lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 "900"; + environment.systemPackages = with pkgs; [ sqlite ]; @@ -60,6 +65,7 @@ # create admin machine.wait_for_unit("multi-user.target") + machine.succeed("systemctl start pdfding.service") machine.wait_for_open_port(${toString port}) machine.succeed("DJANGO_SUPERUSER_PASSWORD=admin pdfding-manage createsuperuser --no-input --username admin --email admin@localhost") diff --git a/nixos/tests/web-apps/pdfding/postgres.nix b/nixos/tests/web-apps/pdfding/postgres.nix index c6a82fad839a..635799571315 100644 --- a/nixos/tests/web-apps/pdfding/postgres.nix +++ b/nixos/tests/web-apps/pdfding/postgres.nix @@ -22,6 +22,14 @@ installTestHelpers = true; }; + # NOTE: on aarch64-linux github actions runer due to lack of kvm, we need to delay pdfding start and give it more time to finish + systemd.services.pdfding.wantedBy = lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 (lib.mkForce [ ]); + systemd.services.pdfding.serviceConfig.TimeoutStartSec = + lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 "900"; + systemd.services.pdfding-background.wantedBy = lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 ( + lib.mkForce [ ] + ); + environment.systemPackages = [ config.services.postgresql.finalPackage ]; @@ -46,6 +54,8 @@ # create admin machine.wait_for_unit("multi-user.target") + machine.succeed("systemctl start pdfding.service") + machine.succeed("systemctl start pdfding-background.service") machine.wait_for_open_port(${toString port}) machine.succeed("DJANGO_SUPERUSER_PASSWORD=admin pdfding-manage createsuperuser --no-input --username admin --email admin@localhost") diff --git a/nixos/tests/web-apps/pdfding/s3-backups.nix b/nixos/tests/web-apps/pdfding/s3-backups.nix index 5a1184b1aea4..610acabc9abb 100644 --- a/nixos/tests/web-apps/pdfding/s3-backups.nix +++ b/nixos/tests/web-apps/pdfding/s3-backups.nix @@ -37,6 +37,14 @@ in installTestHelpers = true; }; + # NOTE: on aarch64-linux github actions runer due to lack of kvm, we need to delay pdfding start and give it more time to finish + systemd.services.pdfding.wantedBy = lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 (lib.mkForce [ ]); + systemd.services.pdfding.serviceConfig.TimeoutStartSec = + lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 "900"; + systemd.services.pdfding-background.wantedBy = lib.mkIf pkgs.stdenv.hostPlatform.isAarch64 ( + lib.mkForce [ ] + ); + # Setup a local garage service for the backup feature # taken from garage nixosTest services.garage = { @@ -113,6 +121,8 @@ in # create admin machine.wait_for_unit("multi-user.target") + machine.succeed("systemctl start pdfding.service") + machine.succeed("systemctl start pdfding-background.service") machine.wait_for_open_port(${toString port}) machine.succeed("DJANGO_SUPERUSER_PASSWORD=admin pdfding-manage createsuperuser --no-input --username admin --email admin@localhost")