diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2021-03-06 22:32:47 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2021-03-06 22:32:47 +0300 |
commit | 4c2f427c3f87a21d96d8069f3356b7e374360349 (patch) | |
tree | 73ad79c58ec87794714853a11bfcf1fc64bfe87d | |
download | linux-status-4c2f427c3f87a21d96d8069f3356b7e374360349.tar.gz linux-status-4c2f427c3f87a21d96d8069f3356b7e374360349.zip |
import pacman packaging from master
Diffstat (limited to '')
-rw-r--r-- | .SRCINFO | 16 | ||||
-rw-r--r-- | .gitattributes | 1 | ||||
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | PKGBUILD | 31 | ||||
-rw-r--r-- | linux-status.install | 19 |
5 files changed, 69 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..e250d88 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,16 @@ +pkgbase = linux-status + pkgdesc = Simple Linux status web page + pkgver = 0.0.1 + pkgrel = 1 + url = https://github.com/egor-tensin/linux-status + install = linux-status.install + arch = any + license = MIT + depends = procps-ng + depends = python + depends = systemd + source = linux-status-0.0.1.tar.gz::https://github.com/egor-tensin/linux-status/archive/v0.0.1.tar.gz + md5sums = SKIP + +pkgname = linux-status + diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..176a458 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..9228191 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +*.tar.zst +*.tar.gz diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..f3c311b --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,31 @@ +# Maintainer: Egor Tensin <Egor.Tensin@gmail.com> +pkgname=linux-status +pkgver=0.0.1 +pkgrel=1 +pkgdesc='Simple Linux status web page' +arch=(any) +url='https://github.com/egor-tensin/linux-status' +license=(MIT) +depends=(procps-ng python systemd) +install=linux-status.install +source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz") +md5sums=(SKIP) + +package() { + cd "$srcdir/$pkgname-$pkgver" + + install -D -m 0644 -t "$pkgdir/usr/share/linux-status" LICENSE.txt + + install -D -m 0644 -t "$pkgdir/usr/share/doc/linux-status" README.md + install -D -m 0644 -t "$pkgdir/usr/share/doc/linux-status/img" img/example.png + + install -D -m 0755 -t "$pkgdir/srv/linux-status" app.py + install -D -m 0755 -t "$pkgdir/srv/linux-status" server.py + + install -D -m 0644 -t "$pkgdir/srv/linux-status" index.html + install -D -m 0644 -t "$pkgdir/srv/linux-status/css" css/bootstrap.min.css + install -D -m 0644 -t "$pkgdir/srv/linux-status/js" js/bootstrap.bundle.min.js + install -D -m 0644 -t "$pkgdir/srv/linux-status/js" js/jquery-3.3.1.min.js + + install -D -m 0644 -t "$pkgdir/usr/lib/systemd/system" dist/systemd/linux-status.service +} diff --git a/linux-status.install b/linux-status.install new file mode 100644 index 0000000..32b9a90 --- /dev/null +++ b/linux-status.install @@ -0,0 +1,19 @@ +post_install() { + systemctl --system daemon-reload + systemctl --system enable linux-status + systemctl --system start linux-status +} + +pre_remove() { + systemctl --system stop linux-status.service + systemctl --system disable linux-status.service + systemctl --system daemon-reload +} + +pre_upgrade() { + pre_remove "$1" +} + +post_upgrade() { + post_install "$1" +} |