gnu: Add keepalived.
[jackhill/guix/guix.git] / gnu / packages / cluster.scm
CommitLineData
af09dabf
SB
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2018 Sou Bunnbu <iyzsong@member.fsf.org>
3;;;
4;;; This file is part of GNU Guix.
5;;;
6;;; GNU Guix is free software; you can redistribute it and/or modify it
7;;; under the terms of the GNU General Public License as published by
8;;; the Free Software Foundation; either version 3 of the License, or (at
9;;; your option) any later version.
10;;;
11;;; GNU Guix is distributed in the hope that it will be useful, but
12;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14;;; GNU General Public License for more details.
15;;;
16;;; You should have received a copy of the GNU General Public License
17;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
18
19(define-module (gnu packages cluster)
20 #:use-module ((guix licenses) #:prefix license:)
21 #:use-module (guix build-system gnu)
22 #:use-module (guix download)
23 #:use-module (guix packages)
24 #:use-module (gnu packages linux)
25 #:use-module (gnu packages pkg-config)
26 #:use-module (gnu packages python)
27 #:use-module (gnu packages tls))
28
29(define-public keepalived
30 (package
31 (name "keepalived")
32 (version "2.0.1")
33 (source (origin
34 (method url-fetch)
35 (uri (string-append
36 "http://www.keepalived.org/software/keepalived-"
37 version ".tar.gz"))
38 (sha256
39 (base32
40 "0hp8i56zkf0398bmpi32a85f05cv2fy9wizkdfbxk7gav4z6yx18"))))
41 (build-system gnu-build-system)
42 (arguments
43 '(#:phases
44 (modify-phases %standard-phases
45 (add-before 'configure 'patch-configure
46 (lambda _
47 ;; XXX: The 'configure' script doesn't handle '-L' flags in the
48 ;; output of 'pkg-config'.
49 (substitute* "configure"
50 (("PKG_CONFIG --libs") "PKG_CONFIG --libs-only-l"))
51 #t)))))
52 (native-inputs
53 `(("pkg-config" ,pkg-config)
54 ("python-sphinx" ,python-sphinx)))
55 (inputs
56 `(("openssl" ,openssl)
57 ("libnfnetlink" ,libnfnetlink)
58 ("libnl" ,libnl)))
59 (home-page "http://www.keepalived.org/")
60 (synopsis "Loadbalancing and high-availability frameworks")
61 (description
62 "Keepalived provides frameworks for both load balancing and high
63availability. The load balancing framework relies on the Linux Virtual
64Server (IPVS) kernel module. High availability is achieved by the Virtual
65Redundancy Routing Protocol (VRRP). Each Keepalived framework can be used
66independently or together to provide resilient infrastructures.")
67 (license license:gpl2+)))