diff options
author | magenbluten <magenbluten@codemonkey.cc> | 2019-05-21 19:52:44 +0200 |
---|---|---|
committer | magenbluten <magenbluten@codemonkey.cc> | 2019-05-21 19:52:44 +0200 |
commit | 09552a6945bd4207c5f44b7aebd7142e7e766d83 (patch) | |
tree | a53914e3f1e286053fc64ad1d87075d2210dae25 /krebs/5pkgs/simple | |
parent | c74d86cf6a1299ba0a11fcfb2341a8632b147420 (diff) | |
parent | 73997358e457b51c72d954546451008560a4adfc (diff) |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'krebs/5pkgs/simple')
-rw-r--r-- | krebs/5pkgs/simple/irc-announce/default.nix | 2 | ||||
-rw-r--r-- | krebs/5pkgs/simple/prison-break/default.nix | 20 | ||||
-rw-r--r-- | krebs/5pkgs/simple/prison-break/straight-plugin.nix | 22 | ||||
-rw-r--r-- | krebs/5pkgs/simple/ssh-audit.nix | 55 |
4 files changed, 98 insertions, 1 deletions
diff --git a/krebs/5pkgs/simple/irc-announce/default.nix b/krebs/5pkgs/simple/irc-announce/default.nix index e1f4919d5..b22e67535 100644 --- a/krebs/5pkgs/simple/irc-announce/default.nix +++ b/krebs/5pkgs/simple/irc-announce/default.nix @@ -15,7 +15,7 @@ pkgs.writeDashBin "irc-announce" '' IRC_SERVER=$1 IRC_PORT=$2 - IRC_NICK=$3$$ + IRC_NICK=$3_$$ IRC_CHANNEL=$4 message=$5 diff --git a/krebs/5pkgs/simple/prison-break/default.nix b/krebs/5pkgs/simple/prison-break/default.nix new file mode 100644 index 000000000..051a46184 --- /dev/null +++ b/krebs/5pkgs/simple/prison-break/default.nix @@ -0,0 +1,20 @@ +{pkgs, fetchFromGitHub}: +with pkgs.python3.pkgs; + +buildPythonPackage rec { + pname = "prison-break"; + version = "1.0.0"; + src = fetchFromGitHub { + owner = "makefu"; + repo = pname; + rev = "1.0.0"; + sha256 = "0ab42z6qr42vz4fc077irn9ykrrylagx1dzlw8dqcanf49dxd961"; + }; + propagatedBuildInputs = [ + docopt + requests + beautifulsoup4 + (callPackage ./straight-plugin.nix {}) + ]; + checkInputs = [ black ]; +} diff --git a/krebs/5pkgs/simple/prison-break/straight-plugin.nix b/krebs/5pkgs/simple/prison-break/straight-plugin.nix new file mode 100644 index 000000000..606c60b5d --- /dev/null +++ b/krebs/5pkgs/simple/prison-break/straight-plugin.nix @@ -0,0 +1,22 @@ +{ lib +, buildPythonPackage +, fetchPypi +}: + +buildPythonPackage rec { + pname = "straight-plugin"; + version = "1.5.0"; + + src = fetchPypi { + pname = "straight.plugin"; + inherit version; + sha256 = "818a7641068932ed6436d0af0a3bb77bbbde29df0a7142c8bd1a249e7c2f0d38"; + }; + + meta = with lib; { + description = "A simple namespaced plugin facility"; + homepage = https://github.com/ironfroggy/straight.plugin; + license = licenses.mit; + maintainers = [ maintainers.makefu ]; + }; +} diff --git a/krebs/5pkgs/simple/ssh-audit.nix b/krebs/5pkgs/simple/ssh-audit.nix new file mode 100644 index 000000000..7d2e6fb34 --- /dev/null +++ b/krebs/5pkgs/simple/ssh-audit.nix @@ -0,0 +1,55 @@ +{ fetchFromGitHub, python3Packages, stdenv }: + +python3Packages.buildPythonPackage rec { + inherit (meta) version; + + pname = "ssh-audit"; + + src = fetchFromGitHub { + owner = "arthepsy"; + repo = pname; + rev = "refs/tags/v${meta.version}"; + sha256 = "0akrychkdym9f6830ysq787c9nc0bkyqvy4h72498lyghwvwc2ms"; + }; + + checkInputs = [ + python3Packages.pytest + python3Packages.pytestcov + ]; + + checkPhase = '' + py.test --cov-report= --cov=ssh-audit -v test + ''; + + postPatch = '' + printf %s "$setupPy" > setup.py + mkdir scripts + cp ssh-audit.py scripts/ssh-audit + mkdir ssh-audit + cp ssh-audit.py ssh-audit/__init__.py + ''; + + setupPy = /* py */ '' + from distutils.core import setup + setup( + author='arthepsy', + description='${meta.description}', + license='${meta.license.spdxId}', + name='${pname}', + packages=['ssh-audit'], + scripts=['scripts/ssh-audit'], + url='${meta.homepage}', + version='${version}', + ) + ''; + + meta = { + description = "tool for ssh server auditing"; + homepage = "https://github.com/arthepsy/ssh-audit"; + license = stdenv.lib.licenses.mit; + maintainers = [ + stdenv.lib.maintainers.tv + ]; + version = "1.7.0"; + }; +} |