Merge staging-next into staging
This commit is contained in:
commit
ef0345a3fa
@ -278,32 +278,31 @@ The following example shows which arguments are given to `buildPythonPackage` in
|
||||
order to build [`datashape`](https://github.com/blaze/datashape).
|
||||
|
||||
```nix
|
||||
{ # ...
|
||||
{ lib, buildPythonPackage, fetchPypi, numpy, multipledispatch, dateutil, pytest }:
|
||||
|
||||
datashape = buildPythonPackage rec {
|
||||
pname = "datashape";
|
||||
version = "0.4.7";
|
||||
buildPythonPackage rec {
|
||||
pname = "datashape";
|
||||
version = "0.4.7";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "14b2ef766d4c9652ab813182e866f493475e65e558bed0822e38bf07bba1a278";
|
||||
};
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "14b2ef766d4c9652ab813182e866f493475e65e558bed0822e38bf07bba1a278";
|
||||
};
|
||||
|
||||
checkInputs = with self; [ pytest ];
|
||||
propagatedBuildInputs = with self; [ numpy multipledispatch dateutil ];
|
||||
checkInputs = [ pytest ];
|
||||
propagatedBuildInputs = [ numpy multipledispatch dateutil ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = https://github.com/ContinuumIO/datashape;
|
||||
description = "A data description language";
|
||||
license = licenses.bsd2;
|
||||
maintainers = with maintainers; [ fridh ];
|
||||
};
|
||||
meta = with lib; {
|
||||
homepage = https://github.com/ContinuumIO/datashape;
|
||||
description = "A data description language";
|
||||
license = licenses.bsd2;
|
||||
maintainers = with maintainers; [ fridh ];
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
We can see several runtime dependencies, `numpy`, `multipledispatch`, and
|
||||
`dateutil`. Furthermore, we have one `buildInput`, i.e. `pytest`. `pytest` is a
|
||||
`dateutil`. Furthermore, we have one `checkInputs`, i.e. `pytest`. `pytest` is a
|
||||
test runner and is only used during the `checkPhase` and is therefore not added
|
||||
to `propagatedBuildInputs`.
|
||||
|
||||
@ -313,25 +312,24 @@ Python bindings to `libxml2` and `libxslt`. These libraries are only required
|
||||
when building the bindings and are therefore added as `buildInputs`.
|
||||
|
||||
```nix
|
||||
{ # ...
|
||||
{ lib, pkgs, buildPythonPackage, fetchPypi }:
|
||||
|
||||
lxml = buildPythonPackage rec {
|
||||
pname = "lxml";
|
||||
version = "3.4.4";
|
||||
buildPythonPackage rec {
|
||||
pname = "lxml";
|
||||
version = "3.4.4";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "16a0fa97hym9ysdk3rmqz32xdjqmy4w34ld3rm3jf5viqjx65lxk";
|
||||
};
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "16a0fa97hym9ysdk3rmqz32xdjqmy4w34ld3rm3jf5viqjx65lxk";
|
||||
};
|
||||
|
||||
buildInputs = with self; [ pkgs.libxml2 pkgs.libxslt ];
|
||||
buildInputs = [ pkgs.libxml2 pkgs.libxslt ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Pythonic binding for the libxml2 and libxslt libraries";
|
||||
homepage = https://lxml.de;
|
||||
license = licenses.bsd3;
|
||||
maintainers = with maintainers; [ sjourdois ];
|
||||
};
|
||||
meta = with lib; {
|
||||
description = "Pythonic binding for the libxml2 and libxslt libraries";
|
||||
homepage = https://lxml.de;
|
||||
license = licenses.bsd3;
|
||||
maintainers = with maintainers; [ sjourdois ];
|
||||
};
|
||||
}
|
||||
```
|
||||
@ -347,35 +345,34 @@ find each of them in a different folder, and therefore we have to set `LDFLAGS`
|
||||
and `CFLAGS`.
|
||||
|
||||
```nix
|
||||
{ # ...
|
||||
{ lib, pkgs, buildPythonPackage, fetchPypi, numpy, scipy }:
|
||||
|
||||
pyfftw = buildPythonPackage rec {
|
||||
pname = "pyFFTW";
|
||||
version = "0.9.2";
|
||||
buildPythonPackage rec {
|
||||
pname = "pyFFTW";
|
||||
version = "0.9.2";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "f6bbb6afa93085409ab24885a1a3cdb8909f095a142f4d49e346f2bd1b789074";
|
||||
};
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "f6bbb6afa93085409ab24885a1a3cdb8909f095a142f4d49e346f2bd1b789074";
|
||||
};
|
||||
|
||||
buildInputs = [ pkgs.fftw pkgs.fftwFloat pkgs.fftwLongDouble];
|
||||
buildInputs = [ pkgs.fftw pkgs.fftwFloat pkgs.fftwLongDouble];
|
||||
|
||||
propagatedBuildInputs = with self; [ numpy scipy ];
|
||||
propagatedBuildInputs = [ numpy scipy ];
|
||||
|
||||
# Tests cannot import pyfftw. pyfftw works fine though.
|
||||
doCheck = false;
|
||||
# Tests cannot import pyfftw. pyfftw works fine though.
|
||||
doCheck = false;
|
||||
|
||||
preConfigure = ''
|
||||
export LDFLAGS="-L${pkgs.fftw.dev}/lib -L${pkgs.fftwFloat.out}/lib -L${pkgs.fftwLongDouble.out}/lib"
|
||||
export CFLAGS="-I${pkgs.fftw.dev}/include -I${pkgs.fftwFloat.dev}/include -I${pkgs.fftwLongDouble.dev}/include"
|
||||
'';
|
||||
preConfigure = ''
|
||||
export LDFLAGS="-L${pkgs.fftw.dev}/lib -L${pkgs.fftwFloat.out}/lib -L${pkgs.fftwLongDouble.out}/lib"
|
||||
export CFLAGS="-I${pkgs.fftw.dev}/include -I${pkgs.fftwFloat.dev}/include -I${pkgs.fftwLongDouble.dev}/include"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "A pythonic wrapper around FFTW, the FFT library, presenting a unified interface for all the supported transforms";
|
||||
homepage = http://hgomersall.github.com/pyFFTW;
|
||||
license = with licenses; [ bsd2 bsd3 ];
|
||||
maintainers = with maintainers; [ fridh ];
|
||||
};
|
||||
meta = with lib; {
|
||||
description = "A pythonic wrapper around FFTW, the FFT library, presenting a unified interface for all the supported transforms";
|
||||
homepage = http://hgomersall.github.com/pyFFTW;
|
||||
license = with licenses; [ bsd2 bsd3 ];
|
||||
maintainers = with maintainers; [ fridh ];
|
||||
};
|
||||
}
|
||||
```
|
||||
@ -403,7 +400,7 @@ Indeed, we can just add any package we like to have in our environment to `propa
|
||||
|
||||
```nix
|
||||
with import <nixpkgs> {};
|
||||
with pkgs.python35Packages;
|
||||
with python35Packages;
|
||||
|
||||
buildPythonPackage rec {
|
||||
name = "mypackage";
|
||||
@ -436,7 +433,7 @@ Let's split the package definition from the environment definition.
|
||||
We first create a function that builds `toolz` in `~/path/to/toolz/release.nix`
|
||||
|
||||
```nix
|
||||
{ lib, pkgs, buildPythonPackage }:
|
||||
{ lib, buildPythonPackage }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "toolz";
|
||||
@ -456,18 +453,17 @@ buildPythonPackage rec {
|
||||
}
|
||||
```
|
||||
|
||||
It takes two arguments, `pkgs` and `buildPythonPackage`.
|
||||
It takes an argument `buildPythonPackage`.
|
||||
We now call this function using `callPackage` in the definition of our environment
|
||||
|
||||
```nix
|
||||
with import <nixpkgs> {};
|
||||
|
||||
( let
|
||||
toolz = pkgs.callPackage /path/to/toolz/release.nix {
|
||||
pkgs = pkgs;
|
||||
buildPythonPackage = pkgs.python35Packages.buildPythonPackage;
|
||||
toolz = callPackage /path/to/toolz/release.nix {
|
||||
buildPythonPackage = python35Packages.buildPythonPackage;
|
||||
};
|
||||
in pkgs.python35.withPackages (ps: [ ps.numpy toolz ])
|
||||
in python35.withPackages (ps: [ ps.numpy toolz ])
|
||||
).env
|
||||
```
|
||||
|
||||
@ -565,7 +561,7 @@ buildPythonPackage rec {
|
||||
'';
|
||||
|
||||
checkInputs = [ hypothesis ];
|
||||
buildInputs = [ setuptools_scm ];
|
||||
nativeBuildInputs = [ setuptools_scm ];
|
||||
propagatedBuildInputs = [ attrs py setuptools six pluggy ];
|
||||
|
||||
meta = with lib; {
|
||||
@ -585,11 +581,6 @@ The `buildPythonPackage` mainly does four things:
|
||||
environment variable and add dependent libraries to script's `sys.path`.
|
||||
* In the `installCheck` phase, `${python.interpreter} setup.py test` is ran.
|
||||
|
||||
As in Perl, dependencies on other Python packages can be specified in the
|
||||
`buildInputs` and `propagatedBuildInputs` attributes. If something is
|
||||
exclusively a build-time dependency, use `buildInputs`; if it is (also) a runtime
|
||||
dependency, use `propagatedBuildInputs`.
|
||||
|
||||
By default tests are run because `doCheck = true`. Test dependencies, like
|
||||
e.g. the test runner, should be added to `checkInputs`.
|
||||
|
||||
@ -733,7 +724,7 @@ Saving the following as `default.nix`
|
||||
with import <nixpkgs> {};
|
||||
|
||||
python.buildEnv.override {
|
||||
extraLibs = [ pkgs.pythonPackages.pyramid ];
|
||||
extraLibs = [ pythonPackages.pyramid ];
|
||||
ignoreCollisions = true;
|
||||
}
|
||||
```
|
||||
@ -815,11 +806,12 @@ Given a `default.nix`:
|
||||
```nix
|
||||
with import <nixpkgs> {};
|
||||
|
||||
buildPythonPackage { name = "myproject";
|
||||
pythonPackages.buildPythonPackage {
|
||||
name = "myproject";
|
||||
buildInputs = with pythonPackages; [ pyramid ];
|
||||
|
||||
buildInputs = with pkgs.pythonPackages; [ pyramid ];
|
||||
|
||||
src = ./.; }
|
||||
src = ./.;
|
||||
}
|
||||
```
|
||||
|
||||
Running `nix-shell` with no arguments should give you
|
||||
@ -1005,10 +997,13 @@ Create this `default.nix` file, together with a `requirements.txt` and simply ex
|
||||
|
||||
```nix
|
||||
with import <nixpkgs> {};
|
||||
with pkgs.python27Packages;
|
||||
with python27Packages;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "impurePythonEnv";
|
||||
|
||||
src = null;
|
||||
|
||||
buildInputs = [
|
||||
# these packages are required for virtualenv and pip to work:
|
||||
#
|
||||
@ -1028,14 +1023,15 @@ stdenv.mkDerivation {
|
||||
libxslt
|
||||
libzip
|
||||
stdenv
|
||||
zlib ];
|
||||
src = null;
|
||||
zlib
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
# set SOURCE_DATE_EPOCH so that we can use python wheels
|
||||
SOURCE_DATE_EPOCH=$(date +%s)
|
||||
virtualenv --no-setuptools venv
|
||||
export PATH=$PWD/venv/bin:$PATH
|
||||
pip install -r requirements.txt
|
||||
# set SOURCE_DATE_EPOCH so that we can use python wheels
|
||||
SOURCE_DATE_EPOCH=$(date +%s)
|
||||
virtualenv --no-setuptools venv
|
||||
export PATH=$PWD/venv/bin:$PATH
|
||||
pip install -r requirements.txt
|
||||
'';
|
||||
}
|
||||
```
|
||||
|
@ -310,6 +310,10 @@ packageOverrides = pkgs: {
|
||||
<section xml:id="sec-elm">
|
||||
<title>Elm</title>
|
||||
|
||||
<para>
|
||||
To start a development environment do <command>nix-shell -p elmPackages.elm elmPackages.elm-format</command>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
To update Elm compiler, see
|
||||
<filename>nixpkgs/pkgs/development/compilers/elm/README.md</filename>.
|
||||
|
@ -1219,6 +1219,11 @@
|
||||
github = "dgonyeo";
|
||||
name = "Derek Gonyeo";
|
||||
};
|
||||
dhkl = {
|
||||
email = "david@davidslab.com";
|
||||
github = "dhl";
|
||||
name = "David Leung";
|
||||
};
|
||||
dipinhora = {
|
||||
email = "dipinhora+github@gmail.com";
|
||||
github = "dipinhora";
|
||||
@ -2733,6 +2738,11 @@
|
||||
github = "lo1tuma";
|
||||
name = "Mathias Schreck";
|
||||
};
|
||||
loewenheim = {
|
||||
email = "loewenheim@mailbox.org";
|
||||
github = "loewenheim";
|
||||
name = "Sebastian Zivota";
|
||||
};
|
||||
lopsided98 = {
|
||||
email = "benwolsieffer@gmail.com";
|
||||
github = "lopsided98";
|
||||
@ -3292,6 +3302,11 @@
|
||||
github = "mvnetbiz";
|
||||
name = "Matt Votava";
|
||||
};
|
||||
mwilsoninsight = {
|
||||
email = "max.wilson@insight.com";
|
||||
github = "mwilsoninsight";
|
||||
name = "Max Wilson";
|
||||
};
|
||||
myrl = {
|
||||
email = "myrl.0xf@gmail.com";
|
||||
github = "myrl";
|
||||
@ -3431,6 +3446,11 @@
|
||||
github = "nocoolnametom";
|
||||
name = "Tom Doggett";
|
||||
};
|
||||
nomeata = {
|
||||
email = "mail@joachim-breitner.de";
|
||||
github = "nomeata";
|
||||
name = "Joachim Breitner";
|
||||
};
|
||||
noneucat = {
|
||||
email = "andy@lolc.at";
|
||||
github = "noneucat";
|
||||
@ -4584,6 +4604,11 @@
|
||||
github = "stumoss";
|
||||
name = "Stuart Moss";
|
||||
};
|
||||
suhr = {
|
||||
email = "suhr@i2pmail.org";
|
||||
github = "suhr";
|
||||
name = "Сухарик";
|
||||
};
|
||||
SuprDewd = {
|
||||
email = "suprdewd@gmail.com";
|
||||
github = "SuprDewd";
|
||||
|
@ -534,6 +534,13 @@
|
||||
Same applies to the new <literal>users.ldap.daemon.rootpwmodpwFile</literal> option.
|
||||
</para>
|
||||
</listitem>
|
||||
<listitem>
|
||||
<para>
|
||||
<literal>nodejs-6_x</literal> is end-of-life.
|
||||
<literal>nodejs-6_x</literal>, <literal>nodejs-slim-6_x</literal> and
|
||||
<literal>nodePackages_6_x</literal> are removed.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
|
||||
|
@ -37,7 +37,52 @@
|
||||
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para />
|
||||
<para>
|
||||
Besides the existing <option>services.prometheus</option> module which
|
||||
targets Prometheus-1 a new <option>services.prometheus2</option> module
|
||||
has been added which targets Prometheus-2.
|
||||
</para>
|
||||
<para>
|
||||
Both modules can be enabled at the same time. In fact
|
||||
<link xlink:href="https://prometheus.io/docs/prometheus/latest/migration/#storage">
|
||||
this is needed for upgrading existing Prometheus-1 data to Prometheus-2
|
||||
</link>.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
|
||||
<section xmlns="http://docbook.org/ns/docbook"
|
||||
xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
xmlns:xi="http://www.w3.org/2001/XInclude"
|
||||
version="5.0"
|
||||
xml:id="sec-release-19.09-incompatibilities">
|
||||
<title>Backward Incompatibilities</title>
|
||||
|
||||
<para>
|
||||
When upgrading from a previous release, please be aware of the following
|
||||
incompatible changes:
|
||||
</para>
|
||||
|
||||
<itemizedlist>
|
||||
<listitem>
|
||||
<para>
|
||||
The directory where Prometheus will store its metric data is now
|
||||
managed by systemd's StateDirectory mechanism. It still defaults
|
||||
to <literal>/var/lib/prometheus</literal>.
|
||||
</para>
|
||||
<para>
|
||||
Its location can be specified by the new
|
||||
<option>services.prometheus.stateDir</option> option which
|
||||
defaults to <literal>prometheus</literal>. Note that this should
|
||||
be a directory relative to <literal>/var/lib/</literal>.
|
||||
</para>
|
||||
<para>
|
||||
The option <option>services.prometheus.dataDir</option> has been
|
||||
deprecated. You can still set it but it's now required to have
|
||||
<literal>/var/lib/</literal> as a prefix and you can't set
|
||||
<option>services.prometheus.stateDir</option> at the same time.
|
||||
</para>
|
||||
</listitem>
|
||||
</itemizedlist>
|
||||
</section>
|
||||
|
@ -744,6 +744,7 @@
|
||||
./services/web-apps/atlassian/crowd.nix
|
||||
./services/web-apps/atlassian/jira.nix
|
||||
./services/web-apps/codimd.nix
|
||||
./services/web-apps/documize.nix
|
||||
./services/web-apps/frab.nix
|
||||
./services/web-apps/icingaweb2/icingaweb2.nix
|
||||
./services/web-apps/icingaweb2/module-monitoring.nix
|
||||
|
@ -226,9 +226,7 @@ in
|
||||
|
||||
environment.shells =
|
||||
[ "/run/current-system/sw/bin/bash"
|
||||
"/var/run/current-system/sw/bin/bash"
|
||||
"/run/current-system/sw/bin/sh"
|
||||
"/var/run/current-system/sw/bin/sh"
|
||||
"${pkgs.bashInteractive}/bin/bash"
|
||||
"${pkgs.bashInteractive}/bin/sh"
|
||||
];
|
||||
|
@ -232,7 +232,6 @@ in
|
||||
|
||||
environment.shells = [
|
||||
"/run/current-system/sw/bin/fish"
|
||||
"/var/run/current-system/sw/bin/fish"
|
||||
"${pkgs.fish}/bin/fish"
|
||||
];
|
||||
|
||||
|
@ -50,7 +50,6 @@ in
|
||||
|
||||
environment.shells =
|
||||
[ "/run/current-system/sw/bin/xonsh"
|
||||
"/var/run/current-system/sw/bin/xonsh"
|
||||
"${pkgs.xonsh}/bin/xonsh"
|
||||
];
|
||||
|
||||
|
@ -230,7 +230,6 @@ in
|
||||
|
||||
environment.shells =
|
||||
[ "/run/current-system/sw/bin/zsh"
|
||||
"/var/run/current-system/sw/bin/zsh"
|
||||
"${pkgs.zsh}/bin/zsh"
|
||||
];
|
||||
|
||||
|
@ -134,7 +134,7 @@ with lib;
|
||||
inetPort = [ "services" "postgrey" "inetPort" ];
|
||||
in
|
||||
if value inetAddr == null
|
||||
then { path = "/var/run/postgrey.sock"; }
|
||||
then { path = "/run/postgrey.sock"; }
|
||||
else { addr = value inetAddr; port = value inetPort; }
|
||||
))
|
||||
|
||||
|
@ -15,7 +15,7 @@ let
|
||||
Name = "${fd_cfg.name}";
|
||||
FDPort = ${toString fd_cfg.port};
|
||||
WorkingDirectory = "${libDir}";
|
||||
Pid Directory = "/var/run";
|
||||
Pid Directory = "/run";
|
||||
${fd_cfg.extraClientConfig}
|
||||
}
|
||||
|
||||
@ -41,7 +41,7 @@ let
|
||||
Name = "${sd_cfg.name}";
|
||||
SDPort = ${toString sd_cfg.port};
|
||||
WorkingDirectory = "${libDir}";
|
||||
Pid Directory = "/var/run";
|
||||
Pid Directory = "/run";
|
||||
${sd_cfg.extraStorageConfig}
|
||||
}
|
||||
|
||||
@ -77,7 +77,7 @@ let
|
||||
Password = "${dir_cfg.password}";
|
||||
DirPort = ${toString dir_cfg.port};
|
||||
Working Directory = "${libDir}";
|
||||
Pid Directory = "/var/run/";
|
||||
Pid Directory = "/run/";
|
||||
QueryFile = "${pkgs.bacula}/etc/query.sql";
|
||||
${dir_cfg.extraDirectorConfig}
|
||||
}
|
||||
|
@ -85,7 +85,7 @@ in {
|
||||
|
||||
uriFile = mkOption {
|
||||
type = types.path;
|
||||
default = "/var/run/couchdb/couchdb.uri";
|
||||
default = "/run/couchdb/couchdb.uri";
|
||||
description = ''
|
||||
This file contains the full URI that can be used to access this
|
||||
instance of CouchDB. It is used to help discover the port CouchDB is
|
||||
|
@ -65,7 +65,7 @@ in
|
||||
};
|
||||
|
||||
pidFile = mkOption {
|
||||
default = "/var/run/mongodb.pid";
|
||||
default = "/run/mongodb.pid";
|
||||
description = "Location of MongoDB pid file";
|
||||
};
|
||||
|
||||
|
@ -226,8 +226,8 @@ in
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network.target" ];
|
||||
preStart = ''
|
||||
mkdir -p /var/run/slapd
|
||||
chown -R "${cfg.user}:${cfg.group}" /var/run/slapd
|
||||
mkdir -p /run/slapd
|
||||
chown -R "${cfg.user}:${cfg.group}" /run/slapd
|
||||
${optionalString (cfg.declarativeContents != null) ''
|
||||
rm -Rf "${cfg.dataDir}"
|
||||
''}
|
||||
|
@ -95,7 +95,7 @@ in
|
||||
type = with types; nullOr path;
|
||||
default = null;
|
||||
description = "The path to the socket to bind to.";
|
||||
example = "/var/run/redis.sock";
|
||||
example = "/run/redis.sock";
|
||||
};
|
||||
|
||||
logLevel = mkOption {
|
||||
|
@ -41,7 +41,7 @@ in
|
||||
};
|
||||
|
||||
pidpath = mkOption {
|
||||
default = "/var/run/rethinkdb";
|
||||
default = "/run/rethinkdb";
|
||||
description = "Location where each instance's pid file is located.";
|
||||
};
|
||||
|
||||
|
@ -48,8 +48,8 @@ with lib;
|
||||
requiredBy = [ "postfix.service" ];
|
||||
serviceConfig = {
|
||||
Type = "forking";
|
||||
PIDFile = "/var/run/pfix-srsd.pid";
|
||||
ExecStart = "${pkgs.pfixtools}/bin/pfix-srsd -p /var/run/pfix-srsd.pid -I ${config.services.pfix-srsd.domain} ${config.services.pfix-srsd.secretsFile}";
|
||||
PIDFile = "/run/pfix-srsd.pid";
|
||||
ExecStart = "${pkgs.pfixtools}/bin/pfix-srsd -p /run/pfix-srsd.pid -I ${config.services.pfix-srsd.domain} ${config.services.pfix-srsd.secretsFile}";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -29,7 +29,7 @@ with lib; let
|
||||
options = {
|
||||
path = mkOption {
|
||||
type = path;
|
||||
default = "/var/run/postgrey.sock";
|
||||
default = "/run/postgrey.sock";
|
||||
description = "Path of the unix socket";
|
||||
};
|
||||
|
||||
@ -53,7 +53,7 @@ in {
|
||||
socket = mkOption {
|
||||
type = socket;
|
||||
default = {
|
||||
path = "/var/run/postgrey.sock";
|
||||
path = "/run/postgrey.sock";
|
||||
mode = "0777";
|
||||
};
|
||||
example = {
|
||||
|
@ -174,7 +174,7 @@ in
|
||||
after = [ "network.target" ];
|
||||
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.spamassassin}/bin/spamd ${optionalString cfg.debug "-D"} --username=spamd --groupname=spamd --siteconfigpath=${spamdEnv} --virtual-config-dir=/var/lib/spamassassin/user-%u --allow-tell --pidfile=/var/run/spamd.pid";
|
||||
ExecStart = "${pkgs.spamassassin}/bin/spamd ${optionalString cfg.debug "-D"} --username=spamd --groupname=spamd --siteconfigpath=${spamdEnv} --virtual-config-dir=/var/lib/spamassassin/user-%u --allow-tell --pidfile=/run/spamd.pid";
|
||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||
};
|
||||
|
||||
|
@ -30,7 +30,7 @@ ${optionalString (cfg.bind_host != null) ''
|
||||
bind_host: "${cfg.bind_host}"
|
||||
''}
|
||||
server_name: "${cfg.server_name}"
|
||||
pid_file: "/var/run/matrix-synapse.pid"
|
||||
pid_file: "/run/matrix-synapse.pid"
|
||||
web_client: ${boolToString cfg.web_client}
|
||||
${optionalString (cfg.public_baseurl != null) ''
|
||||
public_baseurl: "${cfg.public_baseurl}"
|
||||
|
@ -101,7 +101,7 @@ in {
|
||||
Type = "simple";
|
||||
ExecStart = "${cfg.package}/bin/mbpfan -f${verbose}";
|
||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||
PIDFile = "/var/run/mbpfan.pid";
|
||||
PIDFile = "/run/mbpfan.pid";
|
||||
Restart = "always";
|
||||
};
|
||||
};
|
||||
|
@ -19,7 +19,7 @@ in
|
||||
description = "spice-vdagent daemon";
|
||||
wantedBy = [ "graphical.target" ];
|
||||
preStart = ''
|
||||
mkdir -p "/var/run/spice-vdagentd/"
|
||||
mkdir -p "/run/spice-vdagentd/"
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "forking";
|
||||
|
@ -38,7 +38,7 @@ in
|
||||
after = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
preStart = "mkdir -p ${cfg.svnBaseDir}";
|
||||
script = "${pkgs.subversion.out}/bin/svnserve -r ${cfg.svnBaseDir} -d --foreground --pid-file=/var/run/svnserve.pid";
|
||||
script = "${pkgs.subversion.out}/bin/svnserve -r ${cfg.svnBaseDir} -d --foreground --pid-file=/run/svnserve.pid";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -24,7 +24,7 @@ let
|
||||
status_file=${nagiosState}/status.dat
|
||||
object_cache_file=${nagiosState}/objects.cache
|
||||
temp_file=${nagiosState}/nagios.tmp
|
||||
lock_file=/var/run/nagios.lock # Not used I think.
|
||||
lock_file=/run/nagios.lock # Not used I think.
|
||||
state_retention_file=${nagiosState}/retention.dat
|
||||
query_socket=${nagiosState}/nagios.qh
|
||||
check_result_path=${nagiosState}
|
||||
|
@ -4,9 +4,24 @@ with lib;
|
||||
|
||||
let
|
||||
cfg = config.services.prometheus;
|
||||
cfg2 = config.services.prometheus2;
|
||||
promUser = "prometheus";
|
||||
promGroup = "prometheus";
|
||||
|
||||
stateDir =
|
||||
if cfg.stateDir != null
|
||||
then cfg.stateDir
|
||||
else
|
||||
if cfg.dataDir != null
|
||||
then
|
||||
# This assumes /var/lib/ is a prefix of cfg.dataDir.
|
||||
# This is checked as an assertion below.
|
||||
removePrefix stateDirBase cfg.dataDir
|
||||
else "prometheus";
|
||||
stateDirBase = "/var/lib/";
|
||||
workingDir = stateDirBase + stateDir;
|
||||
workingDir2 = stateDirBase + cfg2.stateDir;
|
||||
|
||||
# Get a submodule without any embedded metadata:
|
||||
_filter = x: filterAttrs (k: v: k != "_module") x;
|
||||
|
||||
@ -17,13 +32,23 @@ let
|
||||
promtool ${what} $out
|
||||
'';
|
||||
|
||||
# a wrapper that verifies that the configuration is valid for
|
||||
# prometheus 2
|
||||
prom2toolCheck = what: name: file:
|
||||
pkgs.runCommand
|
||||
"${name}-${replaceStrings [" "] [""] what}-checked"
|
||||
{ buildInputs = [ cfg2.package ]; } ''
|
||||
ln -s ${file} $out
|
||||
promtool ${what} $out
|
||||
'';
|
||||
|
||||
# Pretty-print JSON to a file
|
||||
writePrettyJSON = name: x:
|
||||
pkgs.runCommand name { preferLocalBuild = true; } ''
|
||||
echo '${builtins.toJSON x}' | ${pkgs.jq}/bin/jq . > $out
|
||||
'';
|
||||
|
||||
# This becomes the main config file
|
||||
# This becomes the main config file for Prometheus 1
|
||||
promConfig = {
|
||||
global = cfg.globalConfig;
|
||||
rule_files = map (promtoolCheck "check-rules" "rules") (cfg.ruleFiles ++ [
|
||||
@ -35,20 +60,53 @@ let
|
||||
generatedPrometheusYml = writePrettyJSON "prometheus.yml" promConfig;
|
||||
|
||||
prometheusYml = let
|
||||
yml = if cfg.configText != null then
|
||||
yml = if cfg.configText != null then
|
||||
pkgs.writeText "prometheus.yml" cfg.configText
|
||||
else generatedPrometheusYml;
|
||||
in promtoolCheck "check-config" "prometheus.yml" yml;
|
||||
|
||||
cmdlineArgs = cfg.extraFlags ++ [
|
||||
"-storage.local.path=${cfg.dataDir}/metrics"
|
||||
"-storage.local.path=${workingDir}/metrics"
|
||||
"-config.file=${prometheusYml}"
|
||||
"-web.listen-address=${cfg.listenAddress}"
|
||||
"-alertmanager.notification-queue-capacity=${toString cfg.alertmanagerNotificationQueueCapacity}"
|
||||
"-alertmanager.timeout=${toString cfg.alertmanagerTimeout}s"
|
||||
(optionalString (cfg.alertmanagerURL != []) "-alertmanager.url=${concatStringsSep "," cfg.alertmanagerURL}")
|
||||
(optionalString (cfg.webExternalUrl != null) "-web.external-url=${cfg.webExternalUrl}")
|
||||
];
|
||||
] ++
|
||||
optional (cfg.alertmanagerURL != []) "-alertmanager.url=${concatStringsSep "," cfg.alertmanagerURL}" ++
|
||||
optional (cfg.webExternalUrl != null) "-web.external-url=${cfg.webExternalUrl}";
|
||||
|
||||
# This becomes the main config file for Prometheus 2
|
||||
promConfig2 = {
|
||||
global = cfg2.globalConfig;
|
||||
rule_files = map (prom2toolCheck "check rules" "rules") (cfg2.ruleFiles ++ [
|
||||
(pkgs.writeText "prometheus.rules" (concatStringsSep "\n" cfg2.rules))
|
||||
]);
|
||||
scrape_configs = cfg2.scrapeConfigs;
|
||||
alerting = optionalAttrs (cfg2.alertmanagerURL != []) {
|
||||
alertmanagers = [{
|
||||
static_configs = [{
|
||||
targets = cfg2.alertmanagerURL;
|
||||
}];
|
||||
}];
|
||||
};
|
||||
};
|
||||
|
||||
generatedPrometheus2Yml = writePrettyJSON "prometheus.yml" promConfig2;
|
||||
|
||||
prometheus2Yml = let
|
||||
yml = if cfg2.configText != null then
|
||||
pkgs.writeText "prometheus.yml" cfg2.configText
|
||||
else generatedPrometheus2Yml;
|
||||
in prom2toolCheck "check config" "prometheus.yml" yml;
|
||||
|
||||
cmdlineArgs2 = cfg2.extraFlags ++ [
|
||||
"--storage.tsdb.path=${workingDir2}/data/"
|
||||
"--config.file=${prometheus2Yml}"
|
||||
"--web.listen-address=${cfg2.listenAddress}"
|
||||
"--alertmanager.notification-queue-capacity=${toString cfg2.alertmanagerNotificationQueueCapacity}"
|
||||
"--alertmanager.timeout=${toString cfg2.alertmanagerTimeout}s"
|
||||
] ++
|
||||
optional (cfg2.webExternalUrl != null) "--web.external-url=${cfg2.webExternalUrl}";
|
||||
|
||||
promTypes.globalConfig = types.submodule {
|
||||
options = {
|
||||
@ -403,10 +461,21 @@ in {
|
||||
};
|
||||
|
||||
dataDir = mkOption {
|
||||
type = types.path;
|
||||
default = "/var/lib/prometheus";
|
||||
type = types.nullOr types.path;
|
||||
default = null;
|
||||
description = ''
|
||||
Directory to store Prometheus metrics data.
|
||||
This option is deprecated, please use <option>services.prometheus.stateDir</option>.
|
||||
'';
|
||||
};
|
||||
|
||||
stateDir = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
description = ''
|
||||
Directory below <literal>${stateDirBase}</literal> to store Prometheus metrics data.
|
||||
This directory will be created automatically using systemd's StateDirectory mechanism.
|
||||
Defaults to <literal>prometheus</literal>.
|
||||
'';
|
||||
};
|
||||
|
||||
@ -497,30 +566,201 @@ in {
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
services.prometheus2 = {
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
users.groups.${promGroup}.gid = config.ids.gids.prometheus;
|
||||
users.users.${promUser} = {
|
||||
description = "Prometheus daemon user";
|
||||
uid = config.ids.uids.prometheus;
|
||||
group = promGroup;
|
||||
home = cfg.dataDir;
|
||||
createHome = true;
|
||||
};
|
||||
systemd.services.prometheus = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network.target" ];
|
||||
script = ''
|
||||
#!/bin/sh
|
||||
exec ${cfg.package}/bin/prometheus \
|
||||
${concatStringsSep " \\\n " cmdlineArgs}
|
||||
'';
|
||||
serviceConfig = {
|
||||
User = promUser;
|
||||
Restart = "always";
|
||||
WorkingDirectory = cfg.dataDir;
|
||||
enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = ''
|
||||
Enable the Prometheus 2 monitoring daemon.
|
||||
'';
|
||||
};
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
default = pkgs.prometheus_2;
|
||||
defaultText = "pkgs.prometheus_2";
|
||||
description = ''
|
||||
The prometheus2 package that should be used.
|
||||
'';
|
||||
};
|
||||
|
||||
listenAddress = mkOption {
|
||||
type = types.str;
|
||||
default = "0.0.0.0:9090";
|
||||
description = ''
|
||||
Address to listen on for the web interface, API, and telemetry.
|
||||
'';
|
||||
};
|
||||
|
||||
stateDir = mkOption {
|
||||
type = types.str;
|
||||
default = "prometheus2";
|
||||
description = ''
|
||||
Directory below <literal>${stateDirBase}</literal> to store Prometheus metrics data.
|
||||
This directory will be created automatically using systemd's StateDirectory mechanism.
|
||||
Defaults to <literal>prometheus2</literal>.
|
||||
'';
|
||||
};
|
||||
|
||||
extraFlags = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
description = ''
|
||||
Extra commandline options when launching Prometheus 2.
|
||||
'';
|
||||
};
|
||||
|
||||
configText = mkOption {
|
||||
type = types.nullOr types.lines;
|
||||
default = null;
|
||||
description = ''
|
||||
If non-null, this option defines the text that is written to
|
||||
prometheus.yml. If null, the contents of prometheus.yml is generated
|
||||
from the structured config options.
|
||||
'';
|
||||
};
|
||||
|
||||
globalConfig = mkOption {
|
||||
type = promTypes.globalConfig;
|
||||
default = {};
|
||||
apply = _filter;
|
||||
description = ''
|
||||
Parameters that are valid in all configuration contexts. They
|
||||
also serve as defaults for other configuration sections
|
||||
'';
|
||||
};
|
||||
|
||||
rules = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
description = ''
|
||||
Alerting and/or Recording rules to evaluate at runtime.
|
||||
'';
|
||||
};
|
||||
|
||||
ruleFiles = mkOption {
|
||||
type = types.listOf types.path;
|
||||
default = [];
|
||||
description = ''
|
||||
Any additional rules files to include in this configuration.
|
||||
'';
|
||||
};
|
||||
|
||||
scrapeConfigs = mkOption {
|
||||
type = types.listOf promTypes.scrape_config;
|
||||
default = [];
|
||||
apply = x: map _filter x;
|
||||
description = ''
|
||||
A list of scrape configurations.
|
||||
'';
|
||||
};
|
||||
|
||||
alertmanagerURL = mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
description = ''
|
||||
List of Alertmanager URLs to send notifications to.
|
||||
'';
|
||||
};
|
||||
|
||||
alertmanagerNotificationQueueCapacity = mkOption {
|
||||
type = types.int;
|
||||
default = 10000;
|
||||
description = ''
|
||||
The capacity of the queue for pending alert manager notifications.
|
||||
'';
|
||||
};
|
||||
|
||||
alertmanagerTimeout = mkOption {
|
||||
type = types.int;
|
||||
default = 10;
|
||||
description = ''
|
||||
Alert manager HTTP API timeout (in seconds).
|
||||
'';
|
||||
};
|
||||
|
||||
webExternalUrl = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
example = "https://example.com/";
|
||||
description = ''
|
||||
The URL under which Prometheus is externally reachable (for example,
|
||||
if Prometheus is served via a reverse proxy).
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
(mkIf (cfg.enable || cfg2.enable) {
|
||||
users.groups.${promGroup}.gid = config.ids.gids.prometheus;
|
||||
users.users.${promUser} = {
|
||||
description = "Prometheus daemon user";
|
||||
uid = config.ids.uids.prometheus;
|
||||
group = promGroup;
|
||||
};
|
||||
})
|
||||
(mkIf cfg.enable {
|
||||
warnings =
|
||||
optional (cfg.dataDir != null) ''
|
||||
The option services.prometheus.dataDir is deprecated, please use
|
||||
services.prometheus.stateDir.
|
||||
'';
|
||||
assertions = [
|
||||
{
|
||||
assertion = !(cfg.dataDir != null && cfg.stateDir != null);
|
||||
message =
|
||||
"The options services.prometheus.dataDir and services.prometheus.stateDir" +
|
||||
" can't both be set at the same time! It's recommended to only set the latter" +
|
||||
" since the former is deprecated.";
|
||||
}
|
||||
{
|
||||
assertion = cfg.dataDir != null -> hasPrefix stateDirBase cfg.dataDir;
|
||||
message =
|
||||
"The option services.prometheus.dataDir should have ${stateDirBase} as a prefix!";
|
||||
}
|
||||
{
|
||||
assertion = cfg.stateDir != null -> !hasPrefix "/" cfg.stateDir;
|
||||
message =
|
||||
"The option services.prometheus.stateDir shouldn't be an absolute directory." +
|
||||
" It should be a directory relative to ${stateDirBase}.";
|
||||
}
|
||||
{
|
||||
assertion = cfg2.stateDir != null -> !hasPrefix "/" cfg2.stateDir;
|
||||
message =
|
||||
"The option services.prometheus2.stateDir shouldn't be an absolute directory." +
|
||||
" It should be a directory relative to ${stateDirBase}.";
|
||||
}
|
||||
];
|
||||
systemd.services.prometheus = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = "${cfg.package}/bin/prometheus" +
|
||||
optionalString (length cmdlineArgs != 0) (" \\\n " +
|
||||
concatStringsSep " \\\n " cmdlineArgs);
|
||||
User = promUser;
|
||||
Restart = "always";
|
||||
WorkingDirectory = workingDir;
|
||||
StateDirectory = stateDir;
|
||||
};
|
||||
};
|
||||
})
|
||||
(mkIf cfg2.enable {
|
||||
systemd.services.prometheus2 = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = "${cfg2.package}/bin/prometheus" +
|
||||
optionalString (length cmdlineArgs2 != 0) (" \\\n " +
|
||||
concatStringsSep " \\\n " cmdlineArgs2);
|
||||
User = promUser;
|
||||
Restart = "always";
|
||||
WorkingDirectory = workingDir2;
|
||||
StateDirectory = cfg2.stateDir;
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
}
|
||||
|
@ -9,7 +9,7 @@ let
|
||||
|
||||
zabbix = cfg.package;
|
||||
|
||||
stateDir = "/var/run/zabbix";
|
||||
stateDir = "/run/zabbix";
|
||||
|
||||
logDir = "/var/log/zabbix";
|
||||
|
||||
|
@ -7,7 +7,7 @@ let
|
||||
|
||||
cfg = config.services.zabbixServer;
|
||||
|
||||
stateDir = "/var/run/zabbix";
|
||||
stateDir = "/run/zabbix";
|
||||
|
||||
logDir = "/var/log/zabbix";
|
||||
|
||||
|
@ -45,7 +45,7 @@ let
|
||||
astdatadir => /var/lib/asterisk
|
||||
astagidir => /var/lib/asterisk/agi-bin
|
||||
astspooldir => /var/spool/asterisk
|
||||
astrundir => /var/run/asterisk
|
||||
astrundir => /run/asterisk
|
||||
astlogdir => /var/log/asterisk
|
||||
astsbindir => ${cfg.package}/sbin
|
||||
'';
|
||||
@ -257,7 +257,7 @@ in
|
||||
ExecReload = ''${cfg.package}/bin/asterisk -x "core reload"
|
||||
'';
|
||||
Type = "forking";
|
||||
PIDFile = "/var/run/asterisk/asterisk.pid";
|
||||
PIDFile = "/run/asterisk/asterisk.pid";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -214,7 +214,7 @@ in
|
||||
|
||||
systemd.sockets.avahi-daemon =
|
||||
{ description = "Avahi mDNS/DNS-SD Stack Activation Socket";
|
||||
listenStreams = [ "/var/run/avahi-daemon/socket" ];
|
||||
listenStreams = [ "/run/avahi-daemon/socket" ];
|
||||
wantedBy = [ "sockets.target" ];
|
||||
};
|
||||
|
||||
@ -229,7 +229,7 @@ in
|
||||
|
||||
path = [ pkgs.coreutils pkgs.avahi ];
|
||||
|
||||
preStart = "mkdir -p /var/run/avahi-daemon";
|
||||
preStart = "mkdir -p /run/avahi-daemon";
|
||||
|
||||
script =
|
||||
''
|
||||
|
@ -25,8 +25,8 @@ let
|
||||
blackhole { badnetworks; };
|
||||
forward first;
|
||||
forwarders { ${concatMapStrings (entry: " ${entry}; ") cfg.forwarders} };
|
||||
directory "/var/run/named";
|
||||
pid-file "/var/run/named/named.pid";
|
||||
directory "/run/named";
|
||||
pid-file "/run/named/named.pid";
|
||||
${cfg.extraOptions}
|
||||
};
|
||||
|
||||
@ -187,8 +187,8 @@ in
|
||||
${pkgs.bind.out}/sbin/rndc-confgen -r /dev/urandom -c /etc/bind/rndc.key -u ${bindUser} -a -A hmac-sha256 2>/dev/null
|
||||
fi
|
||||
|
||||
${pkgs.coreutils}/bin/mkdir -p /var/run/named
|
||||
chown ${bindUser} /var/run/named
|
||||
${pkgs.coreutils}/bin/mkdir -p /run/named
|
||||
chown ${bindUser} /run/named
|
||||
'';
|
||||
|
||||
serviceConfig = {
|
||||
|
@ -25,7 +25,7 @@ let
|
||||
logger_stdout=-1
|
||||
logger_stdout_level=2
|
||||
|
||||
ctrl_interface=/var/run/hostapd
|
||||
ctrl_interface=/run/hostapd
|
||||
ctrl_interface_group=${cfg.group}
|
||||
|
||||
${if cfg.wpa then ''
|
||||
|
@ -62,7 +62,7 @@ in
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
Type = "forking";
|
||||
PIDFile = "/var/run/htpdate.pid";
|
||||
PIDFile = "/run/htpdate.pid";
|
||||
ExecStart = concatStringsSep " " [
|
||||
"${htpdate}/bin/htpdate"
|
||||
"-D -u nobody"
|
||||
|
@ -63,7 +63,7 @@ in
|
||||
passwordFile = mkOption {
|
||||
type = types.str;
|
||||
default = "";
|
||||
description = "File that containts password";
|
||||
description = "File that contains password";
|
||||
};
|
||||
};
|
||||
}));
|
||||
@ -100,7 +100,7 @@ in
|
||||
passwordFile = mkOption {
|
||||
type = types.str;
|
||||
default = "";
|
||||
description = "File that containts password";
|
||||
description = "File that contains password";
|
||||
};
|
||||
};
|
||||
|
||||
@ -120,7 +120,7 @@ in
|
||||
description = "iodine client - ${name}";
|
||||
after = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
script = "${pkgs.iodine}/bin/iodine -f -u ${iodinedUser} ${cfg.extraConfig} ${optionalString (cfg.passwordFile != "") "-P $(cat \"${cfg.passwordFile}\")"} ${cfg.relay} ${cfg.server}";
|
||||
script = "exec ${pkgs.iodine}/bin/iodine -f -u ${iodinedUser} ${cfg.extraConfig} ${optionalString (cfg.passwordFile != "") "< \"${cfg.passwordFile}\""} ${cfg.relay} ${cfg.server}";
|
||||
serviceConfig = {
|
||||
RestartSec = "30s";
|
||||
Restart = "always";
|
||||
@ -136,7 +136,7 @@ in
|
||||
description = "iodine, ip over dns server daemon";
|
||||
after = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
script = "${pkgs.iodine}/bin/iodined -f -u ${iodinedUser} ${cfg.server.extraConfig} ${optionalString (cfg.server.passwordFile != "") "-P $(cat \"${cfg.server.passwordFile}\")"} ${cfg.server.ip} ${cfg.server.domain}";
|
||||
script = "exec ${pkgs.iodine}/bin/iodined -f -u ${iodinedUser} ${cfg.server.extraConfig} ${optionalString (cfg.server.passwordFile != "") "< \"${cfg.server.passwordFile}\""} ${cfg.server.ip} ${cfg.server.domain}";
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -987,7 +987,7 @@ general {
|
||||
* egdpool_path: path to EGD pool. Not necessary for OpenSSL >= 0.9.7
|
||||
* which automatically finds the path.
|
||||
*/
|
||||
# egdpool_path = "/var/run/egd-pool";
|
||||
# egdpool_path = "/run/egd-pool";
|
||||
|
||||
|
||||
/*
|
||||
|
@ -23,7 +23,7 @@ in
|
||||
users.users._lldpd = {
|
||||
description = "lldpd user";
|
||||
group = "_lldpd";
|
||||
home = "/var/run/lldpd";
|
||||
home = "/run/lldpd";
|
||||
isSystemUser = true;
|
||||
};
|
||||
users.groups._lldpd = {};
|
||||
|
@ -71,7 +71,7 @@ in
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.miniupnpd}/bin/miniupnpd -f ${configFile}";
|
||||
PIDFile = "/var/run/miniupnpd.pid";
|
||||
PIDFile = "/run/miniupnpd.pid";
|
||||
Type = "forking";
|
||||
};
|
||||
};
|
||||
|
@ -31,7 +31,7 @@ in
|
||||
udp-port = 443
|
||||
run-as-user = nobody
|
||||
run-as-group = nogroup
|
||||
socket-file = /var/run/ocserv-socket
|
||||
socket-file = /run/ocserv-socket
|
||||
server-cert = certs/server-cert.pem
|
||||
server-key = certs/server-key.pem
|
||||
keepalive = 32400
|
||||
@ -50,7 +50,7 @@ in
|
||||
rekey-time = 172800
|
||||
rekey-method = ssl
|
||||
use-occtl = true
|
||||
pid-file = /var/run/ocserv.pid
|
||||
pid-file = /run/ocserv.pid
|
||||
device = vpns
|
||||
predictable-ips = true
|
||||
default-domain = example.com
|
||||
@ -90,8 +90,8 @@ in
|
||||
|
||||
serviceConfig = {
|
||||
PrivateTmp = true;
|
||||
PIDFile = "/var/run/ocserv.pid";
|
||||
ExecStart = "${pkgs.ocserv}/bin/ocserv --foreground --pid-file /var/run/ocesrv.pid --config /etc/ocserv/ocserv.conf";
|
||||
PIDFile = "/run/ocserv.pid";
|
||||
ExecStart = "${pkgs.ocserv}/bin/ocserv --foreground --pid-file /run/ocesrv.pid --config /etc/ocserv/ocserv.conf";
|
||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||
};
|
||||
};
|
||||
|
@ -32,12 +32,12 @@ in {
|
||||
else cfg.configPath
|
||||
}";
|
||||
ExecReload = "${pkgs.ipsecTools}/bin/racoonctl reload-config";
|
||||
PIDFile = "/var/run/racoon.pid";
|
||||
PIDFile = "/run/racoon.pid";
|
||||
Type = "forking";
|
||||
Restart = "always";
|
||||
};
|
||||
preStart = ''
|
||||
rm /var/run/racoon.pid || true
|
||||
rm /run/racoon.pid || true
|
||||
mkdir -p /var/racoon
|
||||
'';
|
||||
};
|
||||
|
@ -431,8 +431,6 @@ in
|
||||
|
||||
services.openssh.extraConfig = mkOrder 0
|
||||
''
|
||||
Protocol 2
|
||||
|
||||
UsePAM yes
|
||||
|
||||
AddressFamily ${if config.networking.enableIPv6 then "any" else "inet"}
|
||||
|
@ -132,7 +132,7 @@ in
|
||||
extraCmdArgs = mkOption {
|
||||
type = types.str;
|
||||
default = "";
|
||||
example = "-e/var/run/wpa_supplicant/entropy.bin";
|
||||
example = "-e/run/wpa_supplicant/entropy.bin";
|
||||
description =
|
||||
"Command line arguments to add when executing <literal>wpa_supplicant</literal>.";
|
||||
};
|
||||
@ -164,7 +164,7 @@ in
|
||||
|
||||
socketDir = mkOption {
|
||||
type = types.str;
|
||||
default = "/var/run/wpa_supplicant";
|
||||
default = "/run/wpa_supplicant";
|
||||
description = "Directory of sockets for controlling wpa_supplicant.";
|
||||
};
|
||||
|
||||
|
@ -6,7 +6,7 @@ let
|
||||
cfg = config.networking.wireless;
|
||||
configFile = if cfg.networks != {} then pkgs.writeText "wpa_supplicant.conf" ''
|
||||
${optionalString cfg.userControlled.enable ''
|
||||
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=${cfg.userControlled.group}
|
||||
ctrl_interface=DIR=/run/wpa_supplicant GROUP=${cfg.userControlled.group}
|
||||
update_config=1''}
|
||||
${cfg.extraConfig}
|
||||
${concatStringsSep "\n" (mapAttrsToList (ssid: config: with config; let
|
||||
|
@ -17,7 +17,7 @@ let
|
||||
chmod +x $out/startwm.sh
|
||||
|
||||
substituteInPlace $out/xrdp.ini \
|
||||
--replace "#rsakeys_ini=" "rsakeys_ini=/var/run/xrdp/rsakeys.ini" \
|
||||
--replace "#rsakeys_ini=" "rsakeys_ini=/run/xrdp/rsakeys.ini" \
|
||||
--replace "certificate=" "certificate=${cfg.sslCert}" \
|
||||
--replace "key_file=" "key_file=${cfg.sslKey}" \
|
||||
--replace LogFile=xrdp.log LogFile=/dev/null \
|
||||
@ -132,9 +132,9 @@ in
|
||||
chown root:xrdp ${cfg.sslKey} ${cfg.sslCert}
|
||||
chmod 440 ${cfg.sslKey} ${cfg.sslCert}
|
||||
fi
|
||||
if [ ! -s /var/run/xrdp/rsakeys.ini ]; then
|
||||
mkdir -p /var/run/xrdp
|
||||
${cfg.package}/bin/xrdp-keygen xrdp /var/run/xrdp/rsakeys.ini
|
||||
if [ ! -s /run/xrdp/rsakeys.ini ]; then
|
||||
mkdir -p /run/xrdp
|
||||
${cfg.package}/bin/xrdp-keygen xrdp /run/xrdp/rsakeys.ini
|
||||
fi
|
||||
'';
|
||||
serviceConfig = {
|
||||
|
@ -74,7 +74,7 @@ let
|
||||
${concatMapStrings (addr: ''
|
||||
Listen ${addr}
|
||||
'') cfg.listenAddresses}
|
||||
Listen /var/run/cups/cups.sock
|
||||
Listen /run/cups/cups.sock
|
||||
|
||||
SetEnv PATH /var/lib/cups/path/lib/cups/filter:/var/lib/cups/path/bin
|
||||
|
||||
|
@ -100,8 +100,8 @@ in
|
||||
in
|
||||
pkgs.writeText "fcron.conf" ''
|
||||
fcrontabs = /var/spool/fcron
|
||||
pidfile = /var/run/fcron.pid
|
||||
fifofile = /var/run/fcron.fifo
|
||||
pidfile = /run/fcron.pid
|
||||
fifofile = /run/fcron.fifo
|
||||
fcronallow = /etc/fcron.allow
|
||||
fcrondeny = /etc/fcron.deny
|
||||
shell = /bin/sh
|
||||
|
@ -45,7 +45,7 @@ in {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
requires = [ "network-link-dummy0.service" "network-addresses-dummy0.service" ];
|
||||
preStart = ''
|
||||
/run/current-system/sw/bin/rm -fv /var/run/hologram.sock
|
||||
/run/current-system/sw/bin/rm -fv /run/hologram.sock
|
||||
'';
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.hologram.bin}/bin/hologram-agent -debug -conf ${cfgFile} -port ${cfg.httpPort}";
|
||||
|
@ -67,7 +67,7 @@ in
|
||||
path = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
example = "/var/run/codimd.sock";
|
||||
example = "/run/codimd.sock";
|
||||
description = ''
|
||||
Specify where a UNIX domain socket should be placed.
|
||||
'';
|
||||
|
67
nixos/modules/services/web-apps/documize.nix
Normal file
67
nixos/modules/services/web-apps/documize.nix
Normal file
@ -0,0 +1,67 @@
|
||||
{ pkgs, lib, config, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
|
||||
cfg = config.services.documize;
|
||||
|
||||
in
|
||||
|
||||
{
|
||||
options.services.documize = {
|
||||
enable = mkEnableOption "Documize Wiki";
|
||||
|
||||
offline = mkEnableOption "Documize offline mode";
|
||||
|
||||
package = mkOption {
|
||||
default = pkgs.documize-community;
|
||||
type = types.package;
|
||||
description = ''
|
||||
Which package to use for documize.
|
||||
'';
|
||||
};
|
||||
|
||||
db = mkOption {
|
||||
type = types.str;
|
||||
example = "host=localhost port=5432 sslmode=disable user=admin password=secret dbname=documize";
|
||||
description = ''
|
||||
The DB connection string to use for the database.
|
||||
'';
|
||||
};
|
||||
|
||||
dbtype = mkOption {
|
||||
type = types.enum [ "postgresql" "percona" "mariadb" "mysql" ];
|
||||
description = ''
|
||||
Which database to use for storage.
|
||||
'';
|
||||
};
|
||||
|
||||
port = mkOption {
|
||||
type = types.port;
|
||||
example = 3000;
|
||||
description = ''
|
||||
Which TCP port to serve.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
systemd.services.documize-server = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
|
||||
script = ''
|
||||
${cfg.package}/bin/documize \
|
||||
-db "${cfg.db}" \
|
||||
-dbtype ${cfg.dbtype} \
|
||||
-port ${toString cfg.port} \
|
||||
-offline ${if cfg.offline then "1" else "0"}
|
||||
'';
|
||||
|
||||
serviceConfig = {
|
||||
Restart = "always";
|
||||
DynamicUser = "yes";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
@ -32,7 +32,7 @@ let
|
||||
cd ${pkgs.nextcloud}
|
||||
exec /run/wrappers/bin/sudo -u nextcloud \
|
||||
NEXTCLOUD_CONFIG_DIR="${cfg.home}/config" \
|
||||
${config.services.phpfpm.phpPackage}/bin/php \
|
||||
${phpPackage}/bin/php \
|
||||
-c ${pkgs.writeText "php.ini" phpOptionsStr}\
|
||||
occ $*
|
||||
'';
|
||||
@ -360,7 +360,7 @@ in {
|
||||
environment.NEXTCLOUD_CONFIG_DIR = "${cfg.home}/config";
|
||||
serviceConfig.Type = "oneshot";
|
||||
serviceConfig.User = "nextcloud";
|
||||
serviceConfig.ExecStart = "${pkgs.php}/bin/php -f ${pkgs.nextcloud}/cron.php";
|
||||
serviceConfig.ExecStart = "${phpPackage}/bin/php -f ${pkgs.nextcloud}/cron.php";
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -13,7 +13,7 @@ let
|
||||
runDir = "/run/restya-board";
|
||||
|
||||
poolName = "restya-board";
|
||||
phpfpmSocketName = "/var/run/phpfpm/${poolName}.sock";
|
||||
phpfpmSocketName = "/run/phpfpm/${poolName}.sock";
|
||||
|
||||
in
|
||||
|
||||
|
@ -4,7 +4,7 @@ let
|
||||
cfg = config.services.selfoss;
|
||||
|
||||
poolName = "selfoss_pool";
|
||||
phpfpmSocketName = "/var/run/phpfpm/${poolName}.sock";
|
||||
phpfpmSocketName = "/run/phpfpm/${poolName}.sock";
|
||||
|
||||
dataDir = "/var/lib/selfoss";
|
||||
|
||||
|
@ -15,7 +15,7 @@ let
|
||||
else cfg.database.port;
|
||||
|
||||
poolName = "tt-rss";
|
||||
phpfpmSocketName = "/var/run/phpfpm/${poolName}.sock";
|
||||
phpfpmSocketName = "/run/phpfpm/${poolName}.sock";
|
||||
|
||||
tt-rss-config = pkgs.writeText "config.php" ''
|
||||
<?php
|
||||
|
@ -22,7 +22,7 @@ in {
|
||||
User: root
|
||||
# If available, "nobody" is much more secure for Group:.
|
||||
Group: root
|
||||
Pid_File: /var/run/mighty.pid
|
||||
Pid_File: /run/mighty.pid
|
||||
Logging: Yes # Yes or No
|
||||
Log_File: /var/log/mighty # The directory must be writable by User:
|
||||
Log_File_Size: 16777216 # bytes
|
||||
|
@ -20,7 +20,7 @@ in
|
||||
services.xserver.desktopManager.session = [{
|
||||
name = "kodi";
|
||||
start = ''
|
||||
${pkgs.kodi}/bin/kodi --lircdev /var/run/lirc/lircd --standalone &
|
||||
${pkgs.kodi}/bin/kodi --lircdev /run/lirc/lircd --standalone &
|
||||
waitPID=$!
|
||||
'';
|
||||
}];
|
||||
|
@ -116,6 +116,7 @@ in
|
||||
# pantheon has pantheon-agent-geoclue2
|
||||
services.geoclue2.enableDemoAgent = false;
|
||||
services.gnome3.at-spi2-core.enable = true;
|
||||
services.gnome3.evince.enable = mkDefault true;
|
||||
services.gnome3.evolution-data-server.enable = true;
|
||||
services.gnome3.file-roller.enable = mkDefault true;
|
||||
# TODO: gnome-keyring's xdg autostarts will still be in the environment (from elementary-session-settings) if disabled forcefully
|
||||
@ -162,7 +163,6 @@ in
|
||||
gnome3.geary
|
||||
gnome3.epiphany
|
||||
gnome3.gnome-font-viewer
|
||||
evince
|
||||
] ++ pantheon.apps) config.environment.pantheon.excludePackages)
|
||||
++ (with pkgs;
|
||||
[
|
||||
|
@ -221,7 +221,7 @@ in
|
||||
|
||||
services.xserver.displayManager.job.execCmd = ''
|
||||
${optionalString (cfg.pulseaudio)
|
||||
"export PULSE_COOKIE=/var/run/pulse/.config/pulse/cookie"}
|
||||
"export PULSE_COOKIE=/run/pulse/.config/pulse/cookie"}
|
||||
exec ${pkgs.xpra}/bin/xpra start \
|
||||
--daemon=off \
|
||||
--log-dir=/var/log \
|
||||
@ -233,7 +233,7 @@ in
|
||||
--mdns=no \
|
||||
--pulseaudio=no \
|
||||
${optionalString (cfg.pulseaudio) "--sound-source=pulse"} \
|
||||
--socket-dirs=/var/run/xpra \
|
||||
--socket-dirs=/run/xpra \
|
||||
--xvfb="xpra_Xdummy ${concatStringsSep " " dmcfg.xserverArgs}" \
|
||||
${optionalString (cfg.bindTcp != null) "--bind-tcp=${cfg.bindTcp}"} \
|
||||
--auth=${cfg.auth} \
|
||||
|
@ -61,7 +61,7 @@ let
|
||||
inherit (cfg)
|
||||
version extraConfig extraPerEntryConfig extraEntries forceInstall useOSProber
|
||||
extraEntriesBeforeNixOS extraPrepareConfig extraInitrd configurationLimit copyKernels
|
||||
default fsIdentifier efiSupport efiInstallAsRemovable gfxmodeEfi gfxmodeBios;
|
||||
default fsIdentifier efiSupport efiInstallAsRemovable gfxmodeEfi gfxmodeBios gfxpayloadEfi gfxpayloadBios;
|
||||
path = with pkgs; makeBinPath (
|
||||
[ coreutils gnused gnugrep findutils diffutils btrfs-progs utillinux mdadm ]
|
||||
++ optional (cfg.efiSupport && (cfg.version == 2)) efibootmgr
|
||||
@ -393,6 +393,24 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
gfxpayloadEfi = mkOption {
|
||||
default = "keep";
|
||||
example = "text";
|
||||
type = types.str;
|
||||
description = ''
|
||||
The gfxpayload to pass to GRUB when loading a graphical boot interface under EFI.
|
||||
'';
|
||||
};
|
||||
|
||||
gfxpayloadBios = mkOption {
|
||||
default = "text";
|
||||
example = "keep";
|
||||
type = types.str;
|
||||
description = ''
|
||||
The gfxpayload to pass to GRUB when loading a graphical boot interface under BIOS.
|
||||
'';
|
||||
};
|
||||
|
||||
configurationLimit = mkOption {
|
||||
default = 100;
|
||||
example = 120;
|
||||
|
@ -67,6 +67,8 @@ my $efiInstallAsRemovable = get("efiInstallAsRemovable");
|
||||
my $efiSysMountPoint = get("efiSysMountPoint");
|
||||
my $gfxmodeEfi = get("gfxmodeEfi");
|
||||
my $gfxmodeBios = get("gfxmodeBios");
|
||||
my $gfxpayloadEfi = get("gfxpayloadEfi");
|
||||
my $gfxpayloadBios = get("gfxpayloadBios");
|
||||
my $bootloaderId = get("bootloaderId");
|
||||
my $forceInstall = get("forceInstall");
|
||||
my $font = get("font");
|
||||
@ -293,10 +295,10 @@ else {
|
||||
insmod gfxterm
|
||||
if [ \"\${grub_platform}\" = \"efi\" ]; then
|
||||
set gfxmode=$gfxmodeEfi
|
||||
set gfxpayload=keep
|
||||
set gfxpayload=$gfxpayloadEfi
|
||||
else
|
||||
set gfxmode=$gfxmodeBios
|
||||
set gfxpayload=text
|
||||
set gfxpayload=$gfxpayloadBios
|
||||
fi
|
||||
terminal_output gfxterm
|
||||
fi
|
||||
|
@ -31,7 +31,7 @@ in
|
||||
listenOptions =
|
||||
mkOption {
|
||||
type = types.listOf types.str;
|
||||
default = ["/var/run/docker.sock"];
|
||||
default = ["/run/docker.sock"];
|
||||
description =
|
||||
''
|
||||
A list of unix and tcp docker should listen to. The format follows
|
||||
|
@ -49,7 +49,7 @@ in {
|
||||
config = mkIf cfg.enable (let
|
||||
|
||||
# Where the communication sockets live
|
||||
runDir = "/var/run/openvswitch";
|
||||
runDir = "/run/openvswitch";
|
||||
|
||||
# The path to the an initialized version of the database
|
||||
db = pkgs.stdenv.mkDerivation {
|
||||
@ -99,13 +99,13 @@ in {
|
||||
--certificate=db:Open_vSwitch,SSL,certificate \
|
||||
--bootstrap-ca-cert=db:Open_vSwitch,SSL,ca_cert \
|
||||
--unixctl=ovsdb.ctl.sock \
|
||||
--pidfile=/var/run/openvswitch/ovsdb.pid \
|
||||
--pidfile=/run/openvswitch/ovsdb.pid \
|
||||
--detach \
|
||||
/var/db/openvswitch/conf.db
|
||||
'';
|
||||
Restart = "always";
|
||||
RestartSec = 3;
|
||||
PIDFile = "/var/run/openvswitch/ovsdb.pid";
|
||||
PIDFile = "/run/openvswitch/ovsdb.pid";
|
||||
# Use service type 'forking' to correctly determine when ovsdb-server is ready.
|
||||
Type = "forking";
|
||||
};
|
||||
@ -123,10 +123,10 @@ in {
|
||||
serviceConfig = {
|
||||
ExecStart = ''
|
||||
${cfg.package}/bin/ovs-vswitchd \
|
||||
--pidfile=/var/run/openvswitch/ovs-vswitchd.pid \
|
||||
--pidfile=/run/openvswitch/ovs-vswitchd.pid \
|
||||
--detach
|
||||
'';
|
||||
PIDFile = "/var/run/openvswitch/ovs-vswitchd.pid";
|
||||
PIDFile = "/run/openvswitch/ovs-vswitchd.pid";
|
||||
# Use service type 'forking' to correctly determine when vswitchd is ready.
|
||||
Type = "forking";
|
||||
};
|
||||
@ -152,11 +152,11 @@ in {
|
||||
ExecStart = ''
|
||||
${cfg.package}/bin/ovs-monitor-ipsec \
|
||||
--root-prefix ${runDir}/ipsec \
|
||||
--pidfile /var/run/openvswitch/ovs-monitor-ipsec.pid \
|
||||
--pidfile /run/openvswitch/ovs-monitor-ipsec.pid \
|
||||
--monitor --detach \
|
||||
unix:/var/run/openvswitch/db.sock
|
||||
unix:/run/openvswitch/db.sock
|
||||
'';
|
||||
PIDFile = "/var/run/openvswitch/ovs-monitor-ipsec.pid";
|
||||
PIDFile = "/run/openvswitch/ovs-monitor-ipsec.pid";
|
||||
# Use service type 'forking' to correctly determine when ovs-monitor-ipsec is ready.
|
||||
Type = "forking";
|
||||
};
|
||||
@ -167,7 +167,7 @@ in {
|
||||
ln -fs ${pkgs.ipsecTools}/bin/setkey ${runDir}/ipsec/usr/sbin/setkey
|
||||
ln -fs ${pkgs.writeScript "racoon-restart" ''
|
||||
#!${pkgs.runtimeShell}
|
||||
/var/run/current-system/sw/bin/systemctl $1 racoon
|
||||
/run/current-system/sw/bin/systemctl $1 racoon
|
||||
''} ${runDir}/ipsec/etc/init.d/racoon
|
||||
'';
|
||||
};
|
||||
|
@ -65,6 +65,7 @@ in
|
||||
docker-registry = handleTest ./docker-registry.nix {};
|
||||
docker-tools = handleTestOn ["x86_64-linux"] ./docker-tools.nix {};
|
||||
docker-tools-overlay = handleTestOn ["x86_64-linux"] ./docker-tools-overlay.nix {};
|
||||
documize = handleTest ./documize.nix {};
|
||||
dovecot = handleTest ./dovecot.nix {};
|
||||
# ec2-config doesn't work in a sandbox as the simulated ec2 instance needs network access
|
||||
#ec2-config = (handleTestOn ["x86_64-linux"] ./ec2.nix {}).boot-ec2-config or {};
|
||||
@ -193,6 +194,7 @@ in
|
||||
predictable-interface-names = handleTest ./predictable-interface-names.nix {};
|
||||
printing = handleTest ./printing.nix {};
|
||||
prometheus = handleTest ./prometheus.nix {};
|
||||
prometheus2 = handleTest ./prometheus-2.nix {};
|
||||
prometheus-exporters = handleTest ./prometheus-exporters.nix {};
|
||||
prosody = handleTest ./prosody.nix {};
|
||||
proxy = handleTest ./proxy.nix {};
|
||||
|
58
nixos/tests/documize.nix
Normal file
58
nixos/tests/documize.nix
Normal file
@ -0,0 +1,58 @@
|
||||
import ./make-test.nix ({ pkgs, lib, ...} : {
|
||||
name = "documize";
|
||||
meta = with pkgs.stdenv.lib.maintainers; {
|
||||
maintainers = [ ma27 ];
|
||||
};
|
||||
|
||||
machine = { pkgs, ... }: {
|
||||
environment.systemPackages = [ pkgs.jq ];
|
||||
|
||||
services.documize = {
|
||||
enable = true;
|
||||
port = 3000;
|
||||
dbtype = "postgresql";
|
||||
db = "host=localhost port=5432 sslmode=disable user=documize password=documize dbname=documize";
|
||||
};
|
||||
|
||||
systemd.services.documize-server = {
|
||||
after = [ "postgresql.service" ];
|
||||
requires = [ "postgresql.service" ];
|
||||
};
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
initialScript = pkgs.writeText "psql-init" ''
|
||||
CREATE ROLE documize WITH LOGIN PASSWORD 'documize';
|
||||
CREATE DATABASE documize WITH OWNER documize;
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
startAll;
|
||||
|
||||
$machine->waitForUnit("documize-server.service");
|
||||
$machine->waitForOpenPort(3000);
|
||||
|
||||
my $dbhash = $machine->succeed("curl -f localhost:3000 "
|
||||
. " | grep 'property=\"dbhash' "
|
||||
. " | grep -Po 'content=\"\\K[^\"]*'"
|
||||
);
|
||||
|
||||
chomp($dbhash);
|
||||
|
||||
$machine->succeed("curl -X POST "
|
||||
. "--data 'dbname=documize' "
|
||||
. "--data 'dbhash=$dbhash' "
|
||||
. "--data 'title=NixOS' "
|
||||
. "--data 'message=Docs' "
|
||||
. "--data 'firstname=John' "
|
||||
. "--data 'lastname=Doe' "
|
||||
. "--data 'email=john.doe\@nixos.org' "
|
||||
. "--data 'password=verysafe' "
|
||||
. "-f localhost:3000/api/setup"
|
||||
);
|
||||
|
||||
$machine->succeed('test "$(curl -f localhost:3000/api/public/meta | jq ".title" | xargs echo)" = "NixOS"');
|
||||
'';
|
||||
})
|
@ -2,6 +2,8 @@
|
||||
config ? {},
|
||||
pkgs ? import ../.. { inherit system config; },
|
||||
enableUnfree ? false
|
||||
# To run the test on the unfree ELK use the folllowing command:
|
||||
# NIXPKGS_ALLOW_UNFREE=1 nix-build nixos/tests/elk.nix -A ELK-6 --arg enableUnfree true
|
||||
}:
|
||||
|
||||
with import ../lib/testing.nix { inherit system pkgs; };
|
||||
|
@ -1,5 +1,5 @@
|
||||
let
|
||||
nginxRoot = "/var/run/nginx";
|
||||
nginxRoot = "/run/nginx";
|
||||
in
|
||||
import ./make-test.nix ({...}: {
|
||||
name = "nghttpx";
|
||||
|
@ -11,7 +11,7 @@ with lib;
|
||||
machine = {
|
||||
services.osquery.enable = true;
|
||||
services.osquery.loggerPath = "/var/log/osquery/logs";
|
||||
services.osquery.pidfile = "/var/run/osqueryd.pid";
|
||||
services.osquery.pidfile = "/run/osqueryd.pid";
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
@ -23,6 +23,6 @@ with lib;
|
||||
"echo 'SELECT value FROM osquery_flags WHERE name = \"logger_path\";' | osqueryi | grep /var/log/osquery/logs"
|
||||
);
|
||||
|
||||
$machine->succeed("echo 'SELECT value FROM osquery_flags WHERE name = \"pidfile\";' | osqueryi | grep /var/run/osqueryd.pid");
|
||||
$machine->succeed("echo 'SELECT value FROM osquery_flags WHERE name = \"pidfile\";' | osqueryi | grep /run/osqueryd.pid");
|
||||
'';
|
||||
})
|
||||
|
@ -42,7 +42,7 @@ import ./make-test.nix ({pkgs, ... }: {
|
||||
# check local encrypted connections work without error
|
||||
$client->succeed("lpstat -E -r") =~ /scheduler is running/ or die;
|
||||
# Test that UNIX socket is used for connections.
|
||||
$client->succeed("lpstat -H") =~ "/var/run/cups/cups.sock" or die;
|
||||
$client->succeed("lpstat -H") =~ "/run/cups/cups.sock" or die;
|
||||
# Test that HTTP server is available too.
|
||||
$client->succeed("curl --fail http://localhost:631/");
|
||||
$client->succeed("curl --fail http://server:631/");
|
||||
|
34
nixos/tests/prometheus-2.nix
Normal file
34
nixos/tests/prometheus-2.nix
Normal file
@ -0,0 +1,34 @@
|
||||
import ./make-test.nix {
|
||||
name = "prometheus-2";
|
||||
|
||||
nodes = {
|
||||
one = { pkgs, ... }: {
|
||||
services.prometheus2 = {
|
||||
enable = true;
|
||||
scrapeConfigs = [{
|
||||
job_name = "prometheus";
|
||||
static_configs = [{
|
||||
targets = [ "127.0.0.1:9090" ];
|
||||
labels = { instance = "localhost"; };
|
||||
}];
|
||||
}];
|
||||
rules = [
|
||||
''
|
||||
groups:
|
||||
- name: test
|
||||
rules:
|
||||
- record: testrule
|
||||
expr: count(up{job="prometheus"})
|
||||
''
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
startAll;
|
||||
$one->waitForUnit("prometheus2.service");
|
||||
$one->waitForOpenPort(9090);
|
||||
$one->succeed("curl -s http://127.0.0.1:9090/metrics");
|
||||
'';
|
||||
}
|
@ -9,11 +9,11 @@
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
name = "kid3-${version}";
|
||||
version = "3.7.0";
|
||||
version = "3.7.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/project/kid3/kid3/${version}/${name}.tar.gz";
|
||||
sha256 = "1bj4kq9hklgfp81rbxcjzbxmdgxjqksx7cqnw3m9dc0pnns5jx0x";
|
||||
sha256 = "0xkrsjrbr3z8cn8hjf623l28r3b755gr11i0clv8d8i3s10vhbd8";
|
||||
};
|
||||
|
||||
buildInputs = with stdenv.lib;
|
||||
|
@ -2,13 +2,13 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "ltc-tools-${version}";
|
||||
version = "0.6.4";
|
||||
version = "0.7.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "x42";
|
||||
repo = "ltc-tools";
|
||||
rev = "v${version}";
|
||||
sha256 = "1a7r99mwc7p5j5y453mrgph67wlznd674v4k2pfmlvc91s6lh44y";
|
||||
sha256 = "0vp25b970r1hv5ndzs4di63rgwnl31jfaj3jz5dka276kx34q4al";
|
||||
};
|
||||
|
||||
buildInputs = [ pkgconfig libltc libsndfile jack2 ];
|
||||
|
@ -1,11 +1,11 @@
|
||||
{ fetchurl, stdenv, pkgconfig, libao, json_c, libgcrypt, ffmpeg, curl }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "pianobar-2018.06.22";
|
||||
name = "pianobar-2019.02.14";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://6xq.net/projects/pianobar/${name}.tar.bz2";
|
||||
sha256 = "1hnlif62vsxgh8j9mcibxwj4gybpgqc11ba729kflpvvi9qmfqwl";
|
||||
sha256 = "07z21vmlqpmvb3294r384iqbx972rwcx6chrdlkfv4hlnc9h7gf0";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
|
@ -1,14 +1,14 @@
|
||||
{ stdenv, fetchurl, pkgconfig, alsaLib, libjack2, dbus, qtbase, qttools, qtx11extras }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "0.5.5";
|
||||
version = "0.5.6";
|
||||
name = "qjackctl-${version}";
|
||||
|
||||
# some dependencies such as killall have to be installed additionally
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/qjackctl/${name}.tar.gz";
|
||||
sha256 = "1rzzqa39a6llr52vjkjr0a86nc776kmr5xs52qqga8ms9697psz5";
|
||||
sha256 = "0wlmbb9m7cf3wr7c2h2hji18592x2b119m7mx85wksjs6rjaq2mj";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
|
@ -1,12 +1,12 @@
|
||||
{ stdenv, fetchurl, pkgconfig, qt5, alsaLib, libjack2 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "0.5.2";
|
||||
version = "0.5.3";
|
||||
name = "qmidinet-${version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/qmidinet/${name}.tar.gz";
|
||||
sha256 = "0y2w3rymvc35r291sp2qaxn36wjwvxzk2iaw9y30q9fqc0vlpdns";
|
||||
sha256 = "0li6iz1anm8pzz7j12yrfyxlyslsfsksmz0kk0iapa4yx3kifn10";
|
||||
};
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
@ -3,11 +3,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "qsampler-${version}";
|
||||
version = "0.5.3";
|
||||
version = "0.5.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/qsampler/${name}.tar.gz";
|
||||
sha256 = "02xazvz8iaksglbgq3jhw4fq3f5pdcq9sss79jxs082md0mry17d";
|
||||
sha256 = "1hk0j63zzdyji5dd89spbyw79i74n28zjryyy0a4gsaq0m7j2dry";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ autoconf automake libtool pkgconfig qttools ];
|
||||
|
@ -6,11 +6,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "reaper-${version}";
|
||||
version = "5.965";
|
||||
version = "5.973";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.reaper.fm/files/${stdenv.lib.versions.major version}.x/reaper${builtins.replaceStrings ["."] [""] version}_linux_x86_64.tar.xz";
|
||||
sha256 = "05fn7r3v4qcb1b31g8layzvqilrwdr0s8yskr61yvbhx2dnjp9iw";
|
||||
sha256 = "02ymi2rn29zrb71krx43nrpfldhkcvwry4gz228apff2hb2lmqdx";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ autoPatchelfHook makeWrapper ];
|
||||
|
@ -4,11 +4,11 @@
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "snd-18.8";
|
||||
name = "snd-19.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/snd/${name}.tar.gz";
|
||||
sha256 = "16p6cmxl8y58wa19k1z6i66qsqaz7rld4850b0sprbxjjb6cqhf7";
|
||||
sha256 = "1a6ls2hyvggss12idca22hq5vsq4jw2xkwrx22dx29i9926gdr6h";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
|
@ -13,11 +13,11 @@ let
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "SunVox-${version}";
|
||||
version = "1.9.3b";
|
||||
version = "1.9.4c";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.warmplace.ru/soft/sunvox/sunvox-${version}.zip";
|
||||
sha256 = "0k74rcq7niw4p17vj3zp9lpgi932896dmzqv4ln43g0pz7l18c8b";
|
||||
sha256 = "19c1a4e28459e31e1a19986f219d4caa4eb2cb5bc9f6aa994abdbb2ebf6ac4ac";
|
||||
};
|
||||
|
||||
buildInputs = [ unzip ];
|
||||
|
@ -68,5 +68,6 @@ stdenv.mkDerivation rec {
|
||||
license = licenses.unfree;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ michalrus ];
|
||||
broken = true;
|
||||
};
|
||||
}
|
||||
|
@ -4,11 +4,11 @@
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
name = "traverso-${version}";
|
||||
version = "0.49.5";
|
||||
version = "0.49.6";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://traverso-daw.org/traverso-0.49.5.tar.gz";
|
||||
sha256 = "169dsqrf807ciavrd82d3iil0xy0r3i1js08xshcrn80ws9hv63m";
|
||||
url = "http://traverso-daw.org/traverso-0.49.6.tar.gz";
|
||||
sha256 = "12f7x8kw4fw1j0xkwjrp54cy4cv1ql0zwz2ba5arclk4pf6bhl7q";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake pkgconfig ];
|
||||
|
@ -1,10 +1,10 @@
|
||||
{ stdenv, fetchurl, gtk2, glib, gdk_pixbuf, alsaLib, nss, nspr, gconf
|
||||
, cups, libgcrypt_1_5, systemd, dbus }:
|
||||
, cups, libgcrypt_1_5, systemd, dbus, libXdamage, expat }:
|
||||
with stdenv.lib;
|
||||
|
||||
let
|
||||
bracketsLibs = makeLibraryPath [
|
||||
gtk2 glib gdk_pixbuf stdenv.cc.cc.lib alsaLib nss nspr gconf cups libgcrypt_1_5 dbus systemd
|
||||
gtk2 glib gdk_pixbuf stdenv.cc.cc.lib alsaLib nss nspr gconf cups libgcrypt_1_5 dbus systemd libXdamage expat
|
||||
];
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
|
@ -6,10 +6,10 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "sigil-${version}";
|
||||
version = "0.9.12";
|
||||
version = "0.9.13";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
sha256 = "0zlm1jjk91cbrphrilpvxhbm26bbmgy10n7hd0fb1ml8q70q34s3";
|
||||
sha256 = "05wnq7av7fgqgcqd88qjwgn55vr4ciy4f0rgi722f52vy97bw9bj";
|
||||
rev = version;
|
||||
repo = "Sigil";
|
||||
owner = "Sigil-Ebook";
|
||||
|
@ -13,8 +13,8 @@ let
|
||||
else throw "ImageMagick is not supported on this platform.";
|
||||
|
||||
cfg = {
|
||||
version = "7.0.8-22";
|
||||
sha256 = "1ivljgf192xh7pq1apdic923pvcb3aq74mx8d4hi65hhc9748gv7";
|
||||
version = "7.0.8-34";
|
||||
sha256 = "0szkzwy0jzmwx4kqli21jq8pk3s53v37q0nsaqzascs3mpkbza2s";
|
||||
patches = [];
|
||||
};
|
||||
in
|
||||
|
@ -17,10 +17,10 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "drawpile-${version}";
|
||||
version = "2.1.4";
|
||||
version = "2.1.6";
|
||||
src = fetchurl {
|
||||
url = "https://drawpile.net/files/src/drawpile-${version}.tar.gz";
|
||||
sha256 = "0n54p5day6gnmxqmgx4yd7q6y0mgv1nwh84yrz5r953yhd9m37rn";
|
||||
sha256 = "0vwsdvphigrq1daiazi411qflahlvgx8x8ssp581bng2lbq1vrbd";
|
||||
};
|
||||
nativeBuildInputs = [
|
||||
extra-cmake-modules
|
||||
|
@ -47,17 +47,17 @@ let
|
||||
libxkbcommon
|
||||
];
|
||||
in buildRustPackage rec {
|
||||
name = "alacritty-${version}";
|
||||
version = "0.2.9";
|
||||
pname = "alacritty";
|
||||
version = "0.3.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "jwilm";
|
||||
repo = "alacritty";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "01wzkpbz6jjmpmnkqswilnn069ir3cx3jvd3j7zsvqdxqpwncz39";
|
||||
sha256 = "0d9qnymi8v4aqm2p300ccdsgavrnd64sv7v0cz5dp0sp5c0vd7jl";
|
||||
};
|
||||
|
||||
cargoSha256 = "0h9wczgpjh52lhrqg0r2dkrh5svmyvrvh4yj7p0nz45skgrnl8w9";
|
||||
cargoSha256 = "11gpv0h15n12f97mcwjymlzcmkldbakkkb5h931qgm3mvhhq5ay5";
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
@ -92,19 +92,20 @@ in buildRustPackage rec {
|
||||
mkdir $out/Applications
|
||||
cp -r target/release/osx/Alacritty.app $out/Applications/Alacritty.app
|
||||
'' else ''
|
||||
install -D alacritty.desktop $out/share/applications/alacritty.desktop
|
||||
install -D extra/linux/alacritty.desktop -t $out/share/applications/
|
||||
install -D extra/logo/alacritty-term.svg $out/share/icons/hicolor/scalable/apps/Alacritty.svg
|
||||
patchelf --set-rpath "${stdenv.lib.makeLibraryPath rpathLibs}" $out/bin/alacritty
|
||||
'') + ''
|
||||
|
||||
install -D alacritty-completions.zsh "$out/share/zsh/site-functions/_alacritty"
|
||||
install -D alacritty-completions.bash "$out/etc/bash_completion.d/alacritty-completions.bash"
|
||||
install -D alacritty-completions.fish "$out/share/fish/vendor_completions.d/alacritty.fish"
|
||||
install -D extra/completions/_alacritty -t "$out/share/zsh/site-functions/"
|
||||
install -D extra/completions/alacritty.bash -t "$out/etc/bash_completion.d/"
|
||||
install -D extra/completions/alacritty.fish -t "$out/share/fish/vendor_completions.d/"
|
||||
|
||||
install -dm 755 "$out/share/man/man1"
|
||||
gzip -c alacritty.man > "$out/share/man/man1/alacritty.1.gz"
|
||||
gzip -c extra/alacritty.man > "$out/share/man/man1/alacritty.1.gz"
|
||||
|
||||
install -dm 755 "$terminfo/share/terminfo/a/"
|
||||
tic -x -o "$terminfo/share/terminfo" alacritty.info
|
||||
tic -x -o "$terminfo/share/terminfo" extra/alacritty.info
|
||||
mkdir -p $out/nix-support
|
||||
echo "$terminfo" >> $out/nix-support/propagated-user-env-packages
|
||||
|
||||
|
@ -1,14 +1,14 @@
|
||||
{ stdenv, fetchFromGitHub, fftw, ncurses5, libpulseaudio, makeWrapper }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "1.7";
|
||||
version = "1.8";
|
||||
name = "cli-visualizer-${version}";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "dpayne";
|
||||
repo = "cli-visualizer";
|
||||
rev = version;
|
||||
sha256 = "06z6vj87xjmacppcxvgm47wby6mv1hnbqav8lpdk9v5s1hmmp1cr";
|
||||
rev = "v${version}";
|
||||
sha256 = "003mbbwsz43mg3d7llphpypqa9g7rs1p1cdbqi1mbc2bfrc1gcq2";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
|
@ -1,8 +1,8 @@
|
||||
{ stdenv, appimage-run, fetchurl }:
|
||||
{ stdenv, appimage-run, fetchurl, gsettings-desktop-schemas, gtk3, gobject-introspection, wrapGAppsHook }:
|
||||
|
||||
let
|
||||
version = "1.0.140";
|
||||
sha256 = "1114v141jayqhvkkxf7dr864j09nf5nz002c7z0pprzr00fifqzx";
|
||||
version = "1.0.142";
|
||||
sha256 = "0k7lnv3qqz17a2a2d431sic3ggi3373r5k0kwxm4017ama7d72m1";
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "joplin-${version}";
|
||||
@ -12,7 +12,8 @@ in
|
||||
inherit sha256;
|
||||
};
|
||||
|
||||
buildInputs = [ appimage-run ];
|
||||
nativeBuildInputs = [ wrapGAppsHook ];
|
||||
buildInputs = [ appimage-run gtk3 gsettings-desktop-schemas gobject-introspection ];
|
||||
|
||||
unpackPhase = ":";
|
||||
|
||||
|
@ -3,13 +3,13 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "opencpn-${version}";
|
||||
version = "4.8.8";
|
||||
version = "5.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "OpenCPN";
|
||||
repo = "OpenCPN";
|
||||
rev = "v${version}";
|
||||
sha256 = "1z9xfc5fgbdslzak3iqg9nx6wggxwv8qwfxfhvfblkyg6kjw30dg";
|
||||
sha256 = "1xv3h6svw9aay5ixpql231md3pf00qxvhg62z88daraf18hlkfja";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
|
@ -2,14 +2,14 @@
|
||||
|
||||
with python3Packages;
|
||||
buildPythonApplication rec {
|
||||
version = "1.25.1";
|
||||
version = "1.26.0";
|
||||
pname = "rtv";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "michael-lazar";
|
||||
repo = "rtv";
|
||||
rev = "v${version}";
|
||||
sha256 = "0pfsf17g37d2v1xrsbfdbv460vs7m955h6q51z71rhb840r9812p";
|
||||
sha256 = "0smwlhc4sj92365pl7yy6a821xddmh9px43nbd0kdd2z9xrndyx1";
|
||||
};
|
||||
|
||||
# Tests try to access network
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ stdenv, fetchFromGitHub
|
||||
, meson, ninja, pkgconfig, pantheon, gettext, wrapGAppsHook, python3, desktop-file-utils
|
||||
, gtk3, glib, libgee, libgda, gtksourceview, libxml2, libsecret, libfixposix, libssh2 }:
|
||||
, gtk3, glib, libgee, libgda, gtksourceview, libxml2, libsecret, libssh2 }:
|
||||
|
||||
|
||||
let
|
||||
@ -11,18 +11,18 @@ let
|
||||
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "sequeler";
|
||||
version = "0.6.8";
|
||||
version = "0.7.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Alecaddd";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "1rx8h3bi86vk8j7c447pwm590z061js4w45nzrp66r41v0rnh5vk";
|
||||
sha256 = "1x2ikagjsgnhhhwkj09ihln17mq4wjq3wwbnf02j2p3jpp4i8w1i";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ meson ninja pkgconfig pantheon.vala gettext wrapGAppsHook python3 desktop-file-utils ];
|
||||
|
||||
buildInputs = [ gtk3 glib pantheon.granite libgee sqlGda gtksourceview libxml2 libsecret libfixposix libssh2 ];
|
||||
buildInputs = [ gtk3 glib pantheon.granite libgee sqlGda gtksourceview libxml2 libsecret libssh2 ];
|
||||
|
||||
postPatch = ''
|
||||
chmod +x build-aux/meson_post_install.py
|
||||
@ -39,7 +39,7 @@ in stdenv.mkDerivation rec {
|
||||
'';
|
||||
homepage = https://github.com/Alecaddd/sequeler;
|
||||
license = licenses.gpl3;
|
||||
maintainers = [ maintainers.etu ];
|
||||
maintainers = [ maintainers.etu ] ++ pantheon.maintainers;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
|
@ -8,13 +8,13 @@
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
name = "waybar-${version}";
|
||||
version = "0.5.0";
|
||||
version = "0.5.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Alexays";
|
||||
repo = "Waybar";
|
||||
rev = version;
|
||||
sha256 = "006pzx4crsqn9vk28g87306xh3jrfwk4ib9cmsxqrxy8v0kl2s4g";
|
||||
sha256 = "1h3ifiklzcbrvqzzhs7rij8w45k96cir2d4kkyd2ap93akvcnsr9";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
|
@ -8,10 +8,10 @@
|
||||
, libjpeg, zlib, dbus, dbus-glib, bzip2, xorg
|
||||
, freetype, fontconfig, file, nspr, nss, libnotify
|
||||
, yasm, libGLU_combined, sqlite, unzip, makeWrapper
|
||||
, hunspell, libevent, libstartup_notification, libvpx
|
||||
, hunspell, libXdamage, libevent, libstartup_notification, libvpx
|
||||
, icu, libpng, jemalloc, glib
|
||||
, autoconf213, which, gnused, cargo, rustc, llvmPackages
|
||||
, rust-cbindgen, nodejs, nasm
|
||||
, rust-cbindgen, nodejs, nasm, fetchpatch
|
||||
, debugBuild ? false
|
||||
|
||||
### optionals
|
||||
@ -30,11 +30,13 @@
|
||||
, privacySupport ? isTorBrowserLike || isIceCatLike
|
||||
|
||||
# WARNING: NEVER set any of the options below to `true` by default.
|
||||
# Set to `privacySupport` or `false`.
|
||||
# Set to `!privacySupport` or `false`.
|
||||
|
||||
# webrtcSupport breaks the aarch64 build on version >= 60.
|
||||
# webrtcSupport breaks the aarch64 build on version >= 60, fixed in 63.
|
||||
# https://bugzilla.mozilla.org/show_bug.cgi?id=1434589
|
||||
, webrtcSupport ? (if lib.versionAtLeast ffversion "60" && stdenv.isAarch64 then false else !privacySupport)
|
||||
, webrtcSupport ? !privacySupport && (!stdenv.isAarch64 || !(
|
||||
lib.versionAtLeast ffversion "60" && lib.versionOlder ffversion "63"
|
||||
))
|
||||
, geolocationSupport ? !privacySupport
|
||||
, googleAPISupport ? geolocationSupport
|
||||
, crashreporterSupport ? false
|
||||
@ -92,6 +94,15 @@ let
|
||||
|
||||
browserPatches = [
|
||||
./env_var_for_system_dir.patch
|
||||
] ++ lib.optionals (stdenv.isAarch64 && lib.versionAtLeast ffversion "66") [
|
||||
(fetchpatch {
|
||||
url = "https://raw.githubusercontent.com/archlinuxarm/PKGBUILDs/09c7fa0dc1d87922e3b464c0fa084df1227fca79/extra/firefox/arm.patch";
|
||||
sha256 = "1vbpih23imhv5r3g21m3m541z08n9n9j1nvmqax76bmyhn7mxp32";
|
||||
})
|
||||
(fetchpatch {
|
||||
url = "https://raw.githubusercontent.com/archlinuxarm/PKGBUILDs/09c7fa0dc1d87922e3b464c0fa084df1227fca79/extra/firefox/build-arm-libopus.patch";
|
||||
sha256 = "1zg56v3lc346fkzcjjx21vjip2s9hb2xw4pvza1dsfdnhsnzppfp";
|
||||
})
|
||||
] ++ patches;
|
||||
|
||||
in
|
||||
@ -120,6 +131,7 @@ stdenv.mkDerivation rec {
|
||||
icu libpng jemalloc glib
|
||||
]
|
||||
++ lib.optionals (!isTorBrowserLike) [ nspr nss ]
|
||||
++ lib.optional (lib.versionOlder ffversion "53") libXdamage
|
||||
++ lib.optional (lib.versionOlder ffversion "61") hunspell
|
||||
|
||||
# >= 66 requires nasm for the AV1 lib dav1d
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ lib, callPackage, stdenv, fetchurl, fetchFromGitHub, fetchpatch, python3 }:
|
||||
{ lib, callPackage, stdenv, fetchurl, fetchFromGitHub, fetchpatch, python3, overrideCC, gccStdenv, gcc6 }:
|
||||
|
||||
let
|
||||
|
||||
@ -47,7 +47,7 @@ rec {
|
||||
# the web, there are many old useful plugins targeting offline
|
||||
# activities (e.g. ebook readers, syncronous translation, etc) that
|
||||
# will probably never be ported to WebExtensions API.
|
||||
firefox-esr-52 = common rec {
|
||||
firefox-esr-52 = (common rec {
|
||||
pname = "firefox-esr";
|
||||
ffversion = "52.9.0esr";
|
||||
src = fetchurl {
|
||||
@ -65,6 +65,9 @@ rec {
|
||||
description = "A web browser built from Firefox Extended Support Release source tree";
|
||||
knownVulnerabilities = [ "Support ended in August 2018." ];
|
||||
};
|
||||
}).override {
|
||||
stdenv = overrideCC gccStdenv gcc6; # gcc7 fails with "undefined reference to `__divmoddi4'"
|
||||
gtk3Support = false;
|
||||
};
|
||||
|
||||
firefox-esr-60 = common rec {
|
||||
|
@ -2,13 +2,13 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "cni-plugins-${version}";
|
||||
version = "0.7.4";
|
||||
version = "0.7.5";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "containernetworking";
|
||||
repo = "plugins";
|
||||
rev = "v${version}";
|
||||
sha256 = "1sywllwnr6lc812sgkqjdd3y10r82shl88dlnwgnbgzs738q2vp2";
|
||||
sha256 = "1kfi0iz2hs4rq3cdkw12j8d47ac4f5vrpzcwcrs2yzmh2j4n5sz5";
|
||||
};
|
||||
|
||||
buildInputs = [ removeReferencesTo go ];
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, pkgconfig, fetchurl, python, dropbox }:
|
||||
{ stdenv, pkgconfig, fetchurl, python3, dropbox }:
|
||||
let
|
||||
version = "2019.02.14";
|
||||
dropboxd = "${dropbox}/bin/dropbox";
|
||||
@ -12,7 +12,7 @@ stdenv.mkDerivation {
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkgconfig ];
|
||||
buildInputs = [ python ];
|
||||
buildInputs = [ python3 ];
|
||||
|
||||
phases = "unpackPhase installPhase";
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
let
|
||||
stableVersion = "2.1.15";
|
||||
previewVersion = "2.2.0a3";
|
||||
previewVersion = "2.2.0a4";
|
||||
addVersion = args:
|
||||
let version = if args.stable then stableVersion else previewVersion;
|
||||
branch = if args.stable then "stable" else "preview";
|
||||
@ -18,7 +18,7 @@ in {
|
||||
};
|
||||
guiPreview = mkGui {
|
||||
stable = false;
|
||||
sha256Hash = "110mghkhanz92p8vfzyh4199mnihb24smxsc44a8v534ds6hww74";
|
||||
sha256Hash = "1a64c314v7mbaiipyap2skqgf69pyp1ld58cn2g3d89w2zrhf5q7";
|
||||
};
|
||||
|
||||
serverStable = mkServer {
|
||||
@ -27,6 +27,6 @@ in {
|
||||
};
|
||||
serverPreview = mkServer {
|
||||
stable = false;
|
||||
sha256Hash = "104pvrba7n9gp7mx31xg520cfahcy0vsmbzx23007c50kp0nxc56";
|
||||
sha256Hash = "1jlz8a34q3s1sz9r6swh3jnlp96602axnvh1byywry5fb9ga8mfy";
|
||||
};
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
{ stdenv, fetchurl, makeWrapper }:
|
||||
|
||||
let
|
||||
version = "3.6.1";
|
||||
version = "3.7.1";
|
||||
arch = if stdenv.is64bit then "amd64" else "x86";
|
||||
libDir = if stdenv.is64bit then "lib64" else "lib";
|
||||
in
|
||||
@ -15,8 +15,8 @@ stdenv.mkDerivation {
|
||||
"http://teamspeak.gameserver.gamed.de/ts3/releases/${version}/teamspeak3-server_linux_${arch}-${version}.tar.bz2"
|
||||
];
|
||||
sha256 = if stdenv.is64bit
|
||||
then "0wgnb7fdy393anridymm1frlgr86j0awxnzvd498ar5fch06ij87"
|
||||
else "0x6p1z4qvgy464n6gnkaqrm7dns1ysyadm68sr260d39a7028q1c";
|
||||
then "1w60241zsvr8d1qlkca6a1sfxa1jz4w1z9kjd0wd2wkgzp4x91v7"
|
||||
else "0s835dnaw662sb2v5ahqiwry0qjcpl7ff9krnhbw2iblsbqis3fj";
|
||||
};
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
|
@ -2,10 +2,10 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "jmeter-${version}";
|
||||
version = "4.0";
|
||||
version = "5.1";
|
||||
src = fetchurl {
|
||||
url = "https://archive.apache.org/dist/jmeter/binaries/apache-${name}.tgz";
|
||||
sha256 = "1dvngvi6j8qb6nmf5a3gpi5wxck4xisj41qkrj8sjwb1f8jq6nw4";
|
||||
sha256 = "04n7srrg47iyrzhskm2w5g8pd8269kjsly5ixsgifl6aqcbvxpcz";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
@ -10,11 +10,11 @@ let
|
||||
inherit (pythonPackages) python;
|
||||
in pythonPackages.buildPythonApplication rec {
|
||||
name = "mailnag-${version}";
|
||||
version = "1.2.1";
|
||||
version = "1.3.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/pulb/mailnag/archive/v${version}.tar.gz";
|
||||
sha256 = "ec7ac027d93bc7d88fc270858f5a181453a6ff07f43cab20563d185818801fee";
|
||||
sha256 = "0cp5pad6jzd5c14pddbi9ap5bi78wjhk1x2p0gbblmvmcasw309s";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
|
@ -1,8 +1,8 @@
|
||||
{ stdenv, fetchFromGitHub, libiconv }:
|
||||
{ stdenv, fetchFromGitHub, fetchpatch, libiconv }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "mblaze-${version}";
|
||||
version = "0.5";
|
||||
version = "0.5.1";
|
||||
|
||||
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ libiconv ];
|
||||
|
||||
@ -10,9 +10,16 @@ stdenv.mkDerivation rec {
|
||||
owner = "chneukirchen";
|
||||
repo = "mblaze";
|
||||
rev = "v${version}";
|
||||
sha256 = "0fyvydafpz7vmwgn7hc4drm9sb7367smrd07wfyizpas0gmxw2j8";
|
||||
sha256 = "11x548dl2jy9cmgsakqrzfdq166whhk4ja7zkiaxrapkjmkf6pbh";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
url = "https://github.com/leahneukirchen/mblaze/commit/53151f4f890f302291eb8d3375dec4f8ecb66ed7.patch";
|
||||
sha256 = "1mcyrh053iiyzdhgm09g5h3a77np496whnc7jr4agpk1nkbcpfxc";
|
||||
})
|
||||
];
|
||||
|
||||
makeFlags = "PREFIX=$(out)";
|
||||
|
||||
postInstall = ''
|
||||
|
@ -27,16 +27,16 @@ with stdenv.lib;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "mutt-${version}";
|
||||
version = "1.11.3";
|
||||
version = "1.11.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://ftp.mutt.org/pub/mutt/${name}.tar.gz";
|
||||
sha256 = "0h8rmcc62n1pagm7mjjccd5fxyhhi4vbvp8m88digkdf5z0g8hm5";
|
||||
sha256 = "0098pr4anmq2a0id8wfi2vci3cgcfwf9k4q411w22xn8lrz3aldn";
|
||||
};
|
||||
|
||||
patches = optional smimeSupport (fetchpatch {
|
||||
url = "https://salsa.debian.org/mutt-team/mutt/raw/debian/1.11.2-2/debian/patches/misc/smime.rc.patch";
|
||||
sha256 = "1rl27qqwl4nw321ll5jcvfmkmz4fkvcsh5vihjcrhzzyf6vz8wmj";
|
||||
url = "https://salsa.debian.org/mutt-team/mutt/raw/debian/1.10.1-2/debian/patches/misc/smime.rc.patch";
|
||||
sha256 = "0b4i00chvx6zj9pcb06x2jysmrcb2znn831lcy32cgfds6gr3nsi";
|
||||
});
|
||||
|
||||
buildInputs =
|
||||
|
@ -1,16 +1,17 @@
|
||||
{ libsmbios, stdenv, autoreconfHook, fetchFromGitHub }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "netperf-20180504";
|
||||
name = "netperf-${version}";
|
||||
version = "20180613";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "HewlettPackard";
|
||||
repo = "netperf";
|
||||
rev = "c0a0d9f31f9940abf375a41b43a343cdbf87caab";
|
||||
sha256 = "0wfj9kkhar6jb5639f5wxpwsraxw4v9yzg71rsdidvj5fyncjjq2";
|
||||
rev = "bcb868bde7f0203bbab69609f65d4088ba7398db";
|
||||
sha256 = "1wbbgdvhadd3qs3afv6i777argdpcyxkwz4yv6aqp223n8ki6dm8";
|
||||
};
|
||||
|
||||
buildInputs = [ libsmbios ];
|
||||
buildInputs = stdenv.lib.optional (stdenv.hostPlatform.isx86) libsmbios;
|
||||
nativeBuildInputs = [ autoreconfHook ];
|
||||
autoreconfPhase = ''
|
||||
autoreconf -i -I src/missing/m4
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user