I have 76 monitors at one site and I screwed up the entires I needed to make in the ports.conf and virtual hosts file to configure multi-port so many times that I decided to write a script to automate the task.
The script will ask you what you would you like to use as the starting port number, how many monitors you have and if you are using HTTPS or not and generate the appropriate entries for you to copy and paste as well as where to put them on a ubuntu system.
The script can be found here:
https://github.com/IncompleteString/mul ... -generator
you run it like this:
Code: Select all
python multi_port_generator.py
Code: Select all
$ multi_port_generator.py
Enter your starting port number:3000
Enter your number of monitors:10
If you use HTTPS enter 1:1
Paste the following into your /etc/apache2/sites-available/000-default-le-ssl.conf OR default-ssl.conf at the line that begins with <VirtualHost *:443
*:3001 *:3002 *:3003 *:3004 *:3005 *:3006 *:3007 *:3008 *:3009 *:3010
Paste the following into your /etc/apache2/ports.conf file at the line starting with listen 443
Listen 3001 https
Listen 3002 https
Listen 3003 https
Listen 3004 https
Listen 3005 https
Listen 3006 https
Listen 3007 https
Listen 3008 https
Listen 3009 https
Listen 3010 https
and http mode:
Code: Select all
$ multi_port_generator.py
Enter your starting port number:30000
Enter your number of monitors:10
If you use HTTPS enter 1:2
Paste the following into your /etc/apache2/sites-available/000-default.conf at the line that begins with <VirtualHost *:80
*:30001 *:30002 *:30003 *:30004 *:30005 *:30006 *:30007 *:30008 *:30009 *:30010
Paste the following into your /etc/apache2/ports.conf file at the line starting with listen 80
Listen 30001
Listen 30002
Listen 30003
Listen 30004
Listen 30005
Listen 30006
Listen 30007
Listen 30008
Listen 30009
Listen 30010