summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 9af52ace994515c8fec50d05ba4df46ef2bf87e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Maintainer: Fallstar <fallstar at daze dot pw>
pkgname=reaction-git
pkgver=r128.e1ff702
pkgrel=1
pkgdesc="A daemon that scans program outputs for repeated patterns, and takes action. Alternative to fail2ban"
arch=('any')
url="https://framagit.org/ppom/reaction"
license=('AGPL')
makedepends=('git' 'go' 'gcc')
provides=('reaction' 'ip46tables')
source=("${pkgname}::git+https://framagit.org/ppom/reaction.git")
sha256sums=('SKIP')

pkgver() {
  cd "${pkgname}"
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}


build() {
    cd "${pkgname}"
    make
}

package() {

    install -Dm755 "${pkgname}/reaction" "${pkgdir}/usr/bin/reaction"
    install -Dm755 "${pkgname}/ip46tables" "${pkgdir}/usr/bin/ip46tables"
    install -Dm644 "${pkgname}/config/reaction.debian.service" "${pkgdir}/usr/lib/systemd/system/reaction.service"
    install -Dm644 "${pkgname}/config/example.jsonnet" "${pkgdir}/etc/reaction.jsonnet"
}