2019-02-24 21:52:48 +00:00
|
|
|
{ lib
|
2021-07-20 01:38:55 +00:00
|
|
|
, fetchPypi
|
2019-02-24 21:52:48 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, pycrypto
|
|
|
|
, paramiko
|
|
|
|
, jinja2
|
|
|
|
, pyyaml
|
|
|
|
, httplib2
|
|
|
|
, six
|
|
|
|
, netaddr
|
|
|
|
, dnspython
|
|
|
|
, jmespath
|
|
|
|
, dopy
|
2019-11-20 13:55:07 +00:00
|
|
|
, ncclient
|
2019-02-24 21:52:48 +00:00
|
|
|
, windowsSupport ? false
|
|
|
|
, pywinrm
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "ansible";
|
2021-10-11 17:19:39 +00:00
|
|
|
version = "2.9.27";
|
2019-02-24 21:52:48 +00:00
|
|
|
|
2021-07-20 01:38:55 +00:00
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-10-11 17:19:39 +00:00
|
|
|
sha256 = "sha256-R5FZ5Qs72Qkg0GvFlBDDpR0/m+m04QKeEdHkotBwVzY=";
|
2019-02-24 21:52:48 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
prePatch = ''
|
2019-11-20 13:55:07 +00:00
|
|
|
# ansible-connection is wrapped, so make sure it's not passed
|
|
|
|
# through the python interpreter.
|
|
|
|
sed -i "s/\[python, /[/" lib/ansible/executor/task_executor.py
|
2019-02-24 21:52:48 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
for m in docs/man/man1/*; do
|
|
|
|
install -vD $m -t $out/share/man/man1
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2019-10-17 07:33:37 +00:00
|
|
|
pycrypto paramiko jinja2 pyyaml httplib2
|
2019-11-20 13:55:07 +00:00
|
|
|
six netaddr dnspython jmespath dopy ncclient
|
2019-02-24 21:52:48 +00:00
|
|
|
] ++ lib.optional windowsSupport pywinrm;
|
|
|
|
|
|
|
|
# dificult to test
|
|
|
|
doCheck = false;
|
|
|
|
|
|
|
|
meta = with lib; {
|
2021-08-22 13:24:18 +00:00
|
|
|
homepage = "https://www.ansible.com";
|
2019-02-24 21:52:48 +00:00
|
|
|
description = "Radically simple IT automation";
|
|
|
|
license = [ licenses.gpl3 ] ;
|
2020-05-17 23:40:20 +00:00
|
|
|
maintainers = with maintainers; [ joamaki costrouc hexa ];
|
2019-02-24 21:52:48 +00:00
|
|
|
platforms = platforms.linux ++ platforms.darwin;
|
|
|
|
};
|
|
|
|
}
|