31 lines
718 B
Nix
31 lines
718 B
Nix
{ config, pkgs, ...}:
|
|
|
|
let
|
|
lAddress = "127.0.0.1";
|
|
lPort = 9081;
|
|
nexusPkgs = pkgs.nexus.overrideAttrs (oldAttrs: rec {
|
|
pname = "nexus";
|
|
version = "3.28.1-01";
|
|
sourceRoot = "${pname}-${version}";
|
|
src = pkgs.fetchurl {
|
|
url = "https://sonatype-download.global.ssl.fastly.net/nexus/3/nexus-${version}-unix.tar.gz";
|
|
sha256 = "0qba2qaz85hf0vgix3qyqdl8yzdb6qr91sgdmxv3fgjhyvnvqyy8";
|
|
};
|
|
});
|
|
|
|
in
|
|
{
|
|
services.nginx.virtualHosts."nexus.*" = {
|
|
enableACME = false;
|
|
forceSSL = false;
|
|
locations."/".proxyPass = "http://${lAddress}:${toString lPort}";
|
|
};
|
|
|
|
services.nexus= {
|
|
enable = true;
|
|
listenAddress = lAddress;
|
|
listenPort = lPort;
|
|
package = nexusPkgs;
|
|
};
|
|
}
|