summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authoraulonsal2021-06-28 06:50:58 +0530
committeraulonsal2021-06-28 06:50:58 +0530
commit6bdecee0cd2810fa11dbdddb1b9f16404ca164cd (patch)
treecb31c4cdf2f0da350f59a49b17e94391c3274e53
parent7dd4b313727f734e45247b74a5d3402dad1667f0 (diff)
downloadaur-6bdecee0cd2810fa11dbdddb1b9f16404ca164cd.tar.gz
upgpkg: pyroscope-bin 0.0.34-2
Install the binary with group and user set to pyroscope and then set the SUID and SGID bits to enable running `pyroscope server` as non-pyroscope, non-root users, as that seems to be an intended use case from the documentation.
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD3
-rw-r--r--pyroscope.install8
3 files changed, 12 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 147f342efdd0..0ae4d5235761 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,8 +1,9 @@
pkgbase = pyroscope-bin
pkgdesc = Continuous profiling platform
pkgver = 0.0.34
- pkgrel = 1
+ pkgrel = 2
url = https://pyroscope.io/
+ install = pyroscope.install
arch = x86_64
arch = aarch64
license = APACHE
diff --git a/PKGBUILD b/PKGBUILD
index d997fc960b68..73ab1892494d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,13 +1,14 @@
# Maintainer: aulonsal <aulonsal at gmail dot com>
pkgname=pyroscope-bin
pkgver=0.0.34
-pkgrel=1
+pkgrel=2
pkgdesc="Continuous profiling platform"
arch=(x86_64 aarch64)
url="https://pyroscope.io/"
license=('APACHE')
provides=("${pkgname%-bin}")
conflicts=("${pkgname%-bin}")
+install=pyroscope.install
backup=("etc/${pkgname%-bin}/server.yml" "etc/default/${pkgname%-bin}")
source=(
"$pkgname-$pkgver-server.service::https://raw.githubusercontent.com/pyroscope-io/${pkgname%-bin}/v$pkgver/scripts/packages/pyroscope-server.service"
diff --git a/pyroscope.install b/pyroscope.install
new file mode 100644
index 000000000000..07c8b3f5a5f8
--- /dev/null
+++ b/pyroscope.install
@@ -0,0 +1,8 @@
+post_install() {
+ chown pyroscope: /usr/bin/pyroscope
+ chmod ug+s /usr/bin/pyroscope
+}
+
+post_upgrade() {
+ post_install
+}