summaryrefslogtreecommitdiff
path: root/pcr/openrc-net
diff options
context:
space:
mode:
authorOmar Vega Ramos <ovruni@gnu.org.pe>2016-01-02 12:14:50 -0500
committerOmar Vega Ramos <ovruni@gnu.org.pe>2016-01-02 12:14:50 -0500
commit6d7a251bc9c86562e1b2c5c5e4a8cb82c647bb36 (patch)
tree76672b04d3a83dda803f5f66e0dc1f7a1698f0a9 /pcr/openrc-net
parent1fc9c5931bda6129d3a8fe1525b8e6bdf81e6ef3 (diff)
downloadabslibre-6d7a251bc9c86562e1b2c5c5e4a8cb82c647bb36.tar.gz
abslibre-6d7a251bc9c86562e1b2c5c5e4a8cb82c647bb36.tar.bz2
abslibre-6d7a251bc9c86562e1b2c5c5e4a8cb82c647bb36.zip
openrc-net-20151230-1: updating version
Diffstat (limited to 'pcr/openrc-net')
-rw-r--r--pcr/openrc-net/PKGBUILD31
-rw-r--r--pcr/openrc-net/snort.install16
2 files changed, 40 insertions, 7 deletions
diff --git a/pcr/openrc-net/PKGBUILD b/pcr/openrc-net/PKGBUILD
index 59f6086b4..2385d6e0e 100644
--- a/pcr/openrc-net/PKGBUILD
+++ b/pcr/openrc-net/PKGBUILD
@@ -41,8 +41,9 @@ pkgname=('autofs-openrc'
'wicd-openrc'
'syncthing-openrc'
'nginx-openrc'
- 'vnstat-openrc')
-pkgver=20151228
+ 'vnstat-openrc'
+ 'snort-openrc')
+pkgver=20151230
pkgrel=1
pkgdesc="OpenRC init scripts"
arch=('any')
@@ -124,7 +125,9 @@ source=("${_dev_uri}/gentoo-apache-${_apver}-${_aprel}.tar.bz2"
"vnstatd.initd::${_gentoo_uri}/net-analyzer/vnstat/files/vnstatd.initd-r1"
"wicd.initd"
"syncthing.confd"
- "syncthing.initd")
+ "syncthing.initd"
+ "snort.confd::${_gentoo_uri}/net-analyzer/snort/files/snort.confd.2"
+ "snort.initd::${_gentoo_uri}/net-analyzer/snort/files/snort.rc12")
sha256sums=('8e093a18582c3a20283ed1c09de9acc6832a80b1d5a02962599db0535d38af19'
'3cf1ab72446cb9417de916e4cd732f2056fb74d2c6f03da6741b7bae8c415448'
'7837345357a7c0162f2bd7aada22329c89b516a85af227a5d3d81afd1000a969'
@@ -199,11 +202,13 @@ sha256sums=('8e093a18582c3a20283ed1c09de9acc6832a80b1d5a02962599db0535d38af19'
'3c9a1c10c3554a544c8075303e37a4aca7a9e742be37b83d27db17fb28ab869a'
'66b2b53b077ddc2d5eb1d81faa99fa0f4f0db01520900ba948001e539bfe02d8'
'eb4a4315916fe3f8688c1da5bb5c249a1f402e61617452288d5b0668078c955c'
- '63708b1a7b61ae791df64bb4cefa01dc12236f96bb67fe6d0b2c513e11c81f3e')
+ '63708b1a7b61ae791df64bb4cefa01dc12236f96bb67fe6d0b2c513e11c81f3e'
+ '337378f098e0cd59fb5c28a26b5b74b32168cf48596064469e6a5ba04fe3a36f'
+ '0a2a82a022e16f21d2c3c873ed75be9fd2931fd37292203c23ee4462ab2eecb4')
-pkgver() {
- date +%Y%m%d
-}
+#pkgver() {
+# date +%Y%m%d
+#}
_inst_initd(){
install -Dm755 ${srcdir}/$1.initd ${pkgdir}/etc/init.d/$1
@@ -718,3 +723,15 @@ package_vnstat-openrc() {
_inst_confd 'vnstatd'
_inst_initd 'vnstatd'
}
+
+package_snort-openrc() {
+ pkgdesc="OpenRC snort init script"
+ depends=('openrc' 'snort')
+ optdepends=('mysql-openrc: mysql initscript'
+ 'postgresql-openrc: postgresql initscript')
+ backup=('etc/conf.d/snort')
+ install=snort.install
+
+ _inst_confd 'snort'
+ _inst_initd 'snort'
+}
diff --git a/pcr/openrc-net/snort.install b/pcr/openrc-net/snort.install
new file mode 100644
index 000000000..5514fbee9
--- /dev/null
+++ b/pcr/openrc-net/snort.install
@@ -0,0 +1,16 @@
+_svc="snort"
+_rlvl="default"
+
+post_install() {
+ _cmd="rc-update add ${_svc} ${_rlvl}"
+ echo " ==> run '${_cmd}'"
+}
+
+post_upgrade() {
+ post_install "$1"
+}
+
+post_remove() {
+ _cmd="rc-update del ${_svc} ${_rlvl}"
+ echo " ==> run '${_cmd}'"
+}