Is your feature request related to a problem? Please describe.
According to official BBB docs, it mentions BBB needs Elastic or Static IP before installation, but what if someone wants to use Dynamic IPs? (Cost effective in some cases)
One of the main problem is, having an option to change IP using any command. I built an AMI image from BBB ec2 instance and then tried to launch BBB from that Image but it wasn't working, after checking that new instance i figured that bbb is installed because of AMI but its having IP of previous EC2 instance, because of which new instance not works and it shows 404 error.
I also changed domain for new instance using bbb-conf --setip xxx.abc.com but still 404 error and Freeswitch was also having IP of previous instance.
Describe the solution you'd like
Describe alternatives you've considered
Tried changing IP address manually, but still it wasn't working.
Additional context
We just want to have an easy deployment process, like cloning instances and doing nothing else or maybe just update subdomain like bbb-conf --setip new.bbbdemo.com
I also use dynamic IP address, and use the following script to change all the settings.
First check your settings by sudo bbb-conf --check
If you find any conflicts, you can use all or part of the following scripts.
Check what is in your respective configuration files before applying the scripts, or it will mess everything up.
Since my server is behind NAT, there are 2 variables $EXTERNAL_IP and $LOCAL_IP
Please refer to https://docs.bigbluebutton.org/2.2/configure-firewall.html for what each line means.
After everything is done, restart bbb and nginx or simply reboot your server.
EXTERNAL_IP = "your global IP address"
LOCAL_IP = "your local IP address if behind NAT otherwise same as EXTERNAL_IP"
DOMAIN_NAME = "your server host name (e.g. bbb.example.com)"
sed -i "s/proxy_pass http.*/proxy_pass https:\/\/$EXTERNAL_IP:7443;/g" /etc/bigbluebutton/nginx/sip.nginx
sed -i "s/\( *ip:\).*/\1 $EXTERNAL_IP/g" /usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
sed -i "s/\( *sip_ip:\).*/\1 $LOCAL_IP/g" /usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
sed -i "s/\(localIpAddress:\).*/\1 $LOCAL_IP/g" /usr/local/bigbluebutton/bbb-webrtc-sfu/config/default.yml
sed -i "s/\(name=\"wss-binding\"\).*/\1 value=\"$EXTERNAL_IP:7443\"\/>/g" /opt/freeswitch/etc/freeswitch/sip_profiles/external.xml
sed -i "s/\"external_rtp_ip=.*\"/\"external_rtp_ip=$EXTERNAL_IP\"/g" /opt/freeswitch/etc/freeswitch/vars.xml
sed -i "s/\"external_sip_ip=.*\"/\"external_sip_ip=$EXTERNAL_IP\"/g" /opt/freeswitch/etc/freeswitch/vars.xml
sed -i "s/\"local_ip_v4=.*\"/\"local_ip_v4=$LOCAL_IP\"/g" /opt/freeswitch/etc/freeswitch/vars.xml
sed -i "s/^ExecStart.*/ExecStart=\/sbin\/ip addr add $EXTERNAL_IP dev lo/g" /lib/systemd/system/dummy-nic.service; #if behind NAT
sed -i "s/.*$DOMAIN_NAME/$EXTERNAL_IP $DOMAIN_NAME/g" /etc/hosts #if behind NAT
You tried cloning your instance? Everything works for you after cloning and running this script in cloned instance?
If the IP address is changed and server name (e.g. bbb.example.com) remains unchanged, it should work.
I thought that was your first question.
And your second question, if you simply clone a working instance and run the above script, I expect it not to work, since I think each clone needs a different server name.
If you change the server name, you need a new SSL certificate, and change the settings regarding domain name that you find in sudo bbb-conf --check as well.
There might be a bunch of other things to do, so it think it more simple to initially run bbb-install for each fresh instance rather than cloning one.
You tried cloning your instance? Everything works for you after cloning and running this script in cloned instance?
Most helpful comment
I also use dynamic IP address, and use the following script to change all the settings.
First check your settings by
sudo bbb-conf --checkIf you find any conflicts, you can use all or part of the following scripts.
Check what is in your respective configuration files before applying the scripts, or it will mess everything up.
Since my server is behind NAT, there are 2 variables
$EXTERNAL_IPand$LOCAL_IPPlease refer to https://docs.bigbluebutton.org/2.2/configure-firewall.html for what each line means.
After everything is done, restart bbb and nginx or simply reboot your server.