From ef174d26e10f657ba2ac091239432f18a21ca6d2 Mon Sep 17 00:00:00 2001 From: Jakub Jirutka Date: Sun, 16 Oct 2016 13:15:55 +0200 Subject: testing/consul: remove {post,pre}-deinstall hooks post-deinstall: - Removing user/group is not a good idea. You can't know if the consul user/group has been created by the package or not; user can use it even for something else. pre-deinstall: - User should decide h[ei]mself if (s)he wants to stop the service before uninstalling, it's his/her responsibility and it should not be handled automagically in pre-deinstall hook. - `&>` is not POSIX-sh compatible, it's a bashism. --- testing/consul/APKBUILD | 4 ++-- testing/consul/consul.post-deinstall | 7 ------- testing/consul/consul.pre-deinstall | 6 ------ 3 files changed, 2 insertions(+), 15 deletions(-) delete mode 100644 testing/consul/consul.post-deinstall delete mode 100644 testing/consul/consul.pre-deinstall diff --git a/testing/consul/APKBUILD b/testing/consul/APKBUILD index 2638d44861..11f54888ba 100644 --- a/testing/consul/APKBUILD +++ b/testing/consul/APKBUILD @@ -2,14 +2,14 @@ # Maintainer: pkgname=consul pkgver=0.7.0 -pkgrel=0 +pkgrel=1 pkgdesc="A tool for service discovery, monitoring and configuration" url="https://www.consul.io/" arch="all !aarch64" license="MPL 2.0" depends="" makedepends="go" -install="$pkgname.pre-install $pkgname.pre-deinstall $pkgname.post-deinstall" +install="$pkgname.pre-install" pkgusers="consul" pkggroups="consul" options="!strip" diff --git a/testing/consul/consul.post-deinstall b/testing/consul/consul.post-deinstall deleted file mode 100644 index a4da5f3354..0000000000 --- a/testing/consul/consul.post-deinstall +++ /dev/null @@ -1,7 +0,0 @@ -#!/bin/sh - -# Delete consul group and user -delgroup consul 2> /dev/null -deluser consul 2> /dev/null -exit 0 - diff --git a/testing/consul/consul.pre-deinstall b/testing/consul/consul.pre-deinstall deleted file mode 100644 index e352a05546..0000000000 --- a/testing/consul/consul.pre-deinstall +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh - -# Stop consul service -rc-service consul stop &> /dev/null -exit 0 - -- cgit v1.2.3