[Unit] Description=__APP__ Videobridge After=network.target [Service] SuccessExitStatus=143 # allow bind to 80 and 443 AmbientCapabilities=CAP_NET_BIND_SERVICE EnvironmentFile=/etc/__APP__/videobridge/config Environment=LOGFILE=/var/log/__APP__/jitsi-videobridge.log User=__APP__ RuntimeDirectory=jitsi-videobridge RuntimeDirectoryMode=0750 PIDFile=/var/run/jitsi-videobridge/jitsi-videobridge.pid # more threads for this process TasksMax=65000 # allow more open files for this process LimitNPROC=65000 LimitNOFILE=65000 WorkingDirectory=__INSTALL_DIR__/jitsi-videobridge/ ExecStart=/bin/bash -c "exec __INSTALL_DIR__/jitsi-videobridge/jvb.sh --host=${JVB_HOST} --domain=${JVB_HOSTNAME} --port=${JVB_PORT} --secret=${JVB_SECRET} ${JVB_OPTS} < /dev/null >> ${LOGFILE} 2>&1" ExecStartPost=/bin/bash -c "echo $MAINPID > /var/run/jitsi-videobridge/jitsi-videobridge.pid" [Install] WantedBy=multi-user.target