summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 06:50:18 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 06:50:18 +0000
commita8f6774ad2693bebb5c45b437815a3dfc777627f (patch)
treeadcb37c02a764490d40305ba8c4c25e82d3b8752
parentAdding upstream version 4.12.1. (diff)
downloadfence-agents-a8f6774ad2693bebb5c45b437815a3dfc777627f.tar.xz
fence-agents-a8f6774ad2693bebb5c45b437815a3dfc777627f.zip
Adding debian version 4.12.1-1.debian/4.12.1-1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
-rw-r--r--debian/changelog406
-rw-r--r--debian/clean2
-rw-r--r--debian/control103
-rw-r--r--debian/copyright61
-rw-r--r--debian/fence-agents.docs2
-rw-r--r--debian/fence-agents.install9
-rw-r--r--debian/fence-virt.docs3
-rw-r--r--debian/fence-virt.install4
-rw-r--r--debian/fence-virtd.docs3
-rw-r--r--debian/fence-virtd.fence_virtd.init26
-rw-r--r--debian/fence-virtd.install5
-rw-r--r--debian/fence-virtd.postinst45
-rw-r--r--debian/fence-virtd.postrm41
-rw-r--r--debian/patches/disable-network-access27
-rw-r--r--debian/patches/enable-zvm-agent17
-rw-r--r--debian/patches/fence-virt-key17
-rw-r--r--debian/patches/logging-warn-deprecated65
-rw-r--r--debian/patches/series6
-rw-r--r--debian/patches/spelling37
-rw-r--r--debian/patches/systemd-syslog-target16
-rwxr-xr-xdebian/rules93
-rw-r--r--debian/salsa-ci.yml4
-rw-r--r--debian/source/format1
-rw-r--r--debian/tests/control20
-rwxr-xr-xdebian/tests/delay34
-rwxr-xr-xdebian/tests/fence-aws47
-rwxr-xr-xdebian/tests/fence-dummy14
-rwxr-xr-xdebian/tests/metadata23
-rw-r--r--debian/upstream/metadata4
-rw-r--r--debian/watch2
30 files changed, 1137 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..1eeea82
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,406 @@
+fence-agents (4.12.1-1) unstable; urgency=medium
+
+ * New upstream version 4.12.1 (Closes: #1029768)
+
+ -- Valentin Vidic <vvidic@debian.org> Sat, 28 Jan 2023 09:06:44 +0100
+
+fence-agents (4.12.0-1) unstable; urgency=medium
+
+ [ Lucas Kanashiro ]
+ * d/rules: use $DEB_HOST_ARCH variable to detect host architecture
+ * d/rules: disable -Wstringop-truncation in s390x to fix a FTBFS with GCC 12
+
+ [ Valentin Vidic ]
+ * New upstream version 4.12.0
+ * Refresh patches for new version
+ * Update Debian copyright year
+ * Update Standards-Version to 4.6.2
+ * Update metadata test for new version
+ * Create temporary directory for agents
+ * Leave zvm agent enabled
+ * Generate secret key on package install
+
+ -- Valentin Vidic <vvidic@debian.org> Sat, 14 Jan 2023 15:44:02 +0100
+
+fence-agents (4.11.0-1) unstable; urgency=medium
+
+ * New upstream version 4.11.0
+ * Refresh patches for new version
+ * Create packages for fence-virt and fence-virtd
+ * Update watch file url
+ * Update Debian copyright
+ * Update Standards-Version to 4.6.0
+ * Cleanup lintian-overrides
+ * Fix lintian warning for syslog.target
+ * Replace deprecated logging.warn calls
+ * Ignore warnings in metadata output
+
+ -- Valentin Vidic <vvidic@debian.org> Sun, 01 May 2022 17:51:59 +0200
+
+fence-agents (4.7.1-1) unstable; urgency=medium
+
+ * New upstream version 4.7.1
+ * Update dependencies for new version
+
+ -- Valentin Vidic <vvidic@debian.org> Mon, 08 Feb 2021 20:32:01 +0100
+
+fence-agents (4.7.0-1) unstable; urgency=medium
+
+ * New upstream version 4.7.0
+ * Run delay test using dash again
+ * Update watch file version
+ * Include pkgconfig in the package
+
+ -- Valentin Vidic <vvidic@debian.org> Thu, 10 Dec 2020 21:25:57 +0100
+
+fence-agents (4.6.0-3) unstable; urgency=medium
+
+ * Run delay test using bash (Closes: #975543)
+ * Update Standards-Version to 4.5.1
+
+ -- Valentin Vidic <vvidic@debian.org> Tue, 01 Dec 2020 22:28:44 +0100
+
+fence-agents (4.6.0-2) unstable; urgency=medium
+
+ [ Rafael David Tinoco ]
+ * d/t/metadata: force gawk and fix warning message
+
+ [ Valentin Vidic ]
+ * Cleanup unused lintian-overrides
+ * Fix failing reproducible build with some locales
+ * Run delay test in parallel to save time
+
+ -- Valentin Vidic <vvidic@debian.org> Sat, 17 Oct 2020 11:15:38 +0200
+
+fence-agents (4.6.0-1) unstable; urgency=medium
+
+ * New upstream version 4.6.0
+ * Refresh patches for new version
+ * Update lintian-overrides for new version
+ * Fix awk warning in autopkgtest
+
+ -- Valentin Vidic <vvidic@debian.org> Wed, 02 Sep 2020 22:27:26 +0200
+
+fence-agents (4.5.2-3) unstable; urgency=medium
+
+ * Move fence_kdump_send to /usr/libexec
+ * Remove Build-Depends on openstack modules
+ * Remove explicit dh_missing call
+ * Fix package description
+ * Add comment why tests are disabled during build
+
+ -- Valentin Vidic <vvidic@debian.org> Sat, 16 May 2020 12:13:29 +0200
+
+fence-agents (4.5.2-2) unstable; urgency=medium
+
+ [ Valentin Vidic ]
+ * Enable CI on salsa
+ * Fix lintian manpage warnings
+ * Move testing to autopkgtest
+ * Fix build error on autodetect agents
+ * Add skippable test for fence_aws
+ * Update Standards-Version to 4.5.0
+ * Use debhelper-compat version 13
+ * Update Maintainer mailing list
+
+ [ Debian Janitor ]
+ * debian/copyright: use spaces rather than tabs to start continuation lines.
+ * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
+ Repository-Browse.
+
+ -- Valentin Vidic <vvidic@debian.org> Wed, 13 May 2020 20:14:32 +0200
+
+fence-agents (4.5.2-1) unstable; urgency=medium
+
+ * New upstream version 4.5.2
+ * Update Standards-Version to 4.4.1
+ * Build using Rules-Requires-Root: no
+
+ -- Valentin Vidic <vvidic@debian.org> Wed, 23 Oct 2019 19:40:34 +0200
+
+fence-agents (4.5.1-1) unstable; urgency=medium
+
+ * New upstream version 4.5.1
+ * Drop patch remove-fence_amt_ws
+ * Use debhelper-compat version 12
+
+ -- Valentin Vidic <vvidic@debian.org> Sun, 29 Sep 2019 12:48:33 +0200
+
+fence-agents (4.4.0-2) unstable; urgency=medium
+
+ * Update patch for removing fence_amt_ws (Closes: #934519)
+
+ -- Valentin Vidic <vvidic@debian.org> Fri, 16 Aug 2019 15:07:06 +0200
+
+fence-agents (4.4.0-1) unstable; urgency=medium
+
+ * New upstream version 4.4.0
+ * Update Standards-Version to 4.4.0
+ * Refresh patches for new version
+ * Update lintian override for manpage
+
+ -- Valentin Vidic <vvidic@debian.org> Sun, 14 Jul 2019 14:00:16 +0200
+
+fence-agents (4.3.3-2) unstable; urgency=high
+
+ * fence_rhevm: add patch for CVE-2019-10153 (Closes: #930887)
+ Including non-ASCII characters in a guest VM's comment or other fields
+ would cause fence_rhevm to exit with an exception.
+
+ -- Valentin Vidic <vvidic@debian.org> Sun, 23 Jun 2019 19:53:35 +0200
+
+fence-agents (4.3.3-1) unstable; urgency=medium
+
+ * New upstream version 4.3.3
+
+ -- Valentin Vidic <vvidic@debian.org> Mon, 03 Dec 2018 19:32:54 +0100
+
+fence-agents (4.3.2-2) unstable; urgency=medium
+
+ * Pass PING{,4,6}_CMD to configure (Closes: #915240)
+
+ -- Valentin Vidic <vvidic@debian.org> Sun, 02 Dec 2018 10:17:57 +0100
+
+fence-agents (4.3.2-1) unstable; urgency=medium
+
+ * New upstream version 4.3.2
+
+ -- Valentin Vidic <vvidic@debian.org> Thu, 29 Nov 2018 16:34:08 +0100
+
+fence-agents (4.3.1-1) unstable; urgency=medium
+
+ * New upstream version 4.3.1
+ * Refresh patches for new version
+ * Update openstack dependencies
+
+ -- Valentin Vidic <vvidic@debian.org> Thu, 18 Oct 2018 09:02:10 +0200
+
+fence-agents (4.3.0-1) unstable; urgency=medium
+
+ * New upstream version 4.3.0
+ * fence_sbd: fix location of sbd binary
+ * fence_openstack: add required python modules
+ * Skip disabled agents in package description
+ * Refresh patches for new version
+ * Update Standards-Version to 4.2.1
+ * Update my email address in Uploaders
+
+ -- Valentin Vidic <vvidic@debian.org> Sat, 06 Oct 2018 22:30:26 +0200
+
+fence-agents (4.2.1-1) unstable; urgency=medium
+
+ * New upstream version 4.2.1
+ * Refresh patches for new version
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Thu, 31 May 2018 14:44:59 +0200
+
+fence-agents (4.2.0-3) unstable; urgency=medium
+
+ * Move python3-requests and python3-suds to Depends (Closes: #899381)
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Wed, 23 May 2018 17:41:54 +0200
+
+fence-agents (4.2.0-2) unstable; urgency=medium
+
+ * fence_scsi: fix Unicode error with python3 (Closes: #899310)
+ * Add autopkgtest for agent metadata
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Wed, 23 May 2018 16:37:33 +0200
+
+fence-agents (4.2.0-1) unstable; urgency=medium
+
+ * New upstream version 4.2.0
+ * Refresh patches for new version
+ * Ignore long line in manpage
+ * Update debian/copyright after file rename
+ * Include upstream README and API documents
+ * Rename debian/install file
+ * Disable testing for agents accessing the network
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Sun, 20 May 2018 21:41:39 +0200
+
+fence-agents (4.1.1-2) unstable; urgency=medium
+
+ * Update Vcs URLs to use salsa
+ * Update Standards-Version to 4.1.4
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Wed, 11 Apr 2018 16:22:49 +0200
+
+fence-agents (4.1.1-1) unstable; urgency=medium
+
+ * New upstream version 4.1.1
+ * Switch the agents to python3
+ * Refresh patches for new version
+ * Reoder paragraphs in debian/copyright
+ * Switch to debhelper v11
+ * Remove XS-Testsuite from debian/control
+ * Add cleanup of autogenerated files
+ * Enable hardening for compiled agents
+ * BUILD_DATE not needed for reproducible builds anymore
+ * Suggest python3 modules required for fence_azure_arm
+ * Remove unused paragraphs from debian/copyright
+ * Update Standards-Version to 4.1.3
+ * Replace cman Conflicts with Breaks
+ * Add patch for spelling errors reported by lintian
+ * Add descriptions for Debian patches
+ * Add iputils-ping to Build-Depends
+ * Fix version reported by agents
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Sun, 18 Feb 2018 15:29:05 +0100
+
+fence-agents (4.0.25-2) unstable; urgency=medium
+
+ [ Christoph Berg ]
+ * Update watch file and homepage to point at github.
+ * Remove myself from Uploaders.
+
+ [ Valentin Vidic ]
+ * Add myself to uploaders.
+ * Ignore lintian warning for fence_ironic description.
+ * Disable Internet access during build (Closes: #849336)
+ * Update Standards-Version to 4.1.1.
+ * Update debhelper to v10.
+ * Use dh_missing --fail-missing.
+ * Remove trailing whitespace in debian/changelog.
+ * Use versioned URL for debian/copyright Format.
+
+ -- Valentin Vidic <Valentin.Vidic@CARNet.hr> Sun, 03 Dec 2017 20:12:11 +0100
+
+fence-agents (4.0.25-1) unstable; urgency=medium
+
+ * Team upload.
+ * New upstream version.
+
+ -- Christoph Berg <christoph.berg@credativ.de> Mon, 23 Jan 2017 11:36:48 +0100
+
+fence-agents (4.0.24-1) unstable; urgency=medium
+
+ * New upstream version.
+
+ -- Adrian Vondendriesch <adrian.vondendriesch@credativ.de> Sat, 17 Sep 2016 15:56:50 +0200
+
+fence-agents (4.0.23-2) unstable; urgency=medium
+
+ * Set LC_ALL=C when sorting list of agents in the description to get
+ reproducible ordering.
+
+ -- Christoph Berg <myon@debian.org> Thu, 07 Jul 2016 15:53:39 +0200
+
+fence-agents (4.0.23-1) unstable; urgency=medium
+
+ * New upstream version.
+ * Disable the new fence_amt_ws agent because we don't have openwsman
+ (and sblim-sfcc) in Debian yet
+ * Include list of agents in package description.
+
+ -- Christoph Berg <christoph.berg@credativ.de> Wed, 06 Jul 2016 13:33:49 +0200
+
+fence-agents (4.0.22-3) unstable; urgency=medium
+
+ * Add dh_python2 override to compile python files. (Closes: #816270)
+
+ -- Adrian Vondendriesch <adrian.vondendriesch@credativ.de> Sun, 13 Mar 2016 14:41:07 +0100
+
+fence-agents (4.0.22-2) unstable; urgency=medium
+
+ * Grab missing fence_zvm.h from upstream.
+ * Remove fence_zvm on non-s390x, it's a no-op anyway.
+
+ -- Christoph Berg <myon@debian.org> Sat, 06 Feb 2016 12:34:18 +0100
+
+fence-agents (4.0.22-1) unstable; urgency=medium
+
+ * New upstream version.
+
+ -- Christoph Berg <christoph.berg@credativ.de> Fri, 05 Feb 2016 16:55:20 +0100
+
+fence-agents (4.0.21-2) unstable; urgency=medium
+
+ * fence_scsi: Fix /sbin/vgs path.
+
+ -- Christoph Berg <christoph.berg@credativ.de> Thu, 24 Sep 2015 13:43:17 +0200
+
+fence-agents (4.0.21-1) unstable; urgency=medium
+
+ * New upstream version.
+
+ -- Christoph Berg <myon@debian.org> Sat, 12 Sep 2015 18:42:15 +0200
+
+fence-agents (4.0.19-1) unstable; urgency=medium
+
+ [ Adrian Vondendriesch ]
+ * New upstream version.
+ * Remove obsolete "fix-agents" patch. Changes are merged upstream.
+ * Add myself to uploaders.
+ * Add "--fail-missing" to debian/rules.
+ * Add fix-virsh-man-page-unexpected-special-character patch to prevent nroff
+ related lintian errors.
+
+ -- Christoph Berg <myon@debian.org> Mon, 27 Jul 2015 20:29:03 +0200
+
+fence-agents (4.0.18-1) unstable; urgency=medium
+
+ * New upstream version.
+ * Use debian/changelog date for BUILD_DATE in scripts to make package builds
+ reproducible.
+ * Promote python-pycurl and python-pexpect to Depends, they are needed by
+ all scripts.
+ * Remove deprecated XS-Python-Version: current.
+ * Run a simple --help test on all agents.
+
+ -- Christoph Berg <myon@debian.org> Sat, 16 May 2015 19:22:41 +0200
+
+fence-agents (4.0.17-1) unstable; urgency=medium
+
+ * New upstream version.
+ + Verifies remote SSL certificates (implemented in 4.0.12, Closes: #764801).
+ CVE-2014-0104
+ + fence_zvmip was rewritten in Python (Closes: #765191).
+ * Add python-requests and time to Build-Depends, add python-requests and
+ python-suds to Suggests (needed by fence_vmware_soap).
+ * Add dh-python to Build-Depends.
+ * Fix perl dependencies.
+ * Remove hardening-wrapper, use buildflags.mk instead.
+ * Remove obsolete lintian override file.
+ * Add autopkgtest script provided by Alexander Sosna.
+ * Add myself to Uploaders; bump Standards-Version.
+
+ -- Christoph Berg <christoph.berg@credativ.de> Wed, 22 Apr 2015 14:18:52 +0200
+
+fence-agents (4.0.7.1-2.1) unstable; urgency=medium
+
+ * Non-maintainer upload.
+ * Add libxml2-utils to Build-Depends to get xmllint (Closes: #741813).
+
+ -- Aurelien Jarno <aurel32@debian.org> Tue, 23 Sep 2014 20:58:23 +0200
+
+fence-agents (4.0.7.1-2) unstable; urgency=medium
+
+ * New upstream release
+ * debian/control: Bump Standards-Version
+
+ -- Martin Loschwitz <madkiss@debian.org> Fri, 21 Feb 2014 13:09:10 +0000
+
+fence-agents (4.0.0-1) experimental; urgency=low
+
+ * New upstream version
+ * debian/patches/fix_manpages.patch: Drop; it's included upstream now
+
+ -- Martin Loschwitz <madkiss@debian.org> Thu, 21 Mar 2013 08:26:47 +0000
+
+fence-agents (3.1.5-2) unstable; urgency=low
+
+ * Adopted numerous changes from the fence-agents Ubuntu package in order
+ to make co-maintaining this package easier, including these changes:
+ - debian/patches/fix_manpages.patch: Fix some manpage errors.
+ - debian/lintian.overrides: Add lintian overrides.
+ Special thanks goes to Andres Rodriguez from Ubuntu!
+ * Include the files in /usr/share/cluster/relaxng/ in the package
+
+ -- Martin Loschwitz <madkiss@debian.org> Thu, 24 Nov 2011 10:14:01 +0000
+
+fence-agents (3.1.5-1) unstable; urgency=low
+
+ * Initial release (Closes: #538203)
+
+ -- Martin Loschwitz <madkiss@debian.org> Mon, 29 Aug 2011 12:43:41 +0000
diff --git a/debian/clean b/debian/clean
new file mode 100644
index 0000000..d83890e
--- /dev/null
+++ b/debian/clean
@@ -0,0 +1,2 @@
+.tarball-version
+.version
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..26e8d27
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,103 @@
+Source: fence-agents
+Section: admin
+Priority: optional
+Maintainer: Debian HA Maintainers <debian-ha-maintainers@alioth-lists.debian.net>
+Uploaders: Adrian Vondendriesch <adrian.vondendriesch@credativ.de>,
+ Valentin Vidic <vvidic@debian.org>
+Build-Depends: autoconf,
+ automake,
+ bison,
+ debhelper-compat (= 13),
+ dh-python,
+ flex,
+ iputils-ping,
+ libcpg-dev,
+ libglib2.0-dev,
+ libnet-telnet-perl,
+ libnspr4-dev,
+ libnss3-dev,
+ libtool,
+ libvirt-dev,
+ libxml2-dev,
+ libxml2-utils,
+ perl,
+ python3,
+ python3-boto3,
+ python3-googleapi,
+ python3-kubernetes,
+ python3-oauth2client,
+ python3-pexpect,
+ python3-pycurl,
+ python3-requests,
+ python3-suds,
+ systemd,
+ time,
+ uuid-dev,
+ xsltproc,
+Rules-Requires-Root: no
+Standards-Version: 4.6.2
+Homepage: https://github.com/ClusterLabs/fence-agents
+Vcs-Browser: https://salsa.debian.org/ha-team/fence-agents
+Vcs-Git: https://salsa.debian.org/ha-team/fence-agents.git
+
+Package: fence-agents
+Architecture: any
+Depends: ${misc:Depends}, ${perl:Depends}, ${python3:Depends}, ${shlibs:Depends},
+ python3-boto3,
+ python3-googleapi,
+ python3-oauth2client,
+ python3-pycurl,
+ python3-pexpect,
+ python3-requests,
+ python3-suds
+Breaks: cman (<= 3.0.12-2ubuntu4)
+Replaces: cman (<= 3.0.12-2ubuntu4)
+Recommends: libnet-telnet-perl,
+ openssh-client,
+ sg3-utils,
+ snmp
+Suggests: fence-virt,
+# Needed by fence_azure_arm:
+ python3-adal,
+ python3-azure,
+# Needed by fence_openstack:
+ python3-keystoneauth1,
+ python3-keystoneclient,
+ python3-novaclient,
+# Needed by fence_kubevirt:
+ python3-kubernetes,
+Description: Fence Agents for Red Hat Cluster
+ Red Hat Fence Agents is a collection of scripts to handle remote
+ power management for several devices. They allow failed or
+ unreachable nodes to be forcibly restarted and removed from the
+ cluster.
+ .
+ Fence agents included:
+ ${agents}
+
+Package: fence-virt
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: Pluggable fencing framework for virtual machines - agent
+ The fencing framework consists of the agent (fence_virt) and
+ the host daemon (fence_virtd). The fence_virtd host daemon is
+ responsible for processing fencing requests from fence_virt agents
+ running in virtual machines and routing the requests to the
+ appropriate physical machine for action.
+ .
+ This package contains the fence_virt agent to be used inside the
+ virtual machine.
+
+Package: fence-virtd
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Pre-Depends: ${misc:Pre-Depends}
+Description: Pluggable fencing framework for virtual machines - daemon
+ The fencing framework consists of the agent (fence_virt) and
+ the host daemon (fence_virtd). The fence_virtd host daemon is
+ responsible for processing fencing requests from fence_virt agents
+ running in virtual machines and routing the requests to the
+ appropriate physical machine for action.
+ .
+ This package contains the fence_virtd daemon to be used on the
+ physical host.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..d1628f7
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,61 @@
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: fence-agents
+Source: https://github.com/ClusterLabs/fence-agents
+
+Files: *
+Copyright: 1997-2003 Sistina Software, Inc. All rights reserved.
+ 2004-2008 Red Hat, Inc. All rights reserved.
+License: GPL-2+
+
+Files: debian/*
+Copyright: 2011 Andres Rodriguez <andreserl@ubuntu.com>
+ 2011-2014 Martin Loschwitz <madkiss@debian.org>
+ 2014 Aurelien Jarno <aurel32@debian.org>
+ 2014-2017 Christoph Berg <myon@debian.org>
+ 2016 Adrian Vondendriesch <adrian.vondendriesch@credativ.de>
+ 2017-2023 Valentin Vidic <vvidic@debian.org>
+License: GPL-2+
+
+Files: agents/apc_snmp/powernet369.mib
+Copyright: 2005 American Power Conversion, Inc.
+License: GPL-2+
+
+Files: agents/ifmib/fence_ifmib.py
+Copyright: 2008 Ross Vandegrift.
+License: GPL-2+
+
+Files: agents/vmware/fence_vmware_helper.pl
+Copyright: Zach Lowry <zach at zachlowry.net>
+License: GPL-2+
+
+Files: agents/zvm/fence_zvm.*
+Copyright: (C) 2012 Sine Nomine Associates
+License: LGPL-2.1+
+
+License: GPL-2+
+ This package is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+ .
+ This package is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+ .
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>
+ .
+ On Debian systems, the complete text of the GNU General
+ Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
+
+License: LGPL-2.1+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+ .
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
diff --git a/debian/fence-agents.docs b/debian/fence-agents.docs
new file mode 100644
index 0000000..37737c2
--- /dev/null
+++ b/debian/fence-agents.docs
@@ -0,0 +1,2 @@
+README.md
+doc/FenceAgentAPI.md
diff --git a/debian/fence-agents.install b/debian/fence-agents.install
new file mode 100644
index 0000000..61a726a
--- /dev/null
+++ b/debian/fence-agents.install
@@ -0,0 +1,9 @@
+usr/lib/tmpfiles.d/fence-agents.conf
+usr/libexec/fence-agents/fence_kdump_send
+usr/sbin/fence*
+usr/share/cluster/fence*
+usr/share/cluster/relaxng*
+usr/share/doc
+usr/share/fence*
+usr/share/man/man8/fence*
+usr/share/pkgconfig/fence-agents.pc
diff --git a/debian/fence-virt.docs b/debian/fence-virt.docs
new file mode 100644
index 0000000..8049b66
--- /dev/null
+++ b/debian/fence-virt.docs
@@ -0,0 +1,3 @@
+agents/virt/docs/architecture.txt
+agents/virt/docs/fence_virt.txt
+agents/virt/docs/README
diff --git a/debian/fence-virt.install b/debian/fence-virt.install
new file mode 100644
index 0000000..7bbfe98
--- /dev/null
+++ b/debian/fence-virt.install
@@ -0,0 +1,4 @@
+usr/sbin/fence_virt
+usr/sbin/fence_xvm
+usr/share/man/man8/fence_virt.8
+usr/share/man/man8/fence_xvm.8
diff --git a/debian/fence-virtd.docs b/debian/fence-virtd.docs
new file mode 100644
index 0000000..8049b66
--- /dev/null
+++ b/debian/fence-virtd.docs
@@ -0,0 +1,3 @@
+agents/virt/docs/architecture.txt
+agents/virt/docs/fence_virt.txt
+agents/virt/docs/README
diff --git a/debian/fence-virtd.fence_virtd.init b/debian/fence-virtd.fence_virtd.init
new file mode 100644
index 0000000..bef63c3
--- /dev/null
+++ b/debian/fence-virtd.fence_virtd.init
@@ -0,0 +1,26 @@
+#!/bin/sh
+# kFreeBSD do not accept scripts as interpreters, using #!/bin/sh and sourcing.
+if [ true != "$INIT_D_SCRIPT_SOURCED" ] ; then
+ set "$0" "$@"; INIT_D_SCRIPT_SOURCED=true . /lib/init/init-d-script
+fi
+### BEGIN INIT INFO
+# Provides: fence_virtd
+# Required-Start: $remote_fs $syslog
+# Required-Stop: $remote_fs $syslog
+# Should-Start: corosync libvirtd
+# Should-Stop: corosync libvirtd
+# Default-Start: 2 3 4 5
+# Default-Stop: 0 1 6
+# Short-Description: Fence-Virt system host daemon
+# Description: Starts and stops fence_virtd daemon.
+### END INIT INFO
+
+NAME="fence_virtd"
+DESC="fence_virtd daemon"
+DAEMON="/usr/sbin/$NAME"
+PIDFILE="/run/$NAME.pid"
+
+CONFIG="/etc/default/$NAME"
+[ -f "$CONFIG" ] && . "$CONFIG"
+
+DAEMON_ARGS="${FENCE_VIRTD_ARGS:--w}"
diff --git a/debian/fence-virtd.install b/debian/fence-virtd.install
new file mode 100644
index 0000000..3f9f6f1
--- /dev/null
+++ b/debian/fence-virtd.install
@@ -0,0 +1,5 @@
+etc/fence_virt.conf
+usr/lib/*/fence-virt/*.so
+usr/sbin/fence_virtd
+usr/share/man/man5/fence_virt.conf.5
+usr/share/man/man8/fence_virtd.8
diff --git a/debian/fence-virtd.postinst b/debian/fence-virtd.postinst
new file mode 100644
index 0000000..a2fc829
--- /dev/null
+++ b/debian/fence-virtd.postinst
@@ -0,0 +1,45 @@
+#!/bin/sh
+# postinst script for fence-virtd
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postinst> `configure' <most-recently-configured-version>
+# * <old-postinst> `abort-upgrade' <new version>
+# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+# <new-version>
+# * <postinst> `abort-remove'
+# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+# <failed-install-package> <version> `removing'
+# <conflicting-package> <version>
+# for details, see https://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ configure)
+ if ! test -e /etc/fence_virt.key; then
+ OLD_UMASK=$(umask)
+ umask 077
+ dd if=/dev/urandom of=/etc/fence_virt.key bs=4096 count=1 status=none
+ umask "$OLD_UMASK"
+ fi
+ ;;
+
+ abort-upgrade|abort-remove|abort-deconfigure)
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/fence-virtd.postrm b/debian/fence-virtd.postrm
new file mode 100644
index 0000000..22cc7ba
--- /dev/null
+++ b/debian/fence-virtd.postrm
@@ -0,0 +1,41 @@
+#!/bin/sh
+# postrm script for fence-virtd
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postrm> `remove'
+# * <postrm> `purge'
+# * <old-postrm> `upgrade' <new-version>
+# * <new-postrm> `failed-upgrade' <old-version>
+# * <new-postrm> `abort-install'
+# * <new-postrm> `abort-install' <old-version>
+# * <new-postrm> `abort-upgrade' <old-version>
+# * <disappearer's-postrm> `disappear' <overwriter>
+# <overwriter-version>
+# for details, see https://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ purge)
+ rm -f /etc/fence_virt.key
+ ;;
+
+ remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/patches/disable-network-access b/debian/patches/disable-network-access
new file mode 100644
index 0000000..772f614
--- /dev/null
+++ b/debian/patches/disable-network-access
@@ -0,0 +1,27 @@
+Description: Disable Internet access during build
+ Agents try to resolve and access hostname 'test', use
+ 127.0.0.1 instead.
+ .
+ Disable testing for ovh as it tries to access SOAP service
+ on www.ovh.com.
+Author: Valentin Vidic <Valentin.Vidic@CARNet.hr>
+Bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=849336
+Last-Update: 2017-12-03
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/agents/Makefile.am
++++ b/agents/Makefile.am
+@@ -67,11 +67,11 @@
+ FENCE_TEST_ARGS = \
+ login=test\n\
+ passwd=test\n\
+-ipaddr=test\n\
++ipaddr=127.0.0.1\n\
+ port=1\n\
+ managed=1\n\
+ devices=test\n\
+-session_url=http://test\n\
++session_url=http://127.0.0.1\n\
+ email=test@test.te\n\
+ ping_targets=localhost
+
diff --git a/debian/patches/enable-zvm-agent b/debian/patches/enable-zvm-agent
new file mode 100644
index 0000000..4b50e40
--- /dev/null
+++ b/debian/patches/enable-zvm-agent
@@ -0,0 +1,17 @@
+Description: Leave zvm enabled
+ Remove agent after bookworm release.
+Author: Valentin Vidic <vvidic@debian.org>
+Last-Update: 2023-01-14
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/configure.ac
++++ b/configure.ac
+@@ -196,7 +196,7 @@
+ fi
+
+ FENCE_ZVM=0
+-if echo "$AGENTS_LIST" | grep -q -E "zvm( |$)"; then
++if echo "$AGENTS_LIST" | grep -q -E "all|zvm( |$)"; then
+ FENCE_ZVM=1
+ fi
+
diff --git a/debian/patches/fence-virt-key b/debian/patches/fence-virt-key
new file mode 100644
index 0000000..8b517eb
--- /dev/null
+++ b/debian/patches/fence-virt-key
@@ -0,0 +1,17 @@
+Description: Update path for key file
+ Daemon does not start if the key file is missing.
+Author: Valentin Vidic <vvidic@debian.org>
+Last-Update: 2023-01-14
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/agents/virt/config/fence_virt.conf
++++ b/agents/virt/config/fence_virt.conf
+@@ -5,7 +5,7 @@
+
+ listeners {
+ multicast {
+- key_file = "/etc/cluster/fence_xvm.key";
++ key_file = "/etc/fence_virt.key";
+ address = "225.0.0.12";
+ # Needed on Fedora systems
+ interface = "virbr0";
diff --git a/debian/patches/logging-warn-deprecated b/debian/patches/logging-warn-deprecated
new file mode 100644
index 0000000..77ab206
--- /dev/null
+++ b/debian/patches/logging-warn-deprecated
@@ -0,0 +1,65 @@
+Description: Replace deprecated logging function
+Author: Valentin Vidic <vvidic@debian.org>
+Last-Update: 2022-05-01
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/agents/aliyun/fence_aliyun.py
++++ b/agents/aliyun/fence_aliyun.py
+@@ -15,7 +15,7 @@
+ from aliyunsdkcore.auth.credentials import EcsRamRoleCredential
+ from aliyunsdkcore.profile import region_provider
+ except ImportError as e:
+- logging.warn("The 'aliyunsdkcore' module has been not installed or is unavailable, try to execute the command 'pip install aliyun-python-sdk-core --upgrade' to solve. error: %s" % e)
++ logging.warning("The 'aliyunsdkcore' module has been not installed or is unavailable, try to execute the command 'pip install aliyun-python-sdk-core --upgrade' to solve. error: %s" % e)
+
+
+ try:
+@@ -24,7 +24,7 @@
+ from aliyunsdkecs.request.v20140526.StopInstanceRequest import StopInstanceRequest
+ from aliyunsdkecs.request.v20140526.RebootInstanceRequest import RebootInstanceRequest
+ except ImportError as e:
+- logging.warn("The 'aliyunsdkecs' module has been not installed or is unavailable, try to execute the command 'pip install aliyun-python-sdk-ecs --upgrade' to solve. error: %s" % e)
++ logging.warning("The 'aliyunsdkecs' module has been not installed or is unavailable, try to execute the command 'pip install aliyun-python-sdk-ecs --upgrade' to solve. error: %s" % e)
+
+
+ def _send_request(conn, request):
+@@ -182,7 +182,7 @@
+ try:
+ region_provider.modify_point('Ecs', region, 'ecs.%s.aliyuncs.com' % region)
+ except Exception as e:
+- logging.warn("Failed: failed to modify endpoint to 'ecs.%s.aliyuncs.com': %s" % (region, e))
++ logging.warning("Failed: failed to modify endpoint to 'ecs.%s.aliyuncs.com': %s" % (region, e))
+
+ # Operate the fencing device
+ result = fence_action(conn, options, set_power_status, get_power_status, get_nodes_list)
+--- a/agents/compute/fence_compute.py
++++ b/agents/compute/fence_compute.py
+@@ -98,7 +98,7 @@
+ # Since it's about forcing back to a default value, there is
+ # no real worries to just consider it's still okay even if the
+ # command failed
+- logging.warn("Exception from attempt to force "
++ logging.warning("Exception from attempt to force "
+ "host back up via nova API: "
+ "%s: %s" % (e.__class__.__name__, e))
+
+--- a/agents/sbd/fence_sbd.py
++++ b/agents/sbd/fence_sbd.py
+@@ -170,7 +170,7 @@
+ if "msgwait" in line:
+ tmp_msg_timeout = int(line.split(':')[1])
+ if -1 != msg_timeout and tmp_msg_timeout != msg_timeout:
+- logging.warn(\
++ logging.warning(\
+ "sbd message timeouts differ in different devices")
+ # we only save the highest timeout
+ if tmp_msg_timeout > msg_timeout:
+@@ -418,7 +418,7 @@
+ power_timeout = int(options["--power-timeout"])
+ sbd_msg_timeout = get_msg_timeout(options)
+ if 0 < power_timeout <= sbd_msg_timeout:
+- logging.warn("power timeout needs to be \
++ logging.warning("power timeout needs to be \
+ greater then sbd message timeout")
+
+ result = fence_action(\
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..9c1a18a
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1,6 @@
+disable-network-access
+spelling
+systemd-syslog-target
+logging-warn-deprecated
+enable-zvm-agent
+fence-virt-key
diff --git a/debian/patches/spelling b/debian/patches/spelling
new file mode 100644
index 0000000..c1cacd9
--- /dev/null
+++ b/debian/patches/spelling
@@ -0,0 +1,37 @@
+Description: Fix spelling errors reported by lintian
+Author: Valentin Vidic <Valentin.Vidic@CARNet.hr>
+Forwarded: not-needed
+Last-Update: 2018-02-18
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/agents/ironic/fence_ironic.py
++++ b/agents/ironic/fence_ironic.py
+@@ -110,7 +110,7 @@
+ options = check_input(device_opt, process_input(device_opt))
+
+ docs = {}
+- docs["shortdesc"] = "Fence agent for OpenStack's Ironic (Bare Metal as a service) service"
++ docs["shortdesc"] = "Fence agent for OpenStack's Ironic (Bare Metal as a service)"
+ docs["longdesc"] = "fence_ironic is a Fencing agent \
+ which can be used with machines controlled by the Ironic service. \
+ This agent calls the openstack CLI. \
+--- a/tests/data/metadata/fence_ironic.xml
++++ b/tests/data/metadata/fence_ironic.xml
+@@ -1,5 +1,5 @@
+ <?xml version="1.0" ?>
+-<resource-agent name="fence_ironic" shortdesc="Fence agent for OpenStack's Ironic (Bare Metal as a service) service" >
++<resource-agent name="fence_ironic" shortdesc="Fence agent for OpenStack's Ironic (Bare Metal as a service)" >
+ <longdesc>fence_ironic is a Fencing agent which can be used with machines controlled by the Ironic service. This agent calls the openstack CLI. WARNING! This fence agent is not intended for production use. Relying on a functional ironic service for fencing is not a good design choice.</longdesc>
+ <vendor-url>https://wiki.openstack.org/wiki/Ironic</vendor-url>
+ <parameters>
+--- a/tests/data/metadata/fence_kdump.xml
++++ b/tests/data/metadata/fence_kdump.xml
+@@ -3,7 +3,7 @@
+ <longdesc>fence_kdump is an I/O fencing agent to be used with the kdump
+ crash recovery service. When the fence_kdump agent is invoked,
+ it will listen for a message from the failed node that acknowledges
+-that the failed node it executing the kdump crash kernel.
++that the failed node is executing the kdump crash kernel.
+ Note that fence_kdump is not a replacement for traditional
+ fencing methods. The fence_kdump agent can only detect that a
+ node has entered the kdump crash recovery service. This allows the
diff --git a/debian/patches/systemd-syslog-target b/debian/patches/systemd-syslog-target
new file mode 100644
index 0000000..f8bf295
--- /dev/null
+++ b/debian/patches/systemd-syslog-target
@@ -0,0 +1,16 @@
+Description: Remove syslog target from systemd service file
+ Fixes systemd-service-file-refers-to-obsolete-target lintian warning
+Author: Valentin Vidic <vvidic@debian.org>
+Last-Update: 2022-05-01
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/agents/virt/fence_virtd.service.in
++++ b/agents/virt/fence_virtd.service.in
+@@ -5,7 +5,6 @@
+
+ After=basic.target
+ After=network.target
+-After=syslog.target
+ After=libvirtd.service
+ After=corosync.service
+
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..56ca903
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,93 @@
+#!/usr/bin/make -f
+
+export DEB_BUILD_MAINT_OPTIONS = hardening=+all
+DPKG_EXPORT_BUILDFLAGS = 1
+include /usr/share/dpkg/buildflags.mk
+include /usr/share/dpkg/pkg-info.mk
+include /usr/share/dpkg/architecture.mk
+
+# Fix FTBFS in s390x with GCC 12
+ifeq ($(DEB_HOST_ARCH),s390x)
+export DEB_CFLAGS_MAINT_APPEND=-Wno-stringop-truncation
+endif
+
+%:
+ dh $@ --with python3
+
+override_dh_autoreconf:
+ # fix version reported by agents
+ echo $(DEB_VERSION_UPSTREAM) > .tarball-version
+ dh_autoreconf ./autogen.sh
+
+override_dh_auto_configure:
+ dh_auto_configure -- \
+ --libexecdir=/usr/libexec/fence-agents \
+ --with-fencetmpdir=/run/fence-agents \
+ PING_CMD=/bin/ping \
+ PING6_CMD=/bin/ping6 \
+ PING4_CMD="/bin/ping -4" \
+ PYTHON=/usr/bin/python3 \
+ SBD_PATH=/usr/sbin/sbd \
+ VGS_PATH=/sbin/vgs
+
+override_dh_auto_build:
+ LC_ALL=C dh_auto_build
+
+override_dh_auto_install:
+ $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
+
+override_dh_install:
+ rm -v debian/tmp/usr/share/doc/fence-agents/COPY*
+ rm -v debian/tmp/usr/share/doc/fence-agents/README.licence
+ rmdir debian/tmp/usr/share/doc/fence-agents
+ifneq ($(DEB_HOST_ARCH),s390x)
+ # remove fence_zvm because it doesn't do anything except on 390x
+ rm -v debian/tmp/usr/sbin/fence_zvm
+ rm -v debian/tmp/usr/share/man/man8/fence_zvm.8
+endif
+ dh_install
+ # test agents (skip ack_manual, it doesn't have --help, skip vmware_helper, it wants VIRuntime.pm)
+ # we test in tmp after install so the .pyc files generated don't make it into the package
+ for agent in debian/tmp/usr/sbin/*; do \
+ case $${agent##*/} in fence_ack_manual|fence_vmware_helper|fence_virt) continue;; esac; \
+ echo "Testing $$agent"; \
+ PYTHONPATH=debian/tmp/usr/share/fence $$agent --help >/dev/null || exit; \
+ done
+ # fence_virt is in a separate package
+ rm -v debian/fence-agents/usr/sbin/fence_virt
+ rm -v debian/fence-agents/usr/sbin/fence_virtd
+ rm -v debian/fence-agents/usr/sbin/fence_xvm
+ rm -v debian/fence-agents/usr/share/man/man8/fence_virt.8
+ rm -v debian/fence-agents/usr/share/man/man8/fence_virtd.8
+ rm -v debian/fence-agents/usr/share/man/man8/fence_xvm.8
+
+# tests are slow and require network access so moved to debian/tests/{delay,metadata}
+override_dh_auto_test:
+
+override_dh_python3:
+ dh_python3
+ dh_python3 /usr/share/fence
+
+override_dh_installsystemd:
+ mkdir -p debian/fence-virtd/lib/systemd/system/
+ cp agents/virt/fence_virtd.service debian/fence-virtd/lib/systemd/system/
+ dh_installsystemd -pfence-virtd
+
+override_dh_installinit:
+ dh_installinit -pfence-virtd --name=fence_virtd
+
+override_dh_missing:
+ rm debian/tmp/usr/lib/*/fence-virt/*.*a
+ dh_missing --fail-missing
+
+override_dh_gencontrol:
+ # extract agent descriptions for use in debian/control
+ export LC_ALL=C; \
+ ( echo -n "agents="; \
+ sed -ne 's/<resource-agent name="\(.*\)" shortdesc="\(.*\)".*/\1: \2/p' tests/data/metadata/*.xml | \
+ sed -e 's/\(I.O \)\?\(Fence\|Fencing\) agent for //' | \
+ grep -v 'fence_amt_ws:\|fence_virt:' | \
+ while read line; do echo -n " $$line\$${Newline}"; done ; \
+ echo ; \
+ ) >> debian/fence-agents.substvars
+ dh_gencontrol
diff --git a/debian/salsa-ci.yml b/debian/salsa-ci.yml
new file mode 100644
index 0000000..33c3a64
--- /dev/null
+++ b/debian/salsa-ci.yml
@@ -0,0 +1,4 @@
+---
+include:
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/salsa-ci.yml
+ - https://salsa.debian.org/salsa-ci-team/pipeline/raw/master/pipeline-jobs.yml
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..0abf418
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,20 @@
+Tests: metadata
+Depends: fence-agents, python3-openstackclient, xsltproc, libxml2-utils, gawk
+
+Tests: delay
+Depends: fence-agents, python3-openstackclient, time, iputils-ping
+
+Tests: fence-dummy
+Depends: fence-agents
+Restrictions: allow-stderr
+
+Tests: fence-aws
+Depends: fence-agents
+Restrictions: skippable
+
+Test-Command: /usr/sbin/fence_virt -h
+Depends: fence-virt
+
+Test-Command: service fence_virtd status
+Depends: fence-virtd
+Restrictions: needs-root, isolation-container
diff --git a/debian/tests/delay b/debian/tests/delay
new file mode 100755
index 0000000..ad0af03
--- /dev/null
+++ b/debian/tests/delay
@@ -0,0 +1,34 @@
+#!/bin/sh
+
+set -e
+
+DEFAULT_ARGS='delay=10\n login=test\n passwd=test\n ipaddr=127.0.0.1\n port=1\n managed=1\n devices=test\n session_url=http://127.0.0.1\n email=test@test.te\n ping_targets=localhost'
+OUTPUT=$AUTOPKGTEST_TMP/delay
+mkdir -p $OUTPUT
+
+for agent in /usr/sbin/fence_*; do
+ [ "$agent" = "/usr/sbin/fence_ack_manual" ] && continue
+ [ "$agent" = "/usr/sbin/fence_kdump" ] && continue
+
+ ARGS="$DEFAULT_ARGS"
+ if [ "$agent" = "/usr/sbin/fence_cisco_mds" ]; then
+ ARGS=$(echo "$ARGS" | sed 's#port=1#port=fc1/1#')
+ fi
+ LOG="$OUTPUT/$(basename $agent)"
+
+ (
+ TIME=$(/usr/bin/time -p sh -c "printf '$ARGS' | $agent " 2>&1 | awk -F"[. ]" -vOFS= '/real/ {print $2,$3}')
+ if [ "$TIME" -lt 1000 ]; then
+ echo "$agent delay too low: $TIME" | tee $LOG
+ else
+ echo "$agent delay ok: $TIME" | tee $LOG
+ fi
+ ) &
+ pids="$pids $!"
+done
+
+wait $pids
+
+if grep -qr 'delay too low' $OUTPUT; then
+ exit 1
+fi
diff --git a/debian/tests/fence-aws b/debian/tests/fence-aws
new file mode 100755
index 0000000..21a3dab
--- /dev/null
+++ b/debian/tests/fence-aws
@@ -0,0 +1,47 @@
+#!/bin/sh
+
+set -e
+
+if [ -z "$AWS_INSTANCE_ID" ] || [ -z "$AWS_REGION" ] || \
+ [ -z "$AWS_ACCESS_KEY" ] || [ -z "$AWS_SECRET_KEY" ];
+then
+ echo "AWS environment not found, skipping test."
+ exit 77
+fi
+
+test_aws() {
+ printf "\n=== $1 ===\n"
+ /usr/sbin/fence_aws -r $AWS_REGION -a $AWS_ACCESS_KEY -s $AWS_SECRET_KEY -n $AWS_INSTANCE_ID -o $1
+}
+
+printf "=== version ===\n"
+/usr/sbin/fence_aws -V
+
+test_aws list
+
+if test_aws status
+then # instance is running
+ test_aws reboot
+ sleep 30
+ test_aws status
+
+ test_aws off
+ sleep 30
+ test_aws status || true
+
+ test_aws on
+ sleep 30
+ test_aws status
+else # instance is stopped
+ test_aws on
+ sleep 30
+ test_aws status
+
+ test_aws reboot
+ sleep 30
+ test_aws status
+
+ test_aws off
+ sleep 30
+ test_aws status || true
+fi
diff --git a/debian/tests/fence-dummy b/debian/tests/fence-dummy
new file mode 100755
index 0000000..c0b2ba3
--- /dev/null
+++ b/debian/tests/fence-dummy
@@ -0,0 +1,14 @@
+#!/bin/sh
+
+set -ex
+
+# clean up
+rm -f /tmp/fence_dummy.status
+trap "rm -f /tmp/fence_dummy.status" 0 2 3 15
+
+/usr/sbin/fence_dummy -V
+
+/usr/sbin/fence_dummy -v
+
+# show status from /tmp/fence_dummy.status
+/usr/sbin/fence_dummy -o status
diff --git a/debian/tests/metadata b/debian/tests/metadata
new file mode 100755
index 0000000..21c1ece
--- /dev/null
+++ b/debian/tests/metadata
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+set -e
+
+TMPXML=$AUTOPKGTEST_TMP/xml
+
+for agent in /usr/sbin/fence_*; do
+ [ "$agent" = "/usr/sbin/fence_ack_manual" ] && continue
+
+ printf '\nTesting %s...\n' "$agent"
+ $agent -o metadata > "$TMPXML" 2> /dev/null
+ cat "$TMPXML"
+
+ TESTXML=tests/data/metadata/${agent##*/}.xml
+ if [ -f "$TESTXML" ]; then
+ gawk 'BEGIN {store=-1} /name=".*_path"/ || /name=".*_file"/ {store=2} {if (store!=0) {print}; store--}' "$TMPXML" \
+ | diff -u "$TESTXML" -
+ fi
+
+ xsltproc lib/fence2rng.xsl "$TMPXML" \
+ | sed -e 's/ rha:description=/ description=/g' -e 's/ rha:name=/ name=/g' \
+ | xmllint --nsclean --noout -
+done
diff --git a/debian/upstream/metadata b/debian/upstream/metadata
new file mode 100644
index 0000000..d687187
--- /dev/null
+++ b/debian/upstream/metadata
@@ -0,0 +1,4 @@
+Bug-Database: https://github.com/ClusterLabs/fence-agents/issues
+Bug-Submit: https://github.com/ClusterLabs/fence-agents/issues/new
+Repository: https://github.com/ClusterLabs/fence-agents.git
+Repository-Browse: https://github.com/ClusterLabs/fence-agents
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..135e13e
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,2 @@
+version=4
+https://github.com/ClusterLabs/fence-agents/tags .*/v([\d\.]*.*)\.tar\.gz