Add openresty convenience wrapper

This commit is contained in:
Talia 2025-06-05 13:10:56 +02:00
parent 3c8df651d1
commit 464cb38916
Signed by: darkwiiplayer
GPG key ID: 7808674088232B3E

17
bin/resty-here Executable file
View file

@ -0,0 +1,17 @@
#!/bin/sh
if [ -f "openresty.conf" ]
then config="openresty.conf"
else
if [ -f "nginx.conf" ]
then config="nginx.conf"
else
config="openresty.conf"
cp /usr/local/openresty/example.conf $config
$EDITOR $config
fi
fi
mkdir -p logs
exec nginx -p $(pwd) -c $config -g "daemon off;" "$@"