mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-10-30 14:11:21 +00:00
Merge pull request #89344 from JJJollyjim/openresty-no-perl
openresty: disable perl module by default
This commit is contained in:
commit
132ace5fe6
@ -236,6 +236,7 @@ in
|
||||
nginx-pubhtml = handleTest ./nginx-pubhtml.nix {};
|
||||
nginx-sandbox = handleTestOn ["x86_64-linux"] ./nginx-sandbox.nix {};
|
||||
nginx-sso = handleTest ./nginx-sso.nix {};
|
||||
nginx-variants = handleTest ./nginx-variants.nix {};
|
||||
nix-ssh-serve = handleTest ./nix-ssh-serve.nix {};
|
||||
nixos-generate-config = handleTest ./nixos-generate-config.nix {};
|
||||
novacomd = handleTestOn ["x86_64-linux"] ./novacomd.nix {};
|
||||
|
33
nixos/tests/nginx-variants.nix
Normal file
33
nixos/tests/nginx-variants.nix
Normal file
@ -0,0 +1,33 @@
|
||||
{ system ? builtins.currentSystem,
|
||||
config ? {},
|
||||
pkgs ? import ../.. { inherit system config; }
|
||||
}:
|
||||
|
||||
with import ../lib/testing-python.nix { inherit system pkgs; };
|
||||
|
||||
builtins.listToAttrs (
|
||||
builtins.map
|
||||
(nginxName:
|
||||
{
|
||||
name = nginxName;
|
||||
value = makeTest {
|
||||
name = "nginx-variant-${nginxName}";
|
||||
|
||||
machine = { pkgs, ... }: {
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
virtualHosts.localhost.locations."/".return = "200 'foo'";
|
||||
package = pkgs."${nginxName}";
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
machine.wait_for_unit("nginx")
|
||||
machine.wait_for_open_port(80)
|
||||
machine.succeed('test "$(curl -fvvv http://localhost/)" = foo')
|
||||
'';
|
||||
};
|
||||
}
|
||||
)
|
||||
[ "nginxStable" "nginxUnstable" "nginxShibboleth" "openresty" "tengine" ]
|
||||
)
|
@ -4,6 +4,7 @@
|
||||
, withDebug ? false
|
||||
, withStream ? true
|
||||
, withMail ? false
|
||||
, withPerl ? true
|
||||
, modules ? []
|
||||
, ...
|
||||
}:
|
||||
@ -87,7 +88,7 @@ stdenv.mkDerivation {
|
||||
] ++ optionals withMail [
|
||||
"--with-mail"
|
||||
"--with-mail_ssl_module"
|
||||
] ++ optional (perl != null) [
|
||||
] ++ optionals withPerl [
|
||||
"--with-http_perl_module"
|
||||
"--with-perl=${perl}/bin/perl"
|
||||
"--with-perl_modules_path=lib/perl5"
|
||||
|
@ -34,6 +34,8 @@ callPackage ../nginx/generic.nix args rec {
|
||||
postInstall = ''
|
||||
ln -s $out/luajit/bin/luajit-2.1.0-beta3 $out/bin/luajit-openresty
|
||||
ln -s $out/nginx/sbin/nginx $out/bin/nginx
|
||||
ln -s $out/nginx/conf $out/conf
|
||||
ln -s $out/nginx/html $out/html
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
@ -15927,14 +15927,14 @@ in
|
||||
nginx = nginxStable;
|
||||
|
||||
nginxStable = callPackage ../servers/http/nginx/stable.nix {
|
||||
perl = null;
|
||||
withPerl = false;
|
||||
# We don't use `with` statement here on purpose!
|
||||
# See https://github.com/NixOS/nixpkgs/pull/10474/files#r42369334
|
||||
modules = [ nginxModules.rtmp nginxModules.dav nginxModules.moreheaders ];
|
||||
};
|
||||
|
||||
nginxMainline = callPackage ../servers/http/nginx/mainline.nix {
|
||||
perl = null;
|
||||
withPerl = false;
|
||||
# We don't use `with` statement here on purpose!
|
||||
# See https://github.com/NixOS/nixpkgs/pull/10474/files#r42369334
|
||||
modules = [ nginxModules.dav nginxModules.moreheaders ];
|
||||
@ -15964,7 +15964,9 @@ in
|
||||
openafs = callPackage ../servers/openafs/1.6 { tsmbac = null; ncurses = null; };
|
||||
openafs_1_8 = callPackage ../servers/openafs/1.8 { tsmbac = null; ncurses = null; };
|
||||
|
||||
openresty = callPackage ../servers/http/openresty { };
|
||||
openresty = callPackage ../servers/http/openresty {
|
||||
withPerl = false;
|
||||
};
|
||||
|
||||
opensmtpd = callPackage ../servers/mail/opensmtpd { };
|
||||
opensmtpd-extras = callPackage ../servers/mail/opensmtpd/extras.nix { };
|
||||
|
Loading…
Reference in New Issue
Block a user