extra/nginx to 1.24.0-2

This commit is contained in:
Kevin Mihelich 2023-09-16 14:22:34 +00:00
parent 834d322b69
commit 9bb7d85435
3 changed files with 24 additions and 18 deletions

View file

@ -14,13 +14,11 @@ pkgbase=nginx
pkgname=(nginx nginx-src)
# update tests revision too
pkgver=1.24.0
pkgrel=1
pkgdesc='Lightweight HTTP server and IMAP/POP3 proxy server'
pkgrel=2
arch=(x86_64)
url='https://nginx.org'
license=(custom)
depends=(pcre2 zlib openssl geoip mailcap libxcrypt)
makedepends=(mercurial)
makedepends=(mercurial pcre2 zlib openssl geoip mailcap libxcrypt)
checkdepends=(perl perl-gd perl-io-socket-ssl perl-fcgi perl-cache-memcached
memcached ffmpeg)
backup=(etc/nginx/fastcgi.conf
@ -34,8 +32,8 @@ backup=(etc/nginx/fastcgi.conf
etc/logrotate.d/nginx)
install=nginx.install
source=($url/download/nginx-$pkgver.tar.gz{,.asc}
hg+https://hg.nginx.org/nginx-tests#revision=a797d7428fa5
service
hg+https://hg.nginx.org/nginx-tests#revision=24482e311749
nginx.service
logrotate)
# https://nginx.org/en/pgp_keys.html
validpgpkeys=('B0F4253373F8F6F510D42178520A9993A1C052F8' # Maxim Dounin <mdounin@mdounin.ru>
@ -43,8 +41,8 @@ validpgpkeys=('B0F4253373F8F6F510D42178520A9993A1C052F8' # Maxim Dounin <mdounin
sha512sums=('1114e37de5664a8109c99cfb2faa1f42ff8ac63c932bcf3780d645e5ed32c0b2ac446f80305b4465994c8f9430604968e176ae464fd80f632d1cb2c8f6007ff3'
'SKIP'
'SKIP'
'be2858613d9cca85d80e7b894e9d5fa7892cbddd7a677d2d2f68f419d75fdc1f6802de8014f43ce063b116afd4ff17369873a6adea2dd58ac6f94e617de66fec'
'9232342c0914575ce438c5a8ee7e1c25b0befb457a2934e9cb77d1fe9a103634ea403b57bc0ef0cd6cf72248aee5e5584282cea611bc79198aeac9a65d8df5d7')
'ca7d8666177d31b6c4924e9ab44ddf3d5b596b51da04d38da002830b03bd176d49354bbdd2a496617d57f44111ad59833296af87d03ffe3fca6b99327a7b4c3c'
'2f4dfcfa711b8bcbc5918ba635f5e430ef7132e66276261ade62bb1cba016967432c8dce7f84352cb8b07dc7c6b18f09177aa3eb92c8e358b2a106c8ca142fe9')
_common_flags=(
--with-compat
@ -59,6 +57,7 @@ _common_flags=(
--with-http_gunzip_module
--with-http_gzip_static_module
--with-http_mp4_module
--with-http_random_index_module
--with-http_realip_module
--with-http_secure_link_module
--with-http_slice_module
@ -106,8 +105,8 @@ build() {
--http-uwsgi-temp-path=/var/lib/nginx/uwsgi \
--with-cc-opt="$CFLAGS $CPPFLAGS" \
--with-ld-opt="$LDFLAGS" \
${_common_flags[@]} \
${_stable_flags[@]}
"${_common_flags[@]}" \
"${_stable_flags[@]}"
make
}
@ -118,6 +117,9 @@ check() {
}
package_nginx() {
pkgdesc='Lightweight HTTP server and IMAP/POP3 proxy server'
depends=(pcre2 zlib openssl geoip mailcap libxcrypt)
cd $pkgbase-$pkgver
make DESTDIR="$pkgdir" install
@ -139,13 +141,12 @@ package_nginx() {
mv "$pkgdir"/etc/nginx/html/ "$pkgdir"/usr/share/nginx
install -Dm644 ../logrotate "$pkgdir"/etc/logrotate.d/nginx
install -Dm644 ../service "$pkgdir"/usr/lib/systemd/system/nginx.service
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
install -Dm644 ../nginx.service "$pkgdir"/usr/lib/systemd/system/nginx.service
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgbase/LICENSE
rmdir "$pkgdir"/run
install -d "$pkgdir"/usr/share/man/man8/
gzip -9c man/nginx.8 > "$pkgdir"/usr/share/man/man8/nginx.8.gz
install -Dm0644 objs/nginx.8 "$pkgdir"/usr/share/man/man8/nginx.8
for i in ftdetect ftplugin indent syntax; do
install -Dm644 contrib/vim/$i/nginx.vim \
@ -155,7 +156,7 @@ package_nginx() {
package_nginx-src() {
pkgdesc="Source code of nginx $pkgver, useful for building modules"
depends=()
install -d "$pkgdir/usr/src"
cp -r $pkgbase-$pkgver-src "$pkgdir/usr/src/nginx"
}

View file

@ -1,7 +1,7 @@
/var/log/nginx/*log {
missingok
notifempty
create 640 http log
create 640 http root
sharedscripts
compress
postrotate

View file

@ -1,16 +1,21 @@
[Unit]
Description=A high performance web server and a reverse proxy server
After=network.target network-online.target nss-lookup.target
After=network-online.target remote-fs.target nss-lookup.target
Wants=network-online.target
[Service]
Type=forking
PIDFile=/run/nginx.pid
PrivateDevices=yes
PrivateTmp=true
SyslogLevel=err
ExecStart=/usr/bin/nginx -g 'pid /run/nginx.pid; error_log stderr;'
ExecStart=/usr/bin/nginx
ExecReload=/usr/bin/nginx -s reload
Restart=on-failure
KillMode=mixed
KillSignal=SIGQUIT
TimeoutStopSec=5
[Install]
WantedBy=multi-user.target