gnu: Add python-click-log.
[jackhill/guix/guix.git] / gnu / packages / admin.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
4 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
7 ;;; Copyright © 2015 Alex Sassmannshausen <alex.sassmannshausen@gmail.com>
8 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
9 ;;;
10 ;;; This file is part of GNU Guix.
11 ;;;
12 ;;; GNU Guix is free software; you can redistribute it and/or modify it
13 ;;; under the terms of the GNU General Public License as published by
14 ;;; the Free Software Foundation; either version 3 of the License, or (at
15 ;;; your option) any later version.
16 ;;;
17 ;;; GNU Guix is distributed in the hope that it will be useful, but
18 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;;; GNU General Public License for more details.
21 ;;;
22 ;;; You should have received a copy of the GNU General Public License
23 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24
25 (define-module (gnu packages admin)
26 #:use-module ((guix licenses) #:prefix license:)
27 #:use-module (guix packages)
28 #:use-module (guix utils)
29 #:use-module (guix download)
30 #:use-module (guix git-download)
31 #:use-module (guix build-system cmake)
32 #:use-module (guix build-system gnu)
33 #:use-module (guix build-system python)
34 #:use-module (guix build-system trivial)
35 #:use-module (gnu packages)
36 #:use-module (gnu packages base)
37 #:use-module (gnu packages ncurses)
38 #:use-module (gnu packages readline)
39 #:use-module (gnu packages linux)
40 #:use-module (gnu packages guile)
41 #:use-module (gnu packages gettext)
42 #:use-module (gnu packages perl)
43 #:use-module (gnu packages tcl)
44 #:use-module (gnu packages compression)
45 #:use-module (gnu packages tls)
46 #:use-module (gnu packages gnupg)
47 #:use-module (gnu packages bison)
48 #:use-module (gnu packages flex)
49 #:use-module (gnu packages glib)
50 #:use-module (gnu packages pkg-config)
51 #:use-module (gnu packages popt)
52 #:use-module (gnu packages texinfo)
53 #:use-module (gnu packages groff)
54 #:use-module (gnu packages pciutils)
55 #:use-module (gnu packages libusb)
56 #:use-module (gnu packages libftdi)
57 #:use-module (gnu packages image)
58 #:use-module (gnu packages xorg)
59 #:use-module (gnu packages python)
60 #:use-module (gnu packages man))
61
62 (define-public dmd
63 (let ((base-version "0.2")
64 (patch-level "01"))
65 (package
66 (name "dmd")
67 (version (string-append base-version "." patch-level))
68 (source (origin
69 (method url-fetch)
70 (uri (string-append "ftp://alpha.gnu.org/gnu/dmd/dmd-"
71 base-version ".tar.gz"))
72 (sha256
73 (base32
74 "10fl4k96f17gqx2fv8iw9c61ld26gsk4bbrlfqckdmiimz1k175z"))
75 (patches
76 (list (origin
77 ;; This patch augments 'make-fork+exec-constructor' and
78 ;; is used by a bunch of services.
79 (method url-fetch)
80 (uri (string-append
81 "http://git.savannah.gnu.org/cgit/dmd.git/patch/"
82 "?id=d1d0ff30b3ed2b86b0a3c9bc048d2a855f8e31e6"))
83 (sha256
84 (base32
85 "1lqymypixfiyb72d6bn24m06ry2q1ljnnv0qrc89pbb4z9azaa4d"))
86 (file-name "dmd-user-group.patch"))))))
87 (build-system gnu-build-system)
88 (arguments
89 '(#:configure-flags '("--localstatedir=/var")))
90 (native-inputs `(("pkg-config" ,pkg-config)))
91 (inputs `(("guile" ,guile-2.0)))
92 (synopsis "Daemon managing daemons")
93 (description
94 "GNU DMD is a daemon-managing daemon, meaning that it manages the
95 execution of system services, replacing similar functionality found in
96 typical init systems. It provides dependency-handling through a convenient
97 interface and is based on GNU Guile.")
98 (license license:gpl3+)
99 (home-page "http://www.gnu.org/software/dmd/"))))
100
101 (define-public dfc
102 (package
103 (name "dfc")
104 (version "3.0.4")
105 (source
106 (origin
107 (method url-fetch)
108 (uri (string-append
109 "http://projects.gw-computing.net/attachments/download/79/dfc-"
110 version ".tar.gz"))
111 (sha256
112 (base32
113 "0zk1ppx93ijimf4sbgqilxxikpsa2gmpbynknyh41xy7jbdjxp0b"))))
114 (build-system cmake-build-system)
115 (arguments '(#:tests? #f)) ; There are no tests.
116 (native-inputs `(("gettext" ,gnu-gettext)))
117 (home-page "http://projects.gw-computing.net/projects/dfc")
118 (synopsis "Display file system space usage using graphs and colors")
119 (description
120 "dfc (df color) is a modern version of df. It uses colors, draws pretty
121 graphs and can export its output to different formats.")
122 (license license:bsd-3)))
123
124 (define-public htop
125 (package
126 (name "htop")
127 (version "1.0.3")
128 (source (origin
129 (method url-fetch)
130 (uri (string-append "http://hisham.hm/htop/releases/"
131 version "/htop-" version ".tar.gz"))
132 (sha256
133 (base32
134 "0a8qbpsifzjwc4f45xfwm48jhm59g6q5hlib4bf7z13mgy95fp05"))))
135 (build-system gnu-build-system)
136 (inputs
137 `(("ncurses" ,ncurses)))
138 (home-page "http://htop.sourceforge.net/")
139 (synopsis "Interactive process viewer")
140 (description
141 "This is htop, an interactive process viewer. It is a text-mode
142 application (for console or X terminals) and requires ncurses.")
143 (license license:gpl2)))
144
145 (define-public pies
146 (package
147 (name "pies")
148 (version "1.2")
149 (source
150 (origin
151 (method url-fetch)
152 (uri (string-append "mirror://gnu/pies/pies-"
153 version ".tar.bz2"))
154 (sha256
155 (base32
156 "18w0dbg77i56cx1bwa789w0qi3l4xkkbascxcv2b6gbm0zmjg1g6"))))
157 (build-system gnu-build-system)
158 (home-page "http://www.gnu.org/software/pies/")
159 (synopsis "Program invocation and execution supervisor")
160 (description
161 "GNU pies is a program that supervises the invocation and execution of
162 other programs. It reads the list of programs to be started from its
163 configuration file, executes them, and then monitors their status,
164 re-executing them as necessary.")
165 (license license:gpl3+)))
166
167 (define-public inetutils
168 (package
169 (name "inetutils")
170 (version "1.9.4")
171 (source (origin
172 (method url-fetch)
173 (uri (string-append "mirror://gnu/inetutils/inetutils-"
174 version ".tar.gz"))
175 (sha256
176 (base32
177 "05n65k4ixl85dc6rxc51b1b732gnmm8xnqi424dy9f1nz7ppb3xy"))))
178 (build-system gnu-build-system)
179 (arguments `(;; FIXME: `tftp.sh' relies on `netstat' from utils-linux,
180 ;; which is currently missing.
181 #:tests? #f))
182 (inputs `(("ncurses" ,ncurses)
183 ("readline" ,readline))) ; for 'ftp'
184 (home-page "http://www.gnu.org/software/inetutils/")
185 (synopsis "Basic networking utilities")
186 (description
187 "Inetutils is a collection of common network programs, such as an ftp
188 client and server, a telnet client and server, and an rsh client and server.")
189 (license license:gpl3+)))
190
191 (define-public shadow
192 (package
193 (name "shadow")
194 (version "4.2.1")
195 (source (origin
196 (method url-fetch)
197 (uri (string-append
198 "http://pkg-shadow.alioth.debian.org/releases/"
199 name "-" version ".tar.xz"))
200 (sha256
201 (base32
202 "0h9x1zdbq0pqmygmc1x459jraiqw4gqz8849v268crk78z8r621v"))))
203 (build-system gnu-build-system)
204 (arguments
205 '(;; Assume System V `setpgrp (void)', which is the default on GNU
206 ;; variants (`AC_FUNC_SETPGRP' is not cross-compilation capable.)
207 #:configure-flags '("--with-libpam" "ac_cv_func_setpgrp_void=yes")
208
209 #:phases (alist-cons-before
210 'build 'set-nscd-file-name
211 (lambda* (#:key inputs #:allow-other-keys)
212 ;; Use the right file name for nscd.
213 (let ((libc (assoc-ref inputs "libc")))
214 (substitute* "lib/nscd.c"
215 (("/usr/sbin/nscd")
216 (string-append libc "/sbin/nscd")))))
217 (alist-cons-after
218 'install 'remove-groups
219 (lambda* (#:key outputs #:allow-other-keys)
220 ;; Remove `groups', which is already provided by Coreutils.
221 (let* ((out (assoc-ref outputs "out"))
222 (bin (string-append out "/bin"))
223 (man (string-append out "/share/man")))
224 (delete-file (string-append bin "/groups"))
225 (for-each delete-file (find-files man "^groups\\."))
226 #t))
227 %standard-phases))))
228
229 (inputs (if (string-suffix? "-linux"
230 (or (%current-target-system)
231 (%current-system)))
232 `(("linux-pam" ,linux-pam))
233 '()))
234 (home-page "http://pkg-shadow.alioth.debian.org/")
235 (synopsis "Authentication-related tools such as passwd, su, and login")
236 (description
237 "Shadow provides a number of authentication-related tools, including:
238 login, passwd, su, groupadd, and useradd.")
239
240 ;; The `vipw' program is GPLv2+.
241 ;; libmisc/salt.c is public domain.
242 (license license:bsd-3)))
243
244 (define-public mingetty
245 (package
246 (name "mingetty")
247 (version "1.08")
248 (source (origin
249 (method url-fetch)
250 (uri (string-append "mirror://sourceforge/mingetty/mingetty-"
251 version ".tar.gz"))
252 (sha256
253 (base32
254 "05yxrp44ky2kg6qknk1ih0kvwkgbn9fbz77r3vci7agslh5wjm8g"))))
255 (build-system gnu-build-system)
256 (arguments
257 `(#:phases (alist-replace 'configure
258 (lambda* (#:key inputs outputs
259 #:allow-other-keys)
260 (let* ((out (assoc-ref outputs "out"))
261 (man8 (string-append
262 out "/share/man/man8"))
263 (sbin (string-append out "/sbin"))
264 (shadow (assoc-ref inputs "shadow"))
265 (login (string-append shadow
266 "/bin/login")))
267 (substitute* "Makefile"
268 (("^SBINDIR.*")
269 (string-append "SBINDIR = " out
270 "/sbin\n"))
271 (("^MANDIR.*")
272 (string-append "MANDIR = " out
273 "/share/man/man8\n")))
274
275 ;; Pick the right 'login' by default.
276 (substitute* "mingetty.c"
277 (("\"/bin/login\"")
278 (string-append "\"" login "\"")))
279
280 (mkdir-p sbin)
281 (mkdir-p man8)))
282 %standard-phases)
283 #:tests? #f)) ; no tests
284 (inputs `(("shadow" ,shadow)))
285
286 (home-page "http://sourceforge.net/projects/mingetty")
287 (synopsis "Getty for the text console")
288 (description
289 "Small console getty that is started on the Linux text console,
290 asks for a login name and then transfers over to 'login'. It is extended to
291 allow automatic login and starting any app.")
292 (license license:gpl2+)))
293
294 (define-public net-base
295 (package
296 (name "net-base")
297 (version "5.3")
298 (source (origin
299 (method url-fetch)
300 (uri (string-append
301 "mirror://debian/pool/main/n/netbase/netbase_"
302 version ".tar.xz"))
303 (sha256
304 (base32
305 "12xqjwg3p4rzmmh2iib6sigm9l29y3dgk74mmnw64k84jnbwdxl1"))))
306 (build-system trivial-build-system)
307 (arguments
308 `(#:modules ((guix build utils))
309 #:builder (begin
310 (use-modules (guix build utils)
311 (srfi srfi-26))
312
313 (let* ((source (assoc-ref %build-inputs "source"))
314 (tar (assoc-ref %build-inputs "tar"))
315 (xz (assoc-ref %build-inputs "xz"))
316 (output (assoc-ref %outputs "out"))
317 (etc (string-append output "/etc")))
318 (setenv "PATH" (string-append xz "/bin"))
319 (system* (string-append tar "/bin/tar") "xvf"
320 source)
321 (chdir ,(string-append "netbase-" version))
322 (mkdir-p etc)
323 (for-each copy-file
324 '("etc-services" "etc-protocols" "etc-rpc")
325 (map (cut string-append etc "/" <>)
326 '("services" "protocols" "rpc")))
327 #t))))
328 (native-inputs `(("tar" ,tar)
329 ("xz" ,xz)))
330 (synopsis "IANA protocol, port, and RPC number assignments")
331 (description
332 "This package provides the /etc/services, /etc/protocols, and /etc/rpc
333 files, which contain information about the IANA-assigned port, protocol, and
334 ONC RPC numbers.")
335 (home-page "http://packages.debian.org/sid/netbase")
336 (license license:gpl2)))
337
338 (define-public netcat
339 (package
340 (name "netcat")
341 (version "0.7.1")
342 (source (origin
343 (method url-fetch)
344 (uri (string-append "mirror://sourceforge/netcat/netcat-"
345 version ".tar.bz2"))
346 (sha256
347 (base32
348 "1frjcdkhkpzk0f84hx6hmw5l0ynpmji8vcbaxg8h5k2svyxz0nmm"))))
349 (build-system gnu-build-system)
350 (arguments
351 `(#:configure-flags
352 ;; By default, man and info pages are put in PREFIX/{man,info},
353 ;; but we want them in PREFIX/share/{man,info}.
354 (let ((out (assoc-ref %outputs "out")))
355 (list (string-append "--mandir=" out "/share/man")
356 (string-append "--infodir=" out "/share/info")))))
357 (home-page "http://netcat.sourceforge.net")
358 (synopsis "Read and write data over TCP/IP")
359 (description
360 "Netcat is a featured networking utility which reads and writes data
361 across network connections, using the TCP/IP protocol. It is designed to be a
362 reliable \"back-end\" tool that can be used directly or easily driven by other
363 programs and scripts. At the same time, it is a feature-rich network debugging
364 and exploration tool, since it can create almost any kind of connection you
365 would need and has several interesting built-in capabilities.")
366 (license license:gpl2+)))
367
368 (define-public alive
369 (package
370 (name "alive")
371 (version "2.0.2")
372 (source (origin
373 (method url-fetch)
374 (uri (string-append "mirror://gnu/alive/alive-"
375 version ".tar.xz"))
376 (sha256
377 (base32
378 "1vrzg51ai68x9yld7vbgl58sxaw5qpx8rbakwcxn4cqq6vpxj38j"))))
379 (build-system gnu-build-system)
380 (arguments '(#:configure-flags '("alive_cv_nice_ping=yes")))
381 (inputs `(("guile" ,guile-2.0)
382 ("inetutils" ,inetutils)))
383 (home-page "http://www.gnu.org/software/alive/")
384 (synopsis "Autologin and keep-alive daemon")
385 (description
386 "GNU Alive sends periodic pings to a server, generally to keep a
387 connection alive.")
388 (license license:gpl3+)))
389
390 (define-public isc-dhcp
391 (let* ((bind-major-version "9")
392 (bind-minor-version "9")
393 (bind-patch-version "8")
394 (bind-release-type "-P")
395 (bind-release-version "2")
396 (bind-version (string-append bind-major-version
397 "."
398 bind-minor-version
399 "."
400 bind-patch-version
401 bind-release-type
402 bind-release-version)))
403 (package
404 (name "isc-dhcp")
405 (version "4.3.3-P1")
406 (source (origin
407 (method url-fetch)
408 (uri (string-append "http://ftp.isc.org/isc/dhcp/"
409 version "/dhcp-" version ".tar.gz"))
410 (sha256
411 (base32
412 "08crcsmg4dm2v533aq3883ik8mf4vvvd6r998r4vrgx1zxnqj7n1"))))
413 (build-system gnu-build-system)
414 (arguments
415 `(#:parallel-build? #f
416 #:phases
417 (modify-phases %standard-phases
418 (add-after 'unpack 'replace-bundled-bind
419 (lambda* (#:key inputs #:allow-other-keys)
420 (delete-file "bind/bind.tar.gz")
421 (copy-file (assoc-ref inputs "bind-source-tarball")
422 "bind/bind.tar.gz")
423 (chmod "bind/bind.tar.gz" #o644)
424 (substitute* "bind/version.tmp"
425 (("^MAJORVER=.*")
426 (format #f "MAJORVER=~a\n" ,bind-major-version))
427 (("^MINORVER=.*")
428 (format #f "MINORVER=~a\n" ,bind-minor-version))
429 (("^PATCHVER=.*")
430 (format #f "PATCHVER=~a\n" ,bind-patch-version))
431 (("^RELEASETYPE=.*")
432 (format #f "RELEASETYPE=~a\n" ,bind-release-type))
433 (("^RELEASEVER=.*")
434 (format #f "RELEASEVER=~a\n" ,bind-release-version)))
435 #t))
436 (add-after 'configure 'post-configure
437 (lambda* (#:key outputs #:allow-other-keys)
438 ;; Point to the right client script, which will be
439 ;; installed in a later phase.
440 (substitute* "includes/dhcpd.h"
441 (("#define[[:blank:]]+_PATH_DHCLIENT_SCRIPT.*")
442 (let ((out (assoc-ref outputs "out")))
443 (string-append "#define _PATH_DHCLIENT_SCRIPT \""
444 out "/libexec/dhclient-script"
445 "\"\n"))))
446
447 ;; During the 'build' phase, 'bind.tar.gz' is extracted, so
448 ;; we must patch shebangs in there and make sure the right
449 ;; shell is used.
450 (with-directory-excursion "bind"
451 (substitute* "Makefile"
452 (("\\./configure")
453 (let ((sh (which "sh")))
454 (string-append "./configure CONFIG_SHELL="
455 sh " SHELL=" sh))))
456
457 (let ((bind-directory (string-append "bind-" ,bind-version)))
458 (system* "tar" "xf" "bind.tar.gz")
459 (for-each patch-shebang
460 (find-files bind-directory ".*"))
461 (zero? (system* "tar" "cf" "bind.tar.gz"
462 bind-directory
463 ;; avoid non-determinism in the archive
464 "--sort=name"
465 "--mtime=@0"
466 "--owner=root:0"
467 "--group=root:0"))))))
468 (add-after 'install 'post-install
469 (lambda* (#:key inputs outputs #:allow-other-keys)
470 ;; Install the dhclient script for GNU/Linux and make sure
471 ;; if finds all the programs it needs.
472 (let* ((out (assoc-ref outputs "out"))
473 (libexec (string-append out "/libexec"))
474 (coreutils (assoc-ref inputs "coreutils"))
475 (inetutils (assoc-ref inputs "inetutils"))
476 (net-tools (assoc-ref inputs "net-tools"))
477 (sed (assoc-ref inputs "sed")))
478 (substitute* "client/scripts/linux"
479 (("/sbin/ip")
480 (string-append (assoc-ref inputs "iproute")
481 "/sbin/ip")))
482
483 (mkdir-p libexec)
484 (copy-file "client/scripts/linux"
485 (string-append libexec "/dhclient-script"))
486
487 (wrap-program
488 (string-append libexec "/dhclient-script")
489 `("PATH" ":" prefix
490 ,(map (lambda (dir)
491 (string-append dir "/bin:"
492 dir "/sbin"))
493 (list inetutils net-tools coreutils sed))))))))))
494
495 (native-inputs `(("perl" ,perl)))
496
497 (inputs `(("inetutils" ,inetutils)
498 ("net-tools" ,net-tools)
499 ("iproute" ,iproute)
500
501 ;; XXX isc-dhcp bundles a copy of bind that has security
502 ;; flaws, so we use a newer version.
503 ("bind-source-tarball"
504 ,(origin
505 (method url-fetch)
506 (uri (string-append "http://ftp.isc.org/isc/bind9/"
507 bind-version
508 "/bind-" bind-version ".tar.gz"))
509 (sha256
510 (base32
511 "0agkpmpna7s67la13krn4xlhwhdjpazmljxlq0zbjdwnw4k1k17m"))))
512
513 ;; When cross-compiling, we need the cross Coreutils and sed.
514 ;; Otherwise just use those from %FINAL-INPUTS.
515 ,@(if (%current-target-system)
516 `(("coreutils" ,coreutils)
517 ("sed" ,sed))
518 '())))
519
520 (home-page "http://www.isc.org/products/DHCP/")
521 (synopsis "Dynamic Host Configuration Protocol (DHCP) tools")
522 (description
523 "ISC's Dynamic Host Configuration Protocol (DHCP) distribution provides a
524 reference implementation of all aspects of DHCP, through a suite of DHCP
525 tools: server, client, and relay agent.")
526 (license license:isc))))
527
528 (define-public libpcap
529 (package
530 (name "libpcap")
531 (version "1.7.4")
532 (source (origin
533 (method url-fetch)
534 (uri (string-append "http://www.tcpdump.org/release/libpcap-"
535 version ".tar.gz"))
536 (sha256
537 (base32
538 "1c28ykkizd7jqgzrfkg7ivqjlqs9p6lygp26bsw2i0z8hwhi3lvs"))))
539 (build-system gnu-build-system)
540 (native-inputs `(("bison" ,bison) ("flex" ,flex)))
541 (arguments '(#:configure-flags '("--with-pcap=linux")
542 #:tests? #f)) ; no 'check' target
543 (home-page "http://www.tcpdump.org")
544 (synopsis "Network packet capture library")
545 (description
546 "libpcap is an interface for user-level packet capture. It provides a
547 portable framework for low-level network monitoring. Applications include
548 network statistics collection, security monitoring, network debugging, etc.")
549
550 ;; fad-*.c and a couple other files are BSD-4, but the rest is BSD-3.
551 (license license:bsd-3)))
552
553 (define-public tcpdump
554 (package
555 (name "tcpdump")
556 (version "4.7.4")
557 (source (origin
558 (method url-fetch)
559 (uri (string-append "http://www.tcpdump.org/release/tcpdump-"
560 version ".tar.gz"))
561 (sha256
562 (base32
563 "1byr8w6grk08fsq0444jmcz9ar89lq9nf4mjq2cny0w9k8k21rbb"))))
564 (build-system gnu-build-system)
565 (inputs `(("libpcap" ,libpcap)
566 ("openssl" ,openssl)))
567 (native-inputs `(("perl" ,perl))) ; for tests
568 (home-page "http://www.tcpdump.org/")
569 (synopsis "Network packet analyzer")
570 (description
571 "Tcpdump is a command-line tool to analyze network traffic passing
572 through the network interface controller.")
573 (license license:bsd-3)))
574
575 (define-public jnettop
576 (package
577 (name "jnettop")
578 (version "0.13.0")
579 (source (origin
580 (method url-fetch)
581 (uri (string-append "http://jnettop.kubs.info/dist/jnettop-"
582 version ".tar.gz"))
583 (sha256
584 (base32
585 "1855np7c4b0bqzhf1l1dyzxb90fpnvrirdisajhci5am6als31z9"))))
586 (build-system gnu-build-system)
587 (native-inputs
588 `(("pkg-config" ,pkg-config)))
589 (inputs
590 `(("glib" ,glib)
591 ("ncurses" ,ncurses)
592 ("libpcap" ,libpcap)))
593 (home-page "http://jnettop.kubs.info/")
594 (synopsis "Visualize network traffic by bandwidth use")
595 (description
596 "Jnettop is a traffic visualiser, which captures traffic going
597 through the host it is running from and displays streams sorted
598 by bandwidth they use.")
599 (license license:gpl2+)))
600
601 (define-public clusterssh
602 (package
603 (name "clusterssh")
604 (version "3.28")
605 (source (origin
606 (method url-fetch)
607 (uri (string-append "mirror://sourceforge/clusterssh/"
608 "clusterssh-" version ".tar.gz"))
609 (sha256
610 (base32
611 "1bwggpvaj2al5blg1ynapviv2kpydffpzq2zkhi81najnvzc1rr7"))))
612 (build-system gnu-build-system)
613 (inputs `(("perl" ,perl)))
614 (propagated-inputs `(("xterm" ,xterm)
615 ("perl-tk" ,perl-tk)
616 ("perl-x11-protocol" ,perl-x11-protocol)))
617 (arguments
618 `(#:phases
619 (alist-cons-after
620 'install 'set-load-paths
621 (lambda* (#:key inputs outputs #:allow-other-keys)
622 ;; Put the perl-tk and perl-x11-protocol modules in the perl inc
623 ;; path for PROG
624 (let* ((out (assoc-ref outputs "out"))
625 (prog (string-append out "/bin/cssh"))
626 (perl-ver ,(package-version perl))
627 (x11-inc (string-append
628 (assoc-ref inputs "perl-x11-protocol")
629 "/lib/perl5/site_perl/" perl-ver))
630 (tk-inc (string-append
631 (assoc-ref inputs "perl-tk")
632 "/lib/perl5/site_perl/" perl-ver
633 "/x86_64-linux")))
634 (wrap-program
635 prog
636 `("PERL5LIB" ":" prefix (,x11-inc ,tk-inc)))))
637 %standard-phases)))
638 ;; The clusterssh.sourceforge.net address requires login to view
639 (home-page "http://sourceforge.net/projects/clusterssh/")
640 (synopsis "Secure concurrent multi-server terminal control")
641 (description
642 "ClusterSSH controls a number of xterm windows via a single graphical
643 console window to allow commands to be interactively run on multiple servers
644 over ssh connections.")
645 (license license:gpl2+)))
646
647 (define-public rottlog
648 (package
649 (name "rottlog")
650 (version "0.72.2")
651 (source (origin
652 (method url-fetch)
653 (uri (string-append "mirror://gnu/rottlog/rottlog-"
654 version ".tar.gz"))
655 (sha256
656 (base32
657 "0751mb9l2f0jrk3vj6q8ilanifd121dliwk0c34g8k0dlzsv3kd7"))
658 (modules '((guix build utils)))
659 (snippet
660 '(substitute* "Makefile.in"
661 (("-o \\$\\{LOG_OWN\\} -g \\$\\{LOG_GROUP\\}")
662 ;; Don't try to chown root.
663 "")
664 (("mkdir -p \\$\\(ROTT_STATDIR\\)")
665 ;; Don't attempt to create /var/lib/rottlog.
666 "true")))))
667 (build-system gnu-build-system)
668 (arguments
669 '(#:configure-flags (list (string-append "ROTT_ETCDIR="
670 (assoc-ref %outputs "out")
671 "/etc")
672 "--localstatedir=/var")
673 #:phases (alist-cons-after
674 'install 'install-info
675 (lambda _
676 (zero? (system* "make" "install-info")))
677 %standard-phases)))
678 (native-inputs `(("texinfo" ,texinfo)
679 ("util-linux" ,util-linux))) ; for 'cal'
680 (home-page "http://www.gnu.org/software/rottlog/")
681 (synopsis "Log rotation and management")
682 (description
683 "GNU Rot[t]log is a program for managing log files. It is used to
684 automatically rotate out log files when they have reached a given size or
685 according to a given schedule. It can also be used to automatically compress
686 and archive such logs. Rot[t]log will mail reports of its activity to the
687 system administrator.")
688 (license license:gpl3+)))
689
690 (define-public sudo
691 (package
692 (name "sudo")
693 (version "1.8.15")
694 (source (origin
695 (method url-fetch)
696 (uri
697 (list (string-append "http://www.sudo.ws/sudo/dist/sudo-"
698 version ".tar.gz")
699 (string-append "ftp://ftp.sudo.ws/pub/sudo/OLD/sudo-"
700 version ".tar.gz")))
701 (sha256
702 (base32
703 "0263gi6i19fyzzc488n0qw3m518i39f6a7qmrfvahk9j10bkh5j3"))
704 (patches (list (search-patch "sudo-CVE-2015-5602.patch")))))
705 (build-system gnu-build-system)
706 (arguments
707 `(#:configure-flags
708 (list "--with-logpath=/var/log/sudo.log"
709 "--with-rundir=/var/run/sudo" ;must be cleaned up at boot time
710 "--with-vardir=/var/db/sudo"
711 "--with-iologdir=/var/log/sudo-io"
712
713 ;; 'visudo.c' expects _PATH_MV to be defined, but glibc doesn't
714 ;; provide it.
715 (string-append "CPPFLAGS=-D_PATH_MV='\""
716 (assoc-ref %build-inputs "coreutils")
717 "/bin/mv\"'"))
718
719 ;; Avoid non-determinism; see <http://bugs.gnu.org/21918>.
720 #:parallel-build? #f
721
722 #:phases (alist-cons-before
723 'configure 'pre-configure
724 (lambda _
725 (substitute* "src/sudo_usage.h.in"
726 ;; Do not capture 'configure' arguments since we would
727 ;; unduly retain references, and also because the
728 ;; CPPFLAGS above would close the string literal
729 ;; prematurely.
730 (("@CONFIGURE_ARGS@") "\"\""))
731 (substitute* (find-files "." "Makefile\\.in")
732 (("-o [[:graph:]]+ -g [[:graph:]]+")
733 ;; Allow installation as non-root.
734 "")
735 (("^install: (.*)install-sudoers(.*)" _ before after)
736 ;; Don't try to create /etc/sudoers.
737 (string-append "install: " before after "\n"))
738 (("\\$\\(DESTDIR\\)\\$\\(rundir\\)")
739 ;; Don't try to create /run/sudo.
740 "$(TMPDIR)/dummy")
741 (("\\$\\(DESTDIR\\)\\$\\(vardir\\)")
742 ;; Don't try to create /var/db/sudo.
743 "$(TMPDIR)/dummy")))
744 %standard-phases)
745
746 ;; XXX: The 'testsudoers' test series expects user 'root' to exist, but
747 ;; the chroot's /etc/passwd doesn't have it. Turn off the tests.
748 #:tests? #f))
749 (inputs
750 `(("groff" ,groff)
751 ("linux-pam" ,linux-pam)
752 ("coreutils" ,coreutils)))
753 (home-page "http://www.sudo.ws/")
754 (synopsis "Run commands as root")
755 (description
756 "Sudo (su \"do\") allows a system administrator to delegate authority to
757 give certain users (or groups of users) the ability to run some (or all)
758 commands as root or another user while providing an audit trail of the
759 commands and their arguments.")
760
761 ;; See <http://www.sudo.ws/sudo/license.html>.
762 (license license:x11)))
763
764 (define-public wpa-supplicant-minimal
765 (package
766 (name "wpa-supplicant-minimal")
767 (version "2.5")
768 (source (origin
769 (method url-fetch)
770 (uri (string-append
771 "http://w1.fi/releases/wpa_supplicant-"
772 version
773 ".tar.gz"))
774 (sha256
775 (base32
776 "05mkp5bx1c3z7h5biddsv0p49gkrq9ksany3anp4wdiv92p5prfc"))
777 (patches
778 (map search-patch '("wpa-supplicant-CVE-2015-5310.patch"
779 "wpa-supplicant-CVE-2015-5314.patch"
780 "wpa-supplicant-CVE-2015-5315.patch"
781 "wpa-supplicant-CVE-2015-5316.patch")))))
782 (build-system gnu-build-system)
783 (arguments
784 '(#:phases (alist-replace
785 'configure
786 (lambda* (#:key outputs #:allow-other-keys)
787 (chdir "wpa_supplicant")
788 (copy-file "defconfig" ".config")
789 (let ((port (open-file ".config" "al")))
790 (display "
791 CONFIG_DEBUG_SYSLOG=y
792
793 # Choose GnuTLS (the default is OpenSSL.)
794 CONFIG_TLS=gnutls
795
796 CONFIG_DRIVER_NL80211=y
797 CFLAGS += $(shell pkg-config libnl-3.0 --cflags)
798 CONFIG_LIBNL32=y
799 CONFIG_READLINE=y\n" port)
800 (close-port port)))
801
802 (alist-cons-after
803 'install 'install-man-pages
804 (lambda* (#:key outputs #:allow-other-keys)
805 (let* ((out (assoc-ref outputs "out"))
806 (man (string-append out "/share/man"))
807 (man5 (string-append man "/man5"))
808 (man8 (string-append man "/man8")))
809 (define (copy-man-page target)
810 (lambda (file)
811 (copy-file file
812 (string-append target "/"
813 (basename file)))))
814
815 (mkdir-p man5) (mkdir man8)
816 (for-each (copy-man-page man5)
817 (find-files "doc/docbook" "\\.5"))
818 (for-each (copy-man-page man8)
819 (find-files "doc/docbook" "\\.8"))
820 #t))
821 %standard-phases))
822
823 #:make-flags (list "CC=gcc"
824 (string-append "BINDIR=" (assoc-ref %outputs "out")
825 "/sbin")
826 (string-append "LIBDIR=" (assoc-ref %outputs "out")
827 "/lib"))
828 #:tests? #f))
829 (inputs
830 `(("readline" ,readline)
831 ("libnl" ,libnl)
832 ("gnutls" ,gnutls)
833 ("libgcrypt" ,libgcrypt))) ;needed by crypto_gnutls.c
834 (native-inputs
835 `(("pkg-config" ,pkg-config)))
836 (home-page "http://w1.fi/wpa_supplicant/")
837 (synopsis "Connecting to WPA and WPA2-protected wireless networks")
838 (description
839 "wpa_supplicant is a WPA Supplicant with support for WPA and WPA2 (IEEE
840 802.11i / RSN). Supplicant is the IEEE 802.1X/WPA component that is used in
841 the client stations. It implements key negotiation with a WPA Authenticator
842 and it controls the roaming and IEEE 802.11 authentication/association of the
843 WLAN driver.
844
845 This package provides the 'wpa_supplicant' daemon and the 'wpa_cli' command.")
846
847 ;; In practice, this is linked against Readline, which makes it GPLv3+.
848 (license license:bsd-3)))
849
850 (define-public wpa-supplicant
851 (package (inherit wpa-supplicant-minimal)
852 (name "wpa-supplicant")
853 (inputs `(("dbus" ,dbus)
854 ,@(package-inputs wpa-supplicant-minimal)))
855 (arguments
856 (substitute-keyword-arguments (package-arguments wpa-supplicant-minimal)
857 ((#:phases phases)
858 `(alist-cons-after
859 'configure 'configure-for-dbus
860 (lambda _
861 (let ((port (open-file ".config" "al")))
862 (display "
863 CONFIG_CTRL_IFACE_DBUS=y
864 CONFIG_CTRL_IFACE_DBUS_NEW=y
865 CONFIG_CTRL_IFACE_DBUS_INTRO=y\n" port)
866 (close-port port))
867 #t)
868 (alist-cons-after
869 'install-man-pages 'install-dbus-conf
870 (lambda* (#:key outputs #:allow-other-keys)
871 (let* ((out (assoc-ref outputs "out"))
872 (dir (string-append out "/etc/dbus-1/system.d")))
873 (mkdir-p dir)
874 (copy-file "dbus/dbus-wpa_supplicant.conf"
875 (string-append dir "/wpa_supplicant.conf"))))
876 ,phases)))))))
877
878 (define-public wakelan
879 (package
880 (name "wakelan")
881 (version "1.1")
882 (source (origin
883 (method url-fetch)
884 (uri (string-append
885 "ftp://ftp.gwdg.de/pub/linux/metalab/system/network/misc/wakelan-"
886 version ".tar.gz"))
887 (sha256
888 (base32
889 "0vydqpf44146ir6k87gmqaq6xy66xhc1gkr3nsd7jj3nhy7ypx9x"))))
890 (build-system gnu-build-system)
891 (arguments
892 '(#:phases (alist-replace
893 'configure
894 (lambda* (#:key outputs #:allow-other-keys)
895 (let ((out (assoc-ref outputs "out")))
896 (mkdir-p (string-append out "/bin"))
897 (mkdir-p (string-append out "/share/man/man1"))
898
899 ;; It's an old configure script that doesn't understand
900 ;; the extra options we pass.
901 (setenv "CONFIG_SHELL" (which "bash"))
902 (zero?
903 (system* "./configure"
904 (string-append "--prefix=" out)
905 (string-append "--mandir=" out
906 "/share/man")))))
907 %standard-phases)
908 #:tests? #f))
909 (home-page "http://kernel.org") ; really, no home page
910 (synopsis "Send a wake-on-LAN packet")
911 (description
912 "WakeLan broadcasts a properly formatted UDP packet across the local area
913 network, which causes enabled computers to power on.")
914 (license license:gpl2+)))
915
916 (define-public dmidecode
917 (package
918 (name "dmidecode")
919 (version "2.12")
920 (source (origin
921 (method url-fetch)
922 (uri (string-append
923 "mirror://savannah/dmidecode/dmidecode-"
924 version ".tar.bz2"))
925 (sha256
926 (base32
927 "122hgaw8mpqdfra159lfl6pyk3837giqx6vq42j64fjnbl2z6gwi"))))
928 (build-system gnu-build-system)
929 (arguments
930 '(#:phases (alist-delete 'configure %standard-phases)
931 #:tests? #f ; no 'check' target
932 #:make-flags (list (string-append "prefix="
933 (assoc-ref %outputs "out")))))
934 (home-page "http://www.nongnu.org/dmidecode/")
935 (synopsis "Read hardware information from the BIOS")
936 (description
937 "Dmidecode reports information about your system's hardware as described
938 in your system BIOS according to the SMBIOS/DMI standard. This typically
939 includes system manufacturer, model name, serial number, BIOS version, asset
940 tag as well as a lot of other details of varying level of interest and
941 reliability depending on the manufacturer. This will often include usage
942 status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
943 module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
944 (license license:gpl2+)))
945
946 (define-public acpica
947 (package
948 (name "acpica")
949 (version "20150410")
950 (source (origin
951 (method url-fetch)
952 (uri (string-append
953 "https://acpica.org/sites/acpica/files/acpica-unix2-"
954 version ".tar.gz"))
955 (sha256
956 (base32
957 "0q1fjwkyw9x6gsva6fd0zbn7ly4fx0ha4853f416np9kf2irillw"))))
958 (build-system gnu-build-system)
959 (native-inputs `(("flex" ,flex)
960 ("bison" ,bison)))
961 (arguments
962 '(#:make-flags (list (string-append "PREFIX=" %output)
963 "HOST=_LINUX"
964 "OPT_CFLAGS=-Wall -fno-strict-aliasing")
965 #:tests? #f ; no 'check' target.
966 #:phases (alist-delete 'configure %standard-phases)))
967 (home-page "http://acpica.org/")
968 (synopsis "Tools for the development and debug of ACPI tables")
969 (description
970 "The ACPI Component Architecture (ACPICA) project provides an
971 OS-independent reference implementation of the Advanced Configuration and
972 Power Interface Specification (ACPI). ACPICA code contains those portions of
973 ACPI meant to be directly integrated into the host OS as a kernel-resident
974 subsystem, and a small set of tools to assist in developing and debugging ACPI
975 tables. This package contains only the user-space tools needed for ACPI table
976 development, not the kernel implementation of ACPI.")
977 (license license:gpl2))) ; Dual GPLv2/ACPICA Licence
978
979 (define-public stress
980 (package
981 (name "stress")
982 (version "1.0.1")
983 (source (origin
984 (method url-fetch)
985 (uri (string-append "mirror://debian/pool/main/s/stress/stress_"
986 version ".orig.tar.gz"))
987 (sha256
988 (base32
989 "1v9vnzlihqfjsxa93hdbrq72pqqk00dkylmlg8jpxhm7s1w9qfl1"))))
990 (build-system gnu-build-system)
991 (home-page "http://packages.debian.org/wheezy/stress")
992 (synopsis "Impose load on and stress test a computer system")
993 (description
994 "Stress is a tool that imposes a configurable amount of CPU, memory, I/O,
995 or disk stress on a POSIX-compliant operating system and reports any errors it
996 detects.
997
998 Stress is not a benchmark. It is a tool used by system administrators to
999 evaluate how well their systems will scale, by kernel programmers to evaluate
1000 perceived performance characteristics, and by systems programmers to expose
1001 the classes of bugs which only or more frequently manifest themselves when the
1002 system is under heavy load.")
1003 (license license:gpl2+)))
1004
1005 (define-public detox
1006 (package
1007 (name "detox")
1008 (version "1.2.0")
1009 (source (origin
1010 (method url-fetch)
1011 (uri (string-append "mirror://sourceforge/detox/detox-"
1012 version ".tar.bz2"))
1013 (sha256
1014 (base32
1015 "1y6vvjqsg54kl49cry73jbfhr04s7wjs779vrr9zrq6kww7dkymb"))))
1016 (build-system gnu-build-system)
1017 ;; Both flex and popt are used in this case for their runtime libraries
1018 ;; (libfl and libpopt).
1019 (inputs
1020 `(("flex" ,flex)
1021 ("popt" ,popt)))
1022 (arguments
1023 `(#:configure-flags `(,(string-append "--with-popt="
1024 (assoc-ref %build-inputs "popt")))
1025 #:tests? #f)) ;no 'check' target
1026 (home-page "http://detox.sourceforge.net")
1027 (synopsis "Clean up file names")
1028 (description
1029 "Detox is a program that renames files to make them easier to work with
1030 under Unix and related operating systems. Spaces and various other unsafe
1031 characters (such as \"$\") get replaced with \"_\". ISO 8859-1 (Latin-1)
1032 characters can be replaced as well, as can UTF-8 characters.")
1033 (license license:bsd-3)))
1034
1035 (define-public testdisk
1036 (package
1037 (name "testdisk")
1038 (version "6.14")
1039 (source (origin
1040 (method url-fetch)
1041 (uri (string-append "http://www.cgsecurity.org/testdisk-"
1042 version ".tar.bz2"))
1043 (sha256
1044 (base32
1045 "0v1jap83f5h99zv01v3qmqm160d36n4ysi0gyq7xzb3mqgmw75x5"))))
1046 (build-system gnu-build-system)
1047 (inputs
1048 `(;; ("ntfs" ,ntfs)
1049 ("util-linux" ,util-linux)
1050 ("openssl" ,openssl)
1051 ("zlib" ,zlib)
1052 ("e2fsprogs" ,e2fsprogs)
1053 ("libjpeg" ,libjpeg)
1054 ("ncurses" ,ncurses)))
1055 (home-page "http://www.cgsecurity.org/wiki/TestDisk")
1056 (synopsis "Data recovery tool")
1057 (description
1058 "TestDisk is a program for data recovery, primarily designed to help
1059 recover lost partitions and/or make non-booting disks bootable again.")
1060 (license license:gpl2+)))
1061
1062 (define-public tree
1063 (package
1064 (name "tree")
1065 (version "1.7.0")
1066 (source (origin
1067 (method url-fetch)
1068 (uri (string-append
1069 "http://mama.indstate.edu/users/ice/tree/src/tree-"
1070 version ".tgz"))
1071 (sha256
1072 (base32 "04kviw799qxly08zb8n5mgxfd96gyis6x69q2qiw86jnh87c4mv9"))))
1073 (build-system gnu-build-system)
1074 (arguments
1075 '(#:phases (alist-delete 'configure %standard-phases)
1076 #:tests? #f ; no check target
1077 #:make-flags (let ((out (assoc-ref %outputs "out")))
1078 (list (string-append "prefix=" out)))))
1079 (synopsis "Recursively list the contents of a directory")
1080 (description
1081 "Tree is a recursive directory listing command that produces a depth
1082 indented listing of files, which is colorized ala dircolors if the LS_COLORS
1083 environment variable is set and output is to tty.")
1084 (home-page "http://mama.indstate.edu/users/ice/tree/")
1085 (license license:gpl2+)))
1086
1087 (define-public direvent
1088 (package
1089 (name "direvent")
1090 (version "5.0")
1091 (source (origin
1092 (method url-fetch)
1093 (uri (string-append "mirror://gnu/direvent/direvent-"
1094 version ".tar.gz"))
1095 (sha256
1096 (base32
1097 "1i14131y6m8wvirz6piw4zxz2q1kbpl0lniv5kl55rx4k372dg8z"))
1098 (modules '((guix build utils)))
1099 (snippet '(substitute* "tests/testsuite"
1100 (("#![[:blank:]]?/bin/sh")
1101 "#!$SHELL")))))
1102 (build-system gnu-build-system)
1103 (arguments
1104 '(#:phases (alist-cons-before
1105 'build 'patch-/bin/sh
1106 (lambda* (#:key inputs #:allow-other-keys)
1107 ;; Use the right shell when executing the watcher.
1108 (let ((bash (assoc-ref inputs "bash")))
1109 (substitute* "src/direvent.c"
1110 (("\"/bin/sh\"")
1111 (string-append "\"" bash "/bin/sh\"")))))
1112 %standard-phases)))
1113 (home-page "http://www.gnu.org/software/direvent/")
1114 (synopsis "Daemon to monitor directories for events such as file removal")
1115 (description
1116 "A daemon that monitors directories for events, such as creating,
1117 deleting or modifying files. It can monitor different sets of directories for
1118 different events. When an event is detected, direvent calls a specified
1119 external program with information about the event, such as the location
1120 within the file system where it occurred. Thus, \"direvent\" provides an
1121 easy way to react immediately if given files undergo changes, for example, to
1122 track changes in important system configuration files.")
1123 (license license:gpl3+)))
1124
1125 (define-public libcap-ng
1126 (package
1127 (name "libcap-ng")
1128 (version "0.7.4")
1129 (source (origin
1130 (method url-fetch)
1131 (uri (string-append
1132 "http://people.redhat.com/sgrubb/libcap-ng/libcap-ng-"
1133 version ".tar.gz"))
1134 (sha256
1135 (base32
1136 "0ssvnh4cvhya0c1j6k6192zvqcq7nc0x01fb5nwhr0prfqr0i8j8"))))
1137 (build-system gnu-build-system)
1138 (inputs `(("python" ,python)))
1139 (home-page "http://people.redhat.com/sgrubb/libcap-ng/")
1140 (synopsis "Library for more easily working with POSIX capabilities")
1141 (description
1142 "The libcap-ng library is intended to make programming with POSIX
1143 capabilities easier than the traditional libcap library. It includes
1144 utilities that can analyse all currently running applications and print out
1145 any capabilities and whether or not it has an open ended bounding set. The
1146 included utilities are designed to let admins and developers spot apps from
1147 various ways that may be running with too much privilege.")
1148 ;; The library is lgpl2.1+, but also ships some utils which are gpl2+.
1149 (license (list license:lgpl2.1+ license:gpl2+))))
1150
1151 (define-public smartmontools
1152 (package
1153 (name "smartmontools")
1154 (version "6.3")
1155 (source (origin
1156 (method url-fetch)
1157 (uri (string-append
1158 "mirror://sourceforge/smartmontools/smartmontools/"
1159 version "/smartmontools-" version ".tar.gz"))
1160 (sha256
1161 (base32
1162 "06gy71jh2d3gcfmlbbrsqw7215knkfq59q3j6qdxfrar39fhcxx7"))))
1163 (build-system gnu-build-system)
1164 (inputs `(("libcap-ng" ,libcap-ng)))
1165 (home-page "http://www.smartmontools.org/")
1166 (synopsis "S.M.A.R.T. harddisk control and monitoring tools")
1167 (description
1168 "The smartmontools package contains utility programs to control and
1169 monitor storage systems using the Self-Monitoring, Analysis and Reporting
1170 Technology System (S.M.A.R.T.) built into most modern ATA and SCSI harddisks.
1171 In many cases, these utilities will provide advanced warning of disk
1172 degradation and failure.")
1173 (license license:gpl2+)))
1174
1175 (define-public fdupes
1176 (package
1177 (name "fdupes")
1178 (version "1.51")
1179 (source
1180 (origin
1181 (method url-fetch)
1182 (uri (string-append
1183 "https://github.com/adrianlopezroche/fdupes/archive/fdupes-"
1184 version ".tar.gz"))
1185 (sha256
1186 (base32
1187 "11j96vxl9vg3jsnxqxskrv3gad6dh7hz2zpyc8n31xzyxka1c7kn"))))
1188 (build-system gnu-build-system)
1189 (arguments
1190 '(#:phases (alist-delete 'configure %standard-phases)
1191 #:tests? #f ; no 'check' target
1192 #:make-flags (list (string-append "PREFIX="
1193 (assoc-ref %outputs "out")))))
1194 (home-page "https://github.com/adrianlopezroche/fdupes")
1195 (synopsis "Identify duplicate files")
1196 (description
1197 "fdupes is a program for identifying duplicate files residing within
1198 specified directories.")
1199 (license license:expat)))
1200
1201 (define-public graphios
1202 (package
1203 (name "graphios")
1204 (version "2.0.3")
1205 (source
1206 (origin
1207 (method url-fetch)
1208 (uri (string-append
1209 "https://pypi.python.org/packages/source/g/graphios/graphios-"
1210 version ".tar.gz"))
1211 (sha256
1212 (base32
1213 "1h87hvc315wg6lklbf4l7csd3n5pgljwrfli1p3nasdi0izgn66i"))))
1214 (build-system python-build-system)
1215 (arguments
1216 ;; Be warned: Building with Python 3 succeeds, but the build process
1217 ;; throws a syntax error that is ignored.
1218 `(#:python ,python-2
1219 #:phases
1220 (modify-phases %standard-phases
1221 (add-before 'build 'fix-setup.py
1222 (lambda* (#:key outputs #:allow-other-keys)
1223 ;; Fix hardcoded, unprefixed file names.
1224 (let ((out (assoc-ref outputs "out")))
1225 (substitute* '("setup.py")
1226 (("/etc") (string-append out "/etc"))
1227 (("/usr") out)
1228 (("distro_ver = .*") "distro_ver = ''"))
1229 #t))))))
1230 (inputs
1231 `(("python-setuptools" ,python2-setuptools)))
1232 (home-page "https://github.com/shawn-sterling/graphios")
1233 (synopsis "Emit Nagios metrics to Graphite, Statsd, and Librato")
1234 (description
1235 "Graphios is a script to emit nagios perfdata to various upstream metrics
1236 processing and time-series systems. It's currently compatible with Graphite,
1237 Statsd, Librato and InfluxDB. Graphios can emit Nagios metrics to any number
1238 of supported upstream metrics systems simultaneously.")
1239 (license license:gpl2+)))
1240
1241 (define-public ansible
1242 (package
1243 (name "ansible")
1244 (version "1.9.2")
1245 (source
1246 (origin
1247 (method url-fetch)
1248 (uri (string-append
1249 "https://pypi.python.org/packages/source/a/ansible/ansible-"
1250 version
1251 ".tar.gz"))
1252 (sha256
1253 (base32
1254 "007fzgsqaahb0y4gjdxxmir9kcni7wph2z14jhqgpz88idrz8pn2"))))
1255 (build-system python-build-system)
1256 (native-inputs
1257 `(("python2-setuptools" ,python2-setuptools)
1258 ("python2-pycrypto" ,python2-pycrypto)
1259 ("python2-httplib2" ,python2-httplib2)
1260 ("python2-passlib" ,python2-passlib)
1261 ("python2-nose" ,python2-nose)
1262 ("python2-mock" ,python2-mock)
1263 ("python2-jinja2" ,python2-jinja2)
1264 ("python2-pyyaml" ,python2-pyyaml)
1265 ("python2-paramiko" ,python2-paramiko)))
1266 (inputs
1267 `(("python2-pycrypto" ,python2-pycrypto)
1268 ("python2-jinja2" ,python2-jinja2)
1269 ("python2-pyyaml" ,python2-pyyaml)
1270 ("python2-paramiko" ,python2-paramiko)))
1271 (arguments
1272 `(#:python ,python-2)) ; incompatible with Python 3
1273 (home-page "http://ansible.com/")
1274 (synopsis "Radically simple IT automation")
1275 (description "Ansible is a radically simple IT automation system. It
1276 handles configuration-management, application deployment, cloud provisioning,
1277 ad-hoc task-execution, and multinode orchestration - including trivializing
1278 things like zero downtime rolling updates with load balancers.")
1279 (license license:gpl3+)))
1280
1281 (define-public cpulimit
1282 (package
1283 (name "cpulimit")
1284 (version "0.2")
1285 (source
1286 (origin
1287 (method url-fetch)
1288 (uri (string-append "https://github.com/opsengine/cpulimit/archive/v"
1289 version ".tar.gz"))
1290 (file-name (string-append name "-" version ".tar.gz"))
1291 (sha256
1292 (base32
1293 "1nn2w849xd5bw4y5sqnll29nxdwl5h0cv4smc7dwmpb9qnd2ycb4"))))
1294 (build-system gnu-build-system)
1295 (arguments
1296 `(#:phases (modify-phases %standard-phases
1297 (delete 'configure)
1298 (replace
1299 'build
1300 (lambda _
1301 (zero? (system* "make" "CC=gcc" "-Csrc"))))
1302 (replace
1303 'check
1304 (lambda _
1305 (zero? (system* "make" "CC=gcc" "-Ctests"))))
1306 (replace
1307 'install
1308 (lambda* (#:key outputs #:allow-other-keys)
1309 (let* ((out (assoc-ref outputs "out"))
1310 (bin (string-append out "/bin")))
1311 (install-file "src/cpulimit" bin)))))))
1312 (home-page "https://github.com/opsengine/cpulimit")
1313 (synopsis "Limit CPU usage")
1314 (description
1315 "Cpulimit limits the CPU usage of a process. It does not change the nice
1316 value or other scheduling priority settings, but the real CPU usage, and is
1317 able to adapt itself dynamically to the overall system load. Children
1318 processes and threads of the specified process may optionally share the same
1319 limits.")
1320 (license license:gpl2+)))