forked from mirrors/nixpkgs
Add `makePortmap' function, for use by NixOS.
svn path=/nixpkgs/trunk/; revision=11139
This commit is contained in:
parent
fa2f6c5272
commit
d9fb721e1a
|
@ -17,9 +17,9 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
makeFlags =
|
makeFlags =
|
||||||
lib.concatStringsSep " "
|
lib.concatStringsSep " "
|
||||||
(lib.optional daemonUser "RPCUSER=\"${daemonUser}\""
|
(lib.optional (daemonUser != false) "RPCUSER=\"${daemonUser}\""
|
||||||
++ lib.optional daemonUID "DAEMON_UID=${daemonUID}"
|
++ lib.optional (daemonUID != false) "DAEMON_UID=${toString daemonUID}"
|
||||||
++ lib.optional daemonGID "DAEMON_GID=${daemonGID}");
|
++ lib.optional (daemonGID != false) "DAEMON_GID=${toString daemonGID}");
|
||||||
|
|
||||||
buildInputs = [ tcpWrapper ];
|
buildInputs = [ tcpWrapper ];
|
||||||
|
|
||||||
|
|
|
@ -3656,14 +3656,15 @@ rec {
|
||||||
inherit fetchurl stdenv apacheHttpd jdk;
|
inherit fetchurl stdenv apacheHttpd jdk;
|
||||||
};
|
};
|
||||||
|
|
||||||
portmap = import ../servers/portmap {
|
# This function is typically called by the NixOS Upstart job to specify the
|
||||||
inherit fetchurl stdenv lib tcpWrapper;
|
# right UID/GID for `portmap'.
|
||||||
|
makePortmap = { daemonUser ? false, daemonGID ? false, daemonUID ? false }:
|
||||||
|
(import ../servers/portmap {
|
||||||
|
inherit fetchurl stdenv lib tcpWrapper
|
||||||
|
daemonUser daemonGID daemonUID;
|
||||||
|
});
|
||||||
|
|
||||||
# This settings should typically be defined by NixOS Upstart job.
|
portmap = (makePortmap);
|
||||||
daemonUser = false;
|
|
||||||
daemonGID = false;
|
|
||||||
daemonUID = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
mysql4 = import ../servers/sql/mysql {
|
mysql4 = import ../servers/sql/mysql {
|
||||||
inherit fetchurl stdenv ncurses zlib perl;
|
inherit fetchurl stdenv ncurses zlib perl;
|
||||||
|
|
Loading…
Reference in a new issue