mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-10 03:54:07 +02:00
160 lines
6.7 KiB
Text
160 lines
6.7 KiB
Text
# Maintainer: Saarko Eilers <saarko@tutanota.com>
|
|
# Contributor: Saarko Eilers <saarko@tutanota.com>
|
|
# Contributor: Holger Weiss <holger@zedat.fu-berlin.de>
|
|
pkgname=eturnal
|
|
pkgver=1.12.2
|
|
pkgrel=0
|
|
pkgdesc="STUN/TURN server"
|
|
url="https://eturnal.net"
|
|
arch="all"
|
|
license="Apache-2.0"
|
|
makedepends="
|
|
erlang-dev
|
|
openssl-dev
|
|
yaml-dev
|
|
"
|
|
_erldepends="
|
|
accept
|
|
conf
|
|
fast_tls
|
|
fast_yaml
|
|
influx_udp
|
|
p1_utils
|
|
poolboy
|
|
prometheus
|
|
prometheus_httpd
|
|
quantile_estimator
|
|
recon
|
|
stun
|
|
ulitos
|
|
yval
|
|
"
|
|
_accept=0.3.6
|
|
_conf=0.2.6
|
|
_fast_tls=1.1.22
|
|
_fast_yaml=1.0.37
|
|
_influx_udp=1.1.2
|
|
_p1_utils=1.0.26
|
|
_poolboy=1.5.2
|
|
_prometheus=4.13.0
|
|
_prometheus_httpd=2.1.14
|
|
_quantile_estimator=1.0.2
|
|
_recon=2.5.6
|
|
_stun=1.2.19
|
|
_ulitos=0.4.0
|
|
_yval=1.0.10
|
|
_profile="prod"
|
|
pkgusers="$pkgname"
|
|
pkggroups="$pkgname"
|
|
subpackages="$pkgname-doc $pkgname-openrc"
|
|
install="$pkgname.pre-install"
|
|
source="
|
|
https://eturnal.net/download/eturnal-$pkgver.tar.gz
|
|
https://repo.hex.pm/tarballs/accept-$_accept.tar
|
|
https://repo.hex.pm/tarballs/conf-$_conf.tar
|
|
https://repo.hex.pm/tarballs/fast_tls-$_fast_tls.tar
|
|
https://repo.hex.pm/tarballs/fast_yaml-$_fast_yaml.tar
|
|
https://repo.hex.pm/tarballs/influx_udp-$_influx_udp.tar
|
|
https://repo.hex.pm/tarballs/p1_utils-$_p1_utils.tar
|
|
https://repo.hex.pm/tarballs/poolboy-$_poolboy.tar
|
|
https://repo.hex.pm/tarballs/prometheus-$_prometheus.tar
|
|
https://repo.hex.pm/tarballs/prometheus_httpd-$_prometheus_httpd.tar
|
|
https://repo.hex.pm/tarballs/quantile_estimator-$_quantile_estimator.tar
|
|
https://repo.hex.pm/tarballs/recon-$_recon.tar
|
|
https://repo.hex.pm/tarballs/stun-$_stun.tar
|
|
https://repo.hex.pm/tarballs/ulitos-$_ulitos.tar
|
|
https://repo.hex.pm/tarballs/yval-$_yval.tar
|
|
0-eturnal.yml.patch
|
|
1-eturnalctl.patch
|
|
eturnal.logrotate
|
|
eturnal.initd
|
|
eturnal.confd
|
|
"
|
|
|
|
prepare() {
|
|
default_prepare
|
|
# each archive retrieved from hex.pm contains a contents.tar.gz, extract
|
|
# that into _build/default/lib/$dep:
|
|
local libdir="$builddir"/_build/default/lib
|
|
for dep in $_erldepends
|
|
do
|
|
local depvsn='' # Make ShellCheck (SC2154) happy.
|
|
eval depvsn='$_'$dep
|
|
local depdir="$libdir"/$dep
|
|
local deptar="$srcdir"/$dep-$depvsn.tar
|
|
mkdir -p "$depdir"
|
|
tar -C "$builddir" -xf "$deptar" contents.tar.gz
|
|
tar -C "$depdir" -xzf "$builddir"/contents.tar.gz
|
|
rm "$builddir"/contents.tar.gz
|
|
done
|
|
}
|
|
|
|
build() {
|
|
export ETURNAL_PREFIX="/usr/lib/eturnal"
|
|
./rebar3 as $_profile release
|
|
}
|
|
|
|
check() {
|
|
./rebar3 xref
|
|
./rebar3 eunit
|
|
./rebar3 ct
|
|
}
|
|
|
|
package() {
|
|
# eturnal main package:
|
|
## create application directory
|
|
install -dm755 "$pkgdir"/usr/lib/$pkgname
|
|
## install application files
|
|
install -Dm755 \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/bin/eturnalctl \
|
|
"$pkgdir"/usr/sbin/eturnalctl
|
|
rm "$builddir"/_build/$_profile/rel/$pkgname/bin/eturnalctl
|
|
cp -r \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/bin \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/lib \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/releases \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/erts-* \
|
|
"$pkgdir"/usr/lib/$pkgname
|
|
## install configuration file
|
|
install -Dm640 -o $pkgusers -g $pkggroups \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/etc/$pkgname.yml \
|
|
"$pkgdir"/etc/$pkgname.yml
|
|
## create log directory
|
|
install -dm755 -o $pkgusers -g $pkggroups "$pkgdir"/var/log/$pkgname
|
|
## install init script and logrotate configuration
|
|
install -Dm755 \
|
|
"$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
|
|
install -Dm644 \
|
|
"$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
|
|
install -Dm644 \
|
|
"$srcdir"/$pkgname.logrotate "$pkgdir"/etc/logrotate.d/$pkgname
|
|
# eturnal-doc package:
|
|
install -Dm644 \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/doc/LICENSE.txt \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/doc/README.md \
|
|
"$builddir"/_build/$_profile/rel/$pkgname/doc/CHANGELOG.md \
|
|
-t "$pkgdir"/usr/share/doc/$pkgname
|
|
}
|
|
|
|
sha512sums="
|
|
a121834b6461c30214aba95576bb2baec7bdd2e1c9cd7061ec16e21d3c2ff55c24f07b35eb1138d40a57185c8bceef7a4868c60c4875fccd6e6ee5833f19ad22 eturnal-1.12.2.tar.gz
|
|
f2e285515da75569b34c37bb61ce4cda5d6f9aa9dc55f7256ac75f7e9c42ce34048377d6876d304f0c4c663f0bccaa8160726f0d463c2fcd101680a18a9f028e accept-0.3.6.tar
|
|
25628322f77b2d5f359d4197a4da8578159f26d960fc73781839b91da3206591e2613d34fb91dc0443c32c2135ba9f56ed82b85fc613170f97a78efe931eb90e conf-0.2.6.tar
|
|
3dfde6fc2f76f20d98afc9d43b19e55a437e70d301766cdab1906a67493e5d0fc0170966aa218a13fca4749bc55c8a8524af65350c948f8390113a93825a1c89 fast_tls-1.1.22.tar
|
|
40da4e88f8c285fa06956a477ec285e65d8e0174a2d38c7fbe084a0514a57e43d9eb09911686cf954419215ee5fdd7c59a2920ea2427750fc2e8331541690238 fast_yaml-1.0.37.tar
|
|
99a039fab1dbaded923ad694d86d56c784b0f5a0457aa743ff8620b0dd820cd196e32fdf6964bac776a77c0917b2d642e0c4295ccd9f1ba353aaf956f2ae8563 influx_udp-1.1.2.tar
|
|
b24a3895420354d304e869d84043fb7c2c044bce45821702a531d9f14e4aee4774c6a7343f5f2cf55714500d8fefcda9d32b7764221ab276db5fb338a00d9822 p1_utils-1.0.26.tar
|
|
d44621286277d3a3c4590ad24d4771245bed649ac40c6b7c6d32fb8d161de943b2599fd4a323551c798dbe2a39b4594dd701e1364a676295b73a924b2c03e655 poolboy-1.5.2.tar
|
|
e96ca0c7805b1906b99cfca746f6a9342a8123f77a89ad8a198bd36973441596b995b1e555e06ad09c5a51116b8fb9dde298449bd1b1d7976ed778ace970af8a prometheus-4.13.0.tar
|
|
9d95aba3eccc621bff74b98d70317518ec643996dfdf2c862cc39c5835dbfaa8be69bd027bbee3b258c97449d8b2744b51f920820b5b5d7edc57889786b2c69c prometheus_httpd-2.1.14.tar
|
|
be30bc59a7d01770b4fadf6a978d25610663281ee27110f83c7adb84a98b16884bcd790ca9b0d2cfa051ba084e98a852879ab8cb6f44836cde4c19209b8db9cf quantile_estimator-1.0.2.tar
|
|
105430ddc15f1c66d6559c3314a2aa9be213ab9fe8401c80cb912cd624bf14dc7dc79632ece37e27a8a63506b18b4cddae25b5e77b56907c54597797b6e670f6 recon-2.5.6.tar
|
|
897f1164046ba9f748faa4245d78dedefa24b6476ac50c3fa793bf5b658a2cf8253eedb9bddfb6e04a5565f367250a631e62c16607762a50d92ff43f88f634dc stun-1.2.19.tar
|
|
06f28e7ef6e6505d6adc2240c847ef53f908ab83fd100f022ef8c364aa31c579fe4567994c1bf6f1151c1d25e4738600e74edcce4d8447eebe1f527252a609ca ulitos-0.4.0.tar
|
|
25f815c751ce0dd1d045cdae92d8c5697ac07b88eae1a47b9381e2efc1eabc2c02e4d0a5347fa9ddf8de0f3df9aba04ccc35d54fae4829af655ee6e1183bde7a yval-1.0.10.tar
|
|
d30251616f555d6ccbb47a9bff3ee33eda1c4d4a73dd1e140ff036706eb20a02062cc68e78f3c0a19597e72389a27af592e101d86fcb5f0aaaec30febff57e6e 0-eturnal.yml.patch
|
|
cdf20cad2b07acf50a31aafe4ab2cd3b1a1ca2e4feb226296a040466fa801ab5073025c6c16b87651b44bb7ebbba56f4ed020828b4ab5b82bafe75fe4709f403 1-eturnalctl.patch
|
|
ac7be5b7bb7be2d51b52b3dadd5976f45e0980b43ac43451043756543cbcf954f54eacc66ada7e5c2f9cf9630755d75065f4eb194ee1f7ad6a2199dcec322f04 eturnal.logrotate
|
|
b0dd673fa2165c2d238e1edb18bdeabbed69140bd3d16b50d8bda54131671c482279902c5f7c545c887136a9d26dbb216968e8896f55f08343a2a6d5575578c0 eturnal.initd
|
|
29338c6cf5c79c5c4b0cc739f479f42a8af7c654ce4f5f945f973026256666cc152cf049e6caf7ae2e3f9fb456851fa6e29bb2b39fbf33d2cae094e3a05289a5 eturnal.confd
|
|
"
|