summaryrefslogtreecommitdiffstats
path: root/krebs
diff options
context:
space:
mode:
authormakefu <github@syntax-fehler.de>2018-10-07 23:12:16 +0200
committermakefu <github@syntax-fehler.de>2018-10-07 23:12:16 +0200
commit91023a11ebae6794caaecc882892da7f90deea28 (patch)
tree5bfd29cf49b1248cff80c4e001b0bf78b972ff26 /krebs
parent9104af869e8c8ce299fc2ddbf7f2631bbbf48b1e (diff)
parent6b08d5aa46adc80d8a1ab4ed1d3e320c61a19f01 (diff)
Merge remote-tracking branch 'lass/18.09' into 18.09
Diffstat (limited to 'krebs')
-rw-r--r--krebs/2configs/buildbot-stockholm.nix6
-rw-r--r--krebs/2configs/ircd.nix2
-rw-r--r--krebs/3modules/charybdis.nix110
-rw-r--r--krebs/3modules/default.nix2
-rw-r--r--krebs/3modules/git.nix16
-rw-r--r--krebs/3modules/jeschli/default.nix37
-rw-r--r--krebs/3modules/nin/default.nix111
-rw-r--r--krebs/5pkgs/haskell/blessings.nix23
-rw-r--r--krebs/5pkgs/haskell/email-header.nix25
-rw-r--r--krebs/5pkgs/haskell/hyphenation.nix17
-rw-r--r--krebs/5pkgs/simple/buildbot-classic/default.nix2
-rw-r--r--krebs/5pkgs/simple/pass-otp/default.nix30
-rw-r--r--krebs/5pkgs/simple/pass/default.nix121
-rw-r--r--krebs/5pkgs/simple/pass/no-darwin-getopt.patch9
-rw-r--r--krebs/5pkgs/simple/pass/rofi-pass.nix57
-rw-r--r--krebs/5pkgs/simple/pass/set-correct-program-name-for-sleep.patch69
-rw-r--r--krebs/5pkgs/simple/repo-sync/default.nix1
-rw-r--r--krebs/krops.nix5
-rw-r--r--krebs/nixpkgs.json6
19 files changed, 176 insertions, 473 deletions
diff --git a/krebs/2configs/buildbot-stockholm.nix b/krebs/2configs/buildbot-stockholm.nix
index d10fb7203..5784f2cdc 100644
--- a/krebs/2configs/buildbot-stockholm.nix
+++ b/krebs/2configs/buildbot-stockholm.nix
@@ -22,6 +22,12 @@
"http://cgit.ni.r/disko"
"http://cgit.prism.r/disko"
];
+ krops.urls = [
+ "http://cgit.hotdog.r/krops"
+ "http://cgit.ni.r/krops"
+ "http://cgit.prism.r/krops"
+ "https://git.ingolf-wagner.de/krebs/krops.git"
+ ];
nix_writers.urls = [
"http://cgit.hotdog.r/nix-writers"
"http://cgit.ni.r/nix-writers"
diff --git a/krebs/2configs/ircd.nix b/krebs/2configs/ircd.nix
index 962dbf49c..65972aacc 100644
--- a/krebs/2configs/ircd.nix
+++ b/krebs/2configs/ircd.nix
@@ -5,7 +5,7 @@
6667 6669
];
- services.charybdis = {
+ krebs.charybdis = {
enable = true;
motd = ''
hello
diff --git a/krebs/3modules/charybdis.nix b/krebs/3modules/charybdis.nix
new file mode 100644
index 000000000..f4a7c1313
--- /dev/null
+++ b/krebs/3modules/charybdis.nix
@@ -0,0 +1,110 @@
+{ config, lib, pkgs, ... }:
+
+let
+ inherit (lib) mkEnableOption mkIf mkOption singleton types;
+ inherit (pkgs) coreutils charybdis;
+ cfg = config.krebs.charybdis;
+
+ configFile = pkgs.writeText "charybdis.conf" ''
+ ${cfg.config}
+ '';
+in
+
+{
+
+ ###### interface
+
+ options = {
+
+ krebs.charybdis = {
+
+ enable = mkEnableOption "Charybdis IRC daemon";
+
+ config = mkOption {
+ type = types.string;
+ description = ''
+ Charybdis IRC daemon configuration file.
+ '';
+ };
+
+ statedir = mkOption {
+ type = types.string;
+ default = "/var/lib/charybdis";
+ description = ''
+ Location of the state directory of charybdis.
+ '';
+ };
+
+ user = mkOption {
+ type = types.string;
+ default = "ircd";
+ description = ''
+ Charybdis IRC daemon user.
+ '';
+ };
+
+ group = mkOption {
+ type = types.string;
+ default = "ircd";
+ description = ''
+ Charybdis IRC daemon group.
+ '';
+ };
+
+ motd = mkOption {
+ type = types.nullOr types.lines;
+ default = null;
+ description = ''
+ Charybdis MOTD text.
+
+ Charybdis will read its MOTD from /etc/charybdis/ircd.motd .
+ If set, the value of this option will be written to this path.
+ '';
+ };
+
+ };
+
+ };
+
+
+ ###### implementation
+
+ config = mkIf cfg.enable (lib.mkMerge [
+ {
+ users.users = singleton {
+ name = cfg.user;
+ description = "Charybdis IRC daemon user";
+ uid = config.ids.uids.ircd;
+ group = cfg.group;
+ };
+
+ users.groups = singleton {
+ name = cfg.group;
+ gid = config.ids.gids.ircd;
+ };
+
+ systemd.services.charybdis = {
+ description = "Charybdis IRC daemon";
+ wantedBy = [ "multi-user.target" ];
+ environment = {
+ BANDB_DBPATH = "${cfg.statedir}/ban.db";
+ };
+ serviceConfig = {
+ ExecStart = "${charybdis}/bin/charybdis -foreground -logfile /dev/stdout -configfile ${configFile}";
+ Group = cfg.group;
+ User = cfg.user;
+ PermissionsStartOnly = true; # preStart needs to run with root permissions
+ };
+ preStart = ''
+ ${coreutils}/bin/mkdir -p ${cfg.statedir}
+ ${coreutils}/bin/chown ${cfg.user}:${cfg.group} ${cfg.statedir}
+ '';
+ };
+
+ }
+
+ (mkIf (cfg.motd != null) {
+ environment.etc."charybdis/ircd.motd".text = cfg.motd;
+ })
+ ]);
+}
diff --git a/krebs/3modules/default.nix b/krebs/3modules/default.nix
index 6307649e3..8f2e22acf 100644
--- a/krebs/3modules/default.nix
+++ b/krebs/3modules/default.nix
@@ -14,6 +14,7 @@ let
./buildbot/master.nix
./buildbot/slave.nix
./build.nix
+ ./charybdis.nix
./ci.nix
./current.nix
./exim.nix
@@ -111,7 +112,6 @@ let
{ krebs = import ./krebs { inherit config; }; }
{ krebs = import ./lass { inherit config; }; }
{ krebs = import ./makefu { inherit config; }; }
- { krebs = import ./nin { inherit config; }; }
{ krebs = import ./tv { inherit config; }; }
{
krebs.dns.providers = {
diff --git a/krebs/3modules/git.nix b/krebs/3modules/git.nix
index 8a923efd2..f6b4e3c69 100644
--- a/krebs/3modules/git.nix
+++ b/krebs/3modules/git.nix
@@ -121,6 +121,10 @@ let
cgit-settings = types.submodule {
# A setting's value of `null` means cgit's default should be used.
options = {
+ about-filter = mkOption {
+ type = types.nullOr types.package;
+ default = null;
+ };
cache-root = mkOption {
type = types.absolute-pathname;
default = "/tmp/cgit";
@@ -166,6 +170,10 @@ let
types.nullOr (types.enum ["week" "month" "quarter" "year"]);
default = "year";
};
+ readme = mkOption {
+ type = types.listOf types.str;
+ default = [];
+ };
robots = mkOption {
type = types.nullOr (types.listOf types.str);
default = ["nofollow" "noindex"];
@@ -394,8 +402,14 @@ let
kv-to-cgitrc = k: v: getAttr (typeOf v) {
bool = kv-to-cgitrc k (if v then 1 else 0);
null = []; # This will be removed by `flatten`.
- list = "${k}=${concatStringsSep ", " v}";
+ list = {
+ readme = map (x: "readme=${x}") v;
+ }.${k} or "${k}=${concatStringsSep ", " v}";
int = "${k}=${toString v}";
+ set =
+ if subtypes.cgit-settings.check v
+ then "${k}=${v}"
+ else error "kv-to-cgitrc: unhandled type: set";
string = "${k}=${v}";
};
in
diff --git a/krebs/3modules/jeschli/default.nix b/krebs/3modules/jeschli/default.nix
index ab8fe097d..c0cb601bc 100644
--- a/krebs/3modules/jeschli/default.nix
+++ b/krebs/3modules/jeschli/default.nix
@@ -7,43 +7,6 @@ with import <stockholm/lib>;
owner = config.krebs.users.jeschli;
ci = true;
}) {
- bln = {
- nets = {
- retiolum = {
- ip4.addr = "10.243.27.28";
- ip6.addr = "42::28";
- aliases = [
- "bln.r"
- ];
- tinc.pubkey = ''
- -----BEGIN RSA PUBLIC KEY-----
- MIIECgKCBAEAwoN2f6iyQ1Wnk4rZVqhovny8VpwWvC9buE+NoedRaxmWmA5QIP02
- BLwTWFKnbiKOQiYN+a4m/JKs0fFOjYCa2EKhqWWKwdEIN4wJTq8zrjzIaa2rdz+8
- tamE+8rSYDE+RbJ6Gs3SUDfwcxJT6FXCi3JYoirdhAssLSwTf9d5IsfXvkKMabky
- FpY9Im51utmIR8UmYL4Ti7dEaOxif+5Hgl1LuitC8e2IIZJhXJprK9tJk9J0LRWt
- PUM31IG1+A2hNBzs5hferLmmwFvYF1sJ22NtFepxVyOLaLcLEFKWHyU+14qEMSgL
- acsu0lgVZ4A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
- -----END RSA PUBLIC KEY-----
- '';
- };
- };
- };
brauerei = {
nets = {
retiolum = {
diff --git a/krebs/3modules/nin/default.nix b/krebs/3modules/nin/default.nix
deleted file mode 100644
index 1531a2c89..000000000
--- a/krebs/3modules/nin/default.nix
+++ /dev/null
@@ -1,111 +0,0 @@
-{ config, ... }:
-
-with import <stockholm/lib>;
-
-{
- hosts = mapAttrs (_: recursiveUpdate {
- owner = config.krebs.users.nin;
- ci = true;
- }) {
- hiawatha = {
- cores = 2;
- nets = {
- retiolum = {
- ip4.addr = "10.243.132.96";
- ip6.addr = "42:0000:0000:0000:0000:0000:0000:2342";
- aliases = [
- "hiawatha.r"
- ];
- tinc.pubkey = ''
- -----BEGIN RSA PUBLIC KEY-----
- MIIBCgKCAQEAucIe5yLzKJ8F982XRpZT6CvyXuPrtnNTmw/E/T6Oyq88m/OVHh6o
- Viho1XAlJZZwqNniItD0AQB98uFB3+3yA7FepnwwC+PEceIfBG4bTDNyYD3ZCsAB
- iWpmRar9SQ7LFnoZ6X2lYaJkUD9afmvXqJJLR5MClnRQo5OSqXaFdp7ryWinHP7E
- UkPSNByu4LbQ9CnBEW8mmCVZSBLb8ezxg3HpJSigmUcJgiDBJ6aj22BsZ5L+j1Sr
- lvUuaCr8WOS41AYsD5dbTYk7EG42tU5utrOS6z5yHmhbA5r8Ro2OFi/R3Td68BIJ
- yw/m8sfItBCvjJSMEpKHEDfGMBCfQKltCwIDAQAB
- -----END RSA PUBLIC KEY-----
- '';
- };
- };
- ssh.privkey.path = <secrets/ssh.id_ed25519>;
- ssh.pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIFizK5kauDlnjm/IzyzLi+W4hLKqjSWMkfuxzLwg6egx";
- };
- axon= {
- cores = 2;
- nets = {
- retiolum = {
- ip4.addr = "10.243.134.66";
- ip6.addr = "42:0000:0000:0000:0000:0000:0000:1379";
- aliases = [
- "axon.r"
- ];
- tinc.pubkey = ''
- -----BEGIN RSA PUBLIC KEY-----
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HQXpwj3a/JGJYRT6FVbJp4p8PjwAtN9VkpXNl4//3lXQdDD6aQ6ssXaKxVAp2Xj
- FjPjx6J6ok4mRvofKNAREt4eZUdDub34bff6G0zI7Vls9t4ul0uHsJ6+ic3CG+Yl
- buLfOkDp4hVCAlMPQ2NJfWKSggoVao7OTBPTMB3NiM56YOPptfZgu2ttDRTyuQ7p
- hrOwutxoy/abH3hA8bWj1+C23vDtQ2gj0r16SWxpPdb3sselquzKp9NIvtyRVfnG
- yYZTWRHg9mahMC2P0/wWAQVjKb0LnTib4lSe21uqFkWzp+3/Uu+hiwP5xGez/NIi
- ahyL7t0D9r9y+i1RPjYWypgyR568fiGheQIDAQAB
- -----END RSA PUBLIC KEY-----
- '';
- };
- };
- ssh.privkey.path = <secrets/ssh.id_ed25519>;
- ssh.pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF4ubHA2pQzV4tQq9D1zRTD1xOSR6xZM3z6te+5A1ekc";
- };
- onondaga = {
- cores = 1;
- nets = {
- retiolum = {
- ip4.addr = "10.243.132.55";
- ip6.addr = "42:0000:0000:0000:0000:0000:0000:1357";
- aliases = [
- "onondaga.r"
- "cgit.onondaga.r"
- ];
- tinc.pubkey = ''
- -----BEGIN RSA PUBLIC KEY-----
- MIIBCgKCAQEAqj6NPhRVsr8abz9FFx9+ld3amfxN7SRNccbksUOqkufGS0vaupFR
- OWsgj4Qmt3lQ82YVt5yjx0FZHkAsenCEKM3kYoIb4nipT0e1MWkQ7plVveMfGkiu
- htaJ1aCbI2Adxfmk4YbyAr8k3G+Zl9t7gTikBRh7cf5PMiu2JhGUZHzx9urR0ieH
- xyashZFjl4TtIy4q6QTiyST9kfzteh8k7CJ72zfYkdHl9dPlr5Nk22zH9xPkyzmO
- kCNeknuDqKeTT9erNtRLk6pjEcyutt0y2/Uq6iZ38z5qq9k4JzcMuQ3YPpNy8bxn
- hVuk2qBu6kBTUW3iLchoh0d4cfFLWLx1SQIDAQAB
- -----END RSA PUBLIC KEY-----
- '';
- };
- };
- ssh.privkey.path = <secrets/ssh.id_ed25519>;
- ssh.pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGmQk7AXsYLzjUrOjsuhZ3+gT7FjhPtjwxv5XnuU8GJO";
- };
-
- };
- users = {
- nin = {
- mail = "nin@axon.r";
- pubkey = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCl4jHl2dya9Tecot7AcHuk57FiPN0lo8eDa03WmTOCCU7gEJLgpi/zwLxY/K4eXsDgOt8LJwddicgruX2WgIYD3LnwtuN40/U9QqqdBIv/5sYZTcShAK2jyPj0vQJlVUpL7DLxxRH+t4lWeRw/1qaAAVt9jEVbzT5RH233E6+SbXxfnQDhDwOXwD1qfM10BOGh63iYz8/loXG1meb+pkv3HTf5/D7x+/y1XvWRPKuJ2Ml33p2pE3cTd+Tie1O8CREr45I9JOIOKUDQk1klFL5NNXnaQ9h1FRCsnQuoGztoBq8ed6XXL/b8mQ0lqJMxHIoCuDN/HBZYJ0z+1nh8X6XH nin@axon";
- };
- nin_h = {
- mail = "nin@hiawatha.r";
- pubkey = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDicZLUPEVNX7SgqYWcjPo0UESRizEfIvVVbiwa1aApA8x25u/5R3sevcgbIpLHYKDMl5tebny9inr6G2zqB6oq/pocQjHxrPnuLzqjvqeSpbjQjlNWJ9GaHT5koTXZHdkEXGL0vfv1SRDNWUiK0rNymr3GXab4DyrnRnuNl/G1UtLf4Zka94YUD0SSPdS9y6knnRrUWKjGMFBZEbNSgHqMGATPQP9VDwKHIO2OWGfiBAJ4nj/MWj+BxHDleCMY9zbym8yY7p/0PLaUe9eIyLC8MftJ5suuMmASlj+UGWgnqUxWxsMHax9y7CTAc23r1NNCXN5LC6/facGt0rEQrdrTizBgOA1FSHAPCl5f0DBEgWBrRuygEcAueuGWvI8/uvtvQQZLhosDbXEfs/3vm2xoYBe7wH4NZHm+d2LqgIcPXehH9hVQsl6pczngTCJt0Q/6tIMffjhDHeYf6xbe/n3AqFT0PylUSvOw/H5iHws3R6rxtgnOio7yTJ4sq0NMzXCtBY6LYPGnkwf0oKsgB8KavZVnxzF8B1TD4nNi0a7ma7bd1LMzI/oGE6i8kDMROgisIECOcoe8YYJZXIne/wimhhRKZAsd+VrKUo4SzNIavCruCodGAVh2vfrqRJD+HD/aWH7Vr1fCEexquaxeKpRtKGIPW9LRCcEsTilqpZdAiw== nin@hiawatha";
- };
- };
-}
diff --git a/krebs/5pkgs/haskell/blessings.nix b/krebs/5pkgs/haskell/blessings.nix
index f852b4a44..59c5b7984 100644
--- a/krebs/5pkgs/haskell/blessings.nix
+++ b/krebs/5pkgs/haskell/blessings.nix
@@ -1,11 +1,24 @@
-{ mkDerivation, base, fetchgit, stdenv }:
-mkDerivation rec {
+with import <stockholm/lib>;
+{ mkDerivation, base, fetchgit, stdenv }: let
+
+ cfg = {
+ "18.03" = {
+ version = "1.1.0";
+ sha256 = "1k908zap3694fcxdk4bb29s54b0lhdh557y10ybjskfwnym7szn1";
+ };
+ "18.09" = {
+ version = "1.2.0";
+ sha256 = "03hz43ixww0h4fwxqrlrlvmj3pxswhb50ijaapwjz8457il2r300";
+ };
+ }.${versions.majorMinor nixpkgsVersion};
+
+in mkDerivation {
pname = "blessings";
- version = "1.1.0";
+ version = cfg.version;
src = fetchgit {
url = http://cgit.ni.krebsco.de/blessings;
- rev = "refs/tags/v${version}";
- sha256 = "1k908zap3694fcxdk4bb29s54b0lhdh557y10ybjskfwnym7szn1";
+ rev = "refs/tags/v${cfg.version}";
+ sha256 = cfg.sha256;
};
libraryHaskellDepends = [ base ];
doHaddock = false;
diff --git a/krebs/5pkgs/haskell/email-header.nix b/krebs/5pkgs/haskell/email-header.nix
index b54240809..4049168c1 100644
--- a/krebs/5pkgs/haskell/email-header.nix
+++ b/krebs/5pkgs/haskell/email-header.nix
@@ -1,14 +1,29 @@
+with import <stockholm/lib>;
{ mkDerivation, attoparsec, base, base64-bytestring, bytestring
, case-insensitive, containers, exceptions, fetchgit, QuickCheck
, stdenv, tasty, tasty-quickcheck, text, text-icu, time
-}:
-mkDerivation {
+}: let
+
+ cfg = {
+ "18.03" = {
+ version = "0.3.0";
+ rev = "7b179bd31192ead8afe7a0b6e34bcad4039deaa8";
+ sha256 = "12j2n3sbvzjnw99gga7kkdygm8n3qx2lh8q26ad6a53xm5whnz59";
+ };
+ "18.09" = {
+ version = "0.4.1-tv1";
+ rev = "refs/tags/v${cfg.version}";
+ sha256 = "11xjivpj495r2ss9aqljnpzzycb57cm4sr7yzmf939rzwsd3ib0x";
+ };
+ }.${versions.majorMinor nixpkgsVersion};
+
+in mkDerivation {
pname = "email-header";
- version = "0.3.0";
+ version = cfg.version;
src = fetchgit {
url = "https://github.com/4z3/email-header";
- rev = "7b179bd31192ead8afe7a0b6e34bcad4039deaa8";
- sha256 = "12j2n3sbvzjnw99gga7kkdygm8n3qx2lh8q26ad6a53xm5whnz59";
+ rev = cfg.rev;
+ sha256 = cfg.sha256;
};
buildDepends = [
attoparsec base base64-bytestring bytestring case-insensitive
diff --git a/krebs/5pkgs/haskell/hyphenation.nix b/krebs/5pkgs/haskell/hyphenation.nix
deleted file mode 100644
index 6e5fe9455..000000000
--- a/krebs/5pkgs/haskell/hyphenation.nix
+++ /dev/null
@@ -1,17 +0,0 @@
-# Same as upstream but with doCheck = false because doctest has wrong version.
-{ mkDerivation, base, bytestring, containers, directory
-, filepath, unordered-containers, zlib, stdenv
-}:
-mkDerivation {
- pname = "hyphenation";
- version = "0.6";
- sha256 = "2f673666c18f63581422f7c6389b78b0ff754406671296a3d680d417942512f7";
- libraryHaskellDepends = [
- base bytestring containers unordered-containers zlib
- ];
- homepage = "http://github.com/ekmett/hyphenation";
- description = "Configurable Knuth-Liang hyphenation";
- license = stdenv.lib.licenses.bsd3;
- hydraPlatforms = stdenv.lib.platforms.none;
- doCheck = false;
-}
diff --git a/krebs/5pkgs/simple/buildbot-classic/default.nix b/krebs/5pkgs/simple/buildbot-classic/default.nix
index 665b36ab4..c127d2987 100644
--- a/krebs/5pkgs/simple/buildbot-classic/default.nix
+++ b/krebs/5pkgs/simple/buildbot-classic/default.nix
@@ -17,7 +17,7 @@ python2Packages.buildPythonApplication rec {
propagatedBuildInputs = [
python2Packages.jinja2
python2Packages.twisted
- python2Packages.dateutil_1_5
+ python2Packages.dateutil
python2Packages.sqlalchemy_migrate
python2Packages.pysqlite
pkgs.coreutils
diff --git a/krebs/5pkgs/simple/pass-otp/default.nix b/krebs/5pkgs/simple/pass-otp/default.nix
deleted file mode 100644
index 33411180a..000000000
--- a/krebs/5pkgs/simple/pass-otp/default.nix
+++ /dev/null
@@ -1,30 +0,0 @@
-{ stdenv, fetchFromGitHub, oathToolkit }:
-stdenv.mkDerivation rec {
- name = "pass-otp-${version}";
- version = "1.1.0";
-
- src = fetchFromGitHub {
- owner = "tadfisher";
- repo = "pass-otp";
- rev = "v${version}";
- sha256 = "1cgj4zc8fq88n3h6c0vkv9i5al785mdprpgpbv5m22dz9p1wqvbb";
- };
-
- buildInputs = [ oathToolkit ];
-
- patchPhase = ''
- sed -i -e 's|OATH=\$(which oathtool)|OATH=${oathToolkit}/bin/oathtool|' otp.bash
- '';
-
- installPhase = ''
- make PREFIX=$out install
- '';
-
- meta = with stdenv.lib; {
- description = "A pass extension for managing one-time-password (OTP) tokens";
- homepage = https://github.com/tadfisher/pass-otp;
- license = licenses.gpl3;
- maintainers = with maintainers; [ jwiegley tadfisher ];
- platforms = platforms.unix;
- };
-}
diff --git a/krebs/5pkgs/simple/pass/default.nix b/krebs/5pkgs/simple/pass/default.nix
deleted file mode 100644
index c2fe0e1d7..000000000
--- a/krebs/5pkgs/simple/pass/default.nix
+++ /dev/null
@@ -1,121 +0,0 @@
-{ stdenv, lib, fetchurl, fetchFromGitHub
-, coreutils, gnused, getopt, git, tree, gnupg, which, procps, qrencode
-, makeWrapper
-
-, pass-otp
-
-, xclip ? null, xdotool ? null, dmenu ? null
-, x11Support ? !stdenv.isDarwin
-, tombPluginSupport ? false, tomb
-}:
-
-with lib;
-
-assert x11Support -> xclip != null
- && xdotool != null
- && dmenu != null;
-
-let
- plugins = map (p: (fetchFromGitHub {
- owner = "roddhjav";
- repo = "pass-${p.name}";
- inherit (p) rev sha256;
- }))
- ([
- { name = "import";
- rev = "491935bd275f29ceac2b876b3a288011d1ce31e7";
- sha256 = "02mbh05ab8h7kc30hz718d1d1vkjz43b96c7p0xnd92610d2q66q"; }
- { name = "update";
- rev = "cf576c9036fd18efb9ed29e0e9f811207b556fde";
- sha256 = "1hhbrg6a2walrvla6q4cd3pgrqbcrf9brzjkb748735shxfn52hd"; }
- ] ++ stdenv.lib.optional tombPluginSupport {
- name = "tomb";
- rev = "3368134898a42c1b758fabac625ec240e125c6be";
- sha256 = "0qqmxfg4w3r088qhlkhs44036mya82vjflsjjhw2hk8y0wd2i6ds"; }
- );
-
-in stdenv.mkDerivation rec {
- version = "1.7.2";
- name = "password-store-${version}";
-
- src = fetchurl {
- url = "http://git.zx2c4.com/password-store/snapshot/${name}.tar.xz";
- sha256 = "1sl0d7nc85c6c2bmmmyb8rpmn47vhkj831l153mjlkawjvhwas27";
- };
-
- patches = [ ./set-correct-program-name-for-sleep.patch
- ] ++ stdenv.lib.optional stdenv.isDarwin ./no-darwin-getopt.patch;
-
- nativeBuildInputs = [ makeWrapper ];
-
- installFlags = [ "PREFIX=$(out)" "WITH_ALLCOMP=yes" ];
-
- postInstall = ''
- # plugins
- ${stdenv.lib.concatStringsSep "\n" (map (plugin: ''
- pushd ${plugin}
- PREFIX=$out make install
- popd
- '') plugins)}
-
- ln -s \
- ${pass-otp}/lib/password-store/extensions/otp.bash \
- $out/lib/password-store/extensions/
-
- ln -s \
- ${pass-otp}/share/man/man1/pass-otp.1.gz \
- $out/share/man/man1/
-
- # Install Emacs Mode. NOTE: We can't install the necessary
- # dependencies (s.el and f.el) here. The user has to do this
- # himself.
- mkdir -p "$out/share/emacs/site-lisp"
- cp "contrib/emacs/password-store.el" "$out/share/emacs/site-lisp/"
- '' + optionalString x11Support ''
- cp "contrib/dmenu/passmenu" "$out/bin/"
- '';
-
- wrapperPath = with stdenv.lib; makeBinPath ([
- coreutils
- getopt
- git
- gnupg
- gnused
- tree
- which
- qrencode
- ] ++ optional tombPluginSupport tomb
- ++ optional stdenv.isLinux procps
- ++ ifEnable x11Support [ dmenu xclip xdotool ]);
-
- postFixup = ''
- # Fix program name in --help
- substituteInPlace $out/bin/pass \
- --replace 'PROGRAM="''${0##*/}"' "PROGRAM=pass"
-
- # Ensure all dependencies are in PATH
- wrapProgram $out/bin/pass \
- --prefix PATH : "${wrapperPath}"
- '' + stdenv.lib.optionalString x11Support ''
- # We just wrap passmenu with the same PATH as pass. It doesn't
- # need all the tools in there but it doesn't hurt either.
- wrapProgram $out/bin/passmenu \
- --prefix PATH : "$out/bin:${wrapperPath}"
- '';
-
- meta = with stdenv.lib; {
- description = "Stores, retrieves, generates, and synchronizes passwords securely";
- homepage = https://www.passwordstore.org/;
- license = licenses.gpl2Plus;
- maintainers = with maintainers; [ lovek323 the-kenny fpletz ];
- platforms = platforms.unix;
-
- longDescription = ''
- pass is a very simple password store that keeps passwords inside gpg2
- encrypted files inside a simple directory tree residing at
- ~/.password-store. The pass utility provides a series of commands for
- manipulating the password store, allowing the user to add, remove, edit,
- synchronize, generate, and manipulate passwords.
- '';
- };
-}
diff --git a/krebs/5pkgs/simple/pass/no-darwin-getopt.patch b/krebs/5pkgs/simple/pass/no-darwin-getopt.patch
deleted file mode 100644
index e8f7e138f..000000000
--- a/krebs/5pkgs/simple/pass/no-darwin-getopt.patch
+++ /dev/null
@@ -1,9 +0,0 @@
-diff -Naur password-store-1.6.5-orig/src/platform/darwin.sh password-store-1.6.5/src/platform/darwin.sh
---- password-store-1.6.5-orig/src/platform/darwin.sh 2015-01-28 16:43:02.000000000 +0000
-+++ password-store-1.6.5/src/platform/darwin.sh 2015-02-15 16:09:02.000000000 +0000
-@@ -31,5 +31,4 @@
- mount -t hfs -o noatime -o nobrowse "$DARWIN_RAMDISK_DEV" "$SECURE_TMPDIR" || die "Error: could not mount filesystem on ramdisk."
- }
-
--GETOPT="$(brew --prefix gnu-getopt 2>/dev/null || { which port &>/dev/null && echo /opt/local; } || echo /usr/local)/bin/getopt"
- SHRED="srm -f -z"
diff --git a/krebs/5pkgs/simple/pass/rofi-pass.nix b/krebs/5pkgs/simple/pass/rofi-pass.nix
deleted file mode 100644
index 61f51973e..000000000
--- a/krebs/5pkgs/simple/pass/rofi-pass.nix
+++ /dev/null
@@ -1,57 +0,0 @@
-{ stdenv, fetchFromGitHub, pass, rofi, coreutils, utillinux, xdotool, gnugrep
-, libnotify, pwgen, findutils, gawk, gnused, xclip, makeWrapper
-}:
-
-stdenv.mkDerivation rec {
- name = "rofi-pass-${version}";
- version = "1.5.3";
-
- src = fetchFromGitHub {
- owner = "carnager";
- repo = "rofi-pass";
- rev = version;
- sha256 = "1fn1j2rf3abc5qb44zfc8z8ffw6rva4xfp7597hwr1g3szacazpq";
- };
-
- buildInputs = [ makeWrapper ];
-
- dontBuild = true;
-
- installPhase = ''
- mkdir -p $out/bin
- cp -a rofi-pass $out/bin/rofi-pass
-
- mkdir -p $out/share/doc/rofi-pass/
- cp -a config.example $out/share/doc/rofi-pass/config.example
- '';
-
- wrapperPath = with stdenv.lib; makeBinPath [
- coreutils
- findutils
- gawk
- gnugrep
- gnused
- libnotify
- pass
- pwgen
- rofi
- utillinux
- xclip
- xdotool
- ];
-
- fixupPhase = ''
- patchShebangs $out/bin
-
- wrapProgram $out/bin/rofi-pass \
- --prefix PATH : "${wrapperPath}"
- '';
-
- meta = {
- description = "A script to make rofi work with password-store";
- homepage = https://github.com/carnager/rofi-pass;
- maintainers = with stdenv.lib.maintainers; [ the-kenny garbas ];
- license = stdenv.lib.licenses.gpl3;
- platforms = with stdenv.lib.platforms; linux;
- };
-}
diff --git a/krebs/5pkgs/simple/pass/set-correct-program-name-for-sleep.patch b/krebs/5pkgs/simple/pass/set-correct-program-name-for-sleep.patch
deleted file mode 100644
index 782e06e20..000000000
--- a/krebs/5pkgs/simple/pass/set-correct-program-name-for-sleep.patch
+++ /dev/null
@@ -1,69 +0,0 @@
-From 25b44e00ed5df8ffe2782d38ad5cd9f514379599 Mon Sep 17 00:00:00 2001
-From: "Andrew R. M" <andrewmiller237@gmail.com>
-Date: Sat, 8 Apr 2017 13:50:01 -0400
-Subject: [PATCH] Patch the clip() function to work even when using
- single-binary coreutils
-
----
- src/password-store.sh | 4 ++--
- src/platform/cygwin.sh | 4 ++--
- src/platform/darwin.sh | 4 ++--
- 3 files changed, 6 insertions(+), 6 deletions(-)
-
-diff --git a/src/password-store.sh b/src/password-store.sh
-index 6a4172d..4dbd6b8 100755
---- a/src/password-store.sh
-+++ b/src/password-store.sh
-@@ -155,11 +155,11 @@ clip() {
- # variable. Specifically, it cannot store nulls nor (non-trivally) store
- # trailing new lines.
- local sleep_argv0="password store sleep on display $DISPLAY"
-- pkill -f "^$sleep_argv0" 2>/dev/null && sleep 0.5
-+ pkill -P $(pgrep -f "^$sleep_argv0") 2>/dev/null && sleep 0.5
- local before="$(xclip -o -selection "$X_SELECTION" 2>/dev/null | base64)"
- echo -n "$1" | xclip -selection "$X_SELECTION" || die "Error: Could not copy data to the clipboard"
- (
-- ( exec -a "$sleep_argv0" bash <<<"trap 'kill %1' TERM; sleep '$CLIP_TIME' & wait" )
-+ ( exec -a "$sleep_argv0" bash <(echo trap 'kill %1' TERM\; sleep "$CLIP_TIME & wait") )
- local now="$(xclip -o -selection "$X_SELECTION" | base64)"
- [[ $now != $(echo -n "$1" | base64) ]] && before="$now"
-
-diff --git a/src/platform/cygwin.sh b/src/platform/cygwin.sh
-index 6e5dd86..f3574c4 100644
---- a/src/platform/cygwin.sh
-+++ b/src/platform/cygwin.sh
-@@ -3,11 +3,11 @@
-
- clip() {
- local sleep_argv0="password store sleep on display $DISPLAY"
-- pkill -f "^$sleep_argv0" 2>/dev/null && sleep 0.5
-+ pkill -P $(pgrep -f "^$sleep_argv0") 2>/dev/null && sleep 0.5
- local before="$(base64 < /dev/clipboard)"
- echo -n "$1" > /dev/clipboard
- (
-- ( exec -a "$sleep_argv0" sleep "$CLIP_TIME" )
-+ ( exec -a "$sleep_argv0" bash <(echo sleep "$CLIP_TIME") )
- local now="$(base64 < /dev/clipboard)"
- [[ $now != $(echo -n "$1" | base64) ]] && before="$now"
- echo "$before" | base64 -d > /dev/clipboard
-diff --git a/src/platform/darwin.sh b/src/platform/darwin.sh
-index 86eb325..deb04c4 100644
---- a/src/platform/darwin.sh
-+++ b/src/platform/darwin.sh
-@@ -3,11 +3,11 @@
-
- clip() {
- local sleep_argv0="password store sleep for user $(id -u)"
-- pkill -f "^$sleep_argv0" 2>/dev/null && sleep 0.5
-+ pkill -P $(pgrep -f "^$sleep_argv0") 2>/dev/null && sleep 0.5
- local before="$(pbpaste | openssl base64)"
- echo -n "$1" | pbcopy
- (
-- ( exec -a "$sleep_argv0" sleep "$CLIP_TIME" )