summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO40
-rw-r--r--PKGBUILD92
-rw-r--r--crm_report.in24
-rw-r--r--makefile-chown.patch36
-rw-r--r--pacemaker.install14
5 files changed, 206 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..288ffe206f6
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,40 @@
+pkgbase = pacemaker1.1
+ pkgdesc = advanced, scalable high-availability cluster resource manager (1.1 series)
+ pkgver = 1.1.18
+ pkgrel = 1
+ url = https://github.com/ClusterLabs/pacemaker/
+ install = pacemaker.install
+ arch = i686
+ arch = x86_64
+ license = GPL2
+ makedepends = inkscape
+ makedepends = help2man
+ makedepends = asciidoc
+ depends = gnutls
+ depends = glib2
+ depends = pam
+ depends = libtool
+ depends = python-lxml
+ depends = python-yaml
+ depends = libesmtp
+ depends = corosync
+ depends = libqb
+ depends = resource-agents
+ depends = fence-agents
+ depends = ha-glue
+ depends = net-snmp
+ optdepends = pssh: for use with some tools
+ optdepends = pdsh: for use with some tools
+ optdepends = crmsh: for use with crm_report
+ optdepends = booth: for geo-clustering
+ provides = pacemaker=1.1.18
+ conflicts = pacemaker
+ source = https://github.com/ClusterLabs/pacemaker/archive/Pacemaker-1.1.18.tar.gz
+ source = crm_report.in
+ source = makefile-chown.patch
+ sha512sums = 63c287888e5f0bd5f1a2f56450cb3d4da580df2d750ffa90b2212a4efcfa146e05e258a9d87fdcaacde5f8985b9730dae11c5d5ad22e811fd114e1640365c9aa
+ sha512sums = 09a80f5579db9016dcbba759ee9b661aea24ed7c98906939d5e50befb344c693652a9634ab804a91bfedeeeb69ce5ab87f30d2ed356bfefd9cdc67669a1cce64
+ sha512sums = bbd4f0415bbc07dedc447cdedea8470ee5308631721c04d7a495e5d0dcad639754f26d7db5c2bdad13e9669346e83d9674607dc7349e1b59cb7e9a35b31b2d22
+
+pkgname = pacemaker1.1
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..cef5e7d822d
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,92 @@
+# Maintainer: Brian Bidulock <bidulock@openss7.org>
+# Contributor: gls <ghostlovescorebg at gmail dot com>
+# Contributor: Thermi <noel at familie-kuntze dot de>
+# Contributor: Tim Meusel <tim@bastelfreak.de>
+
+pkgname=pacemaker1.1
+_pkgname=pacemaker
+pkgver=1.1.18
+pkgrel=1
+pkgdesc="advanced, scalable high-availability cluster resource manager (1.1 series)"
+arch=('i686' 'x86_64')
+url="https://github.com/ClusterLabs/${_pkgname}/"
+license=('GPL2')
+makedepends=('inkscape' 'help2man' 'asciidoc')
+depends=('gnutls' 'glib2' 'pam' 'libtool' 'python-lxml' 'python-yaml' 'libesmtp'
+ 'corosync' 'libqb' 'resource-agents' 'fence-agents'
+ 'ha-glue' 'net-snmp')
+optdepends=('pssh: for use with some tools'
+ 'pdsh: for use with some tools'
+ 'crmsh: for use with crm_report'
+ 'booth: for geo-clustering')
+provides=($_pkgname=$pkgver)
+conflicts=($_pkgname)
+install=${_pkgname}.install
+source=("https://github.com/ClusterLabs/$_pkgname/archive/Pacemaker-$pkgver.tar.gz"
+ 'crm_report.in'
+ 'makefile-chown.patch')
+sha512sums=('63c287888e5f0bd5f1a2f56450cb3d4da580df2d750ffa90b2212a4efcfa146e05e258a9d87fdcaacde5f8985b9730dae11c5d5ad22e811fd114e1640365c9aa'
+ '09a80f5579db9016dcbba759ee9b661aea24ed7c98906939d5e50befb344c693652a9634ab804a91bfedeeeb69ce5ab87f30d2ed356bfefd9cdc67669a1cce64'
+ 'bbd4f0415bbc07dedc447cdedea8470ee5308631721c04d7a495e5d0dcad639754f26d7db5c2bdad13e9669346e83d9674607dc7349e1b59cb7e9a35b31b2d22')
+
+prepare() {
+ cd ${_pkgname}-Pacemaker-${pkgver}
+ patch -Np2 -b -z .orig <../makefile-chown.patch
+ autoreconf -fiv
+# ./autogen.sh
+}
+
+build() {
+ cd ${_pkgname}-Pacemaker-${pkgver}
+ ./configure \
+ CPPFLAGS= \
+ --sbindir=/usr/bin \
+ --sysconfdir=/etc \
+ --libdir=/usr/lib \
+ --libexecdir=/usr/lib \
+ --localstatedir=/var \
+ --disable-static \
+ --disable-fatal-warnings \
+ --with-version=$pkgver-$pkgrel \
+ --enable-systemd \
+ --disable-upstart \
+ --with-ais \
+ --with-corosync \
+ --without-heartbeat \
+ --without-cman \
+ --with-cs-quorum \
+ --with-nagios \
+ --with-snmp \
+ --with-esmtp \
+ --with-acl \
+ --with-cibsecrets \
+ --without-profiling \
+ --without-coverage \
+ --with-configdir=/etc/pacemaker
+# --with-nagios-plugin-dir=DIR
+# --with-nagios-metadata-dir=DIR
+ make V=0
+}
+
+package() {
+ cd ${_pkgname}-Pacemaker-${pkgver}
+ make DESTDIR="${pkgdir}" install
+ cd "$srcdir"
+ install -Dm644 /dev/null "$pkgdir/usr/lib/tmpfiles.d/$_pkgname.conf"
+ cat>"$pkgdir/usr/lib/tmpfiles.d/$_pkgname.conf"<<-EOF
+ d /var/lib/pacemaker 0750 hacluster haclient
+ d /var/lib/pacemaker/blackbox 0750 hacluster haclient
+ d /var/lib/pacemaker/cib 0750 hacluster haclient
+ d /var/lib/pacemaker/cores 0750 hacluster haclient
+ d /var/lib/pacemaker/pengine 0750 hacluster haclient
+ EOF
+ rm -fr "$pkgdir/var"
+ chmod a+x "$pkgdir/usr/share/pacemaker/tests/cts/CTSlab.py"
+ find "$pkgdir" -name '*.xml' -type f -print0 | xargs -0 chmod a-x
+ rm -fr "$pkgdir/etc/init.d"
+ rm -f "$pkgdir/usr/bin/fence_pcmk"
+ mv "$pkgdir/usr/bin/crm_report" "$pkgdir/usr/bin/crm_report.pacemaker"
+ install -Dm755 crm_report.in "$pkgdir/usr/bin/crm_report"
+}
+
+# vim: set sw=2 et ts=2:
diff --git a/crm_report.in b/crm_report.in
new file mode 100644
index 00000000000..c5dff3bdd4a
--- /dev/null
+++ b/crm_report.in
@@ -0,0 +1,24 @@
+#!/bin/sh
+#
+# Copyright (C) 2007 Dejan Muhamedagic <dmuhamedagic@suse.com>
+# Copyright (C) 2015 Kristoffer Gronlund <kgronlund@suse.com>
+# Copyright (C) 2015 Gao,Yan <ygao@suse.com>
+#
+# Replaced with crm report
+PARENT_COMMAND="$(ps -o comm= $PPID)"
+PROG="$(basename "$0")"
+
+die() {
+ echo "$PROG: $*"
+ exit 1
+}
+[ "$(basename "$PARENT_COMMAND")" = "crm" ] && die "called itself in a loop, aborting"
+if which crm > /dev/null 2>&1; then
+ crm report "$@"
+elif [ -x /usr/sbin/crm ]; then
+ /usr/sbin/crm report "$@"
+else
+ #die "crm_report has been deprecated: Please install crmsh, which replaces it"
+ /usr/sbin/crm_report.pacemaker "$@"
+fi
+
diff --git a/makefile-chown.patch b/makefile-chown.patch
new file mode 100644
index 00000000000..034091b19f0
--- /dev/null
+++ b/makefile-chown.patch
@@ -0,0 +1,36 @@
+diff -up src/pacemaker-Pacemaker-1.1.18/Makefile.am.orig src/pacemaker-Pacemaker-1.1.18/Makefile.am
+--- src/pacemaker-Pacemaker-1.1.18/Makefile.am.orig 2018-04-19 23:26:43.000000000 -0600
++++ src/pacemaker-Pacemaker-1.1.18/Makefile.am 2018-04-19 23:40:07.000000000 -0600
+@@ -67,13 +67,13 @@ install-exec-local:
+ $(INSTALL) -d -m 750 $(DESTDIR)/$(CRM_CONFIG_DIR)
+ $(INSTALL) -d -m 750 $(DESTDIR)/$(CRM_CORE_DIR)
+ $(INSTALL) -d -m 750 $(DESTDIR)/$(CRM_BLACKBOX_DIR)
+- -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_CONFIG_DIR)
+- -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_CORE_DIR)
+- -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_BLACKBOX_DIR)
+ if BUILD_CS_PLUGIN
+ rm -f $(DESTDIR)$(LCRSODIR)/pacemaker.lcrso $(DESTDIR)$(LCRSODIR)/service_crm.so
+ cp $(DESTDIR)$(libdir)/service_crm.so $(DESTDIR)$(LCRSODIR)/pacemaker.lcrso
+ endif
++# -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_CONFIG_DIR)
++# -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_CORE_DIR)
++# -chown $(CRM_DAEMON_USER):$(CRM_DAEMON_GROUP) $(DESTDIR)/$(CRM_BLACKBOX_DIR)
+ # Use chown because the user/group may not exist
+
+ clean-generic:
+diff -up src/pacemaker-Pacemaker-1.1.18/pengine/Makefile.am.orig src/pacemaker-Pacemaker-1.1.18/pengine/Makefile.am
+--- src/pacemaker-Pacemaker-1.1.18/pengine/Makefile.am.orig 2018-04-19 23:26:29.000000000 -0600
++++ src/pacemaker-Pacemaker-1.1.18/pengine/Makefile.am 2018-04-19 23:39:40.000000000 -0600
+@@ -80,9 +80,9 @@ pengine_SOURCES = main.c
+
+ install-exec-local:
+ $(mkinstalldirs) $(DESTDIR)/$(PE_STATE_DIR)
+- -chown $(CRM_DAEMON_USER) $(DESTDIR)/$(PE_STATE_DIR)
+- -chgrp $(CRM_DAEMON_GROUP) $(DESTDIR)/$(PE_STATE_DIR)
+- -chmod 750 $(DESTDIR)/$(PE_STATE_DIR)
++# -chown $(CRM_DAEMON_USER) $(DESTDIR)/$(PE_STATE_DIR)
++# -chgrp $(CRM_DAEMON_GROUP) $(DESTDIR)/$(PE_STATE_DIR)
++# -chmod 750 $(DESTDIR)/$(PE_STATE_DIR)
+
+ uninstall-local:
+
diff --git a/pacemaker.install b/pacemaker.install
new file mode 100644
index 00000000000..adf039e5698
--- /dev/null
+++ b/pacemaker.install
@@ -0,0 +1,14 @@
+post_install(){ :
+ usr/bin/getent group haclient >/dev/null || usr/bin/groupadd -r haclient -g 189
+ usr/bin/getent passwd hacluster >/dev/null || usr/bin/useradd -r -g 189 -u 189 -s /sbin/nologin -c "cluster user" -d / hacluster
+}
+
+post_upgrade(){ :
+}
+
+post_remove(){ :
+ usr/bin/getent group haclient >/dev/null && usr/bin/groupdel -f haclient
+ usr/bin/getent passwd hacluster >/dev/null && usr/bin/userdel hacluster
+# usr/bin/rm -fr var/lib/pacemaker
+}
+