uwsgi is an alternative to using gunicorn + supervisord. It has native proxy support via the WSGI protocol in nginx.
# apt-get install uwsgi uwsgi-plugin-python3
Add a site to uwsgi in /etc/uwsgi/apps-available/netbox.ini
:
#!/bin/bash | |
CANAME=${CANAME:-rootCA} | |
CA2NAME=${CA2NAME:-intermediateCA} | |
NIFI_SERVER=${NIFI_SERVER:-nifi01} | |
DOMAIN=${DOMAIN:-localdomain} | |
IP_ADDRESS=${IP_ADDRESS:-127.0.0.1} | |
EMAIL="${EMAIL:-nifi@${NIFI_SERVER}.${DOMAIN}}" | |
EXT="SAN=IP:127.0.0.1,IP:${IP_ADDRESS},DNS:${NIFI_SERVER}.${DOMAIN},DNS:${NIFI_SERVER},DNS:localhost,EMAIL:${EMAIL}" | |
EXT2="KeyUsage=digitalSignature,keyEncipherment,nonRepudiation,dataEncipherment,keyAgreement,keyCertSign,cRLSign" |
function _do-gen-update() { | |
echo "Upgrading $2..." | |
case "$2" in | |
volt) volt self-upgrade -check ;; | |
zplugin) zplugin upgrade --all ;; | |
*) echo "Unknown application $2. Moving on..." ;; | |
esac | |
touch "$1" | |
} |
for i in /usr/local/{bin,sbin}/*; do otool -L $i; done | sed -e '/^.*is not an object file.*$/d' -e 's|^\(/.*\):$|@\1|' | awk 'BEGIN { RS="@" } !/ssl/ { next } !/^[[:space:]]*(\/.*ssl\.0.9.8.*\.dylib)/ { print $1 }' |