#!/bin/bash -e mkdir -p /etc/3cxpbx cat > /etc/3cxpbx/setupconfig.xml << "" wget -O- http://downloads-global.3cx.com/downloads/3cxpbx/public.key | apt-key add - echo "deb http://downloads-global.3cx.com/downloads/debian stretch main" | tee /etc/apt/sources.list.d/3cxpbx.list apt-get update apt-get -y install nginx rm -f /etc/nginx/sites-enabled/default systemctl reload nginx apt-get -y install 3cxpbx