Bladeren bron

Disables tcp harvester if bridge is installed on same machine.

master
damencho 5 jaren geleden
bovenliggende
commit
e01d891bba
1 gewijzigde bestanden met toevoegingen van 15 en 2 verwijderingen
  1. 15
    2
      debian/jitsi-meet-web-config.postinst

+ 15
- 2
debian/jitsi-meet-web-config.postinst Bestand weergeven

48
         if [ -n "$RET" ] && [ "$RET" = "true" ] ; then
48
         if [ -n "$RET" ] && [ "$RET" = "true" ] ; then
49
             JVB_SERVE="true"
49
             JVB_SERVE="true"
50
         fi
50
         fi
51
-        echo "------> $JVB_SERVE"
52
 
51
 
53
         # stores the hostname so we will reuse it later, like in purge
52
         # stores the hostname so we will reuse it later, like in purge
54
         db_set jitsi-meet/jvb-hostname $JVB_HOSTNAME
53
         db_set jitsi-meet/jvb-hostname $JVB_HOSTNAME
106
             sed -i "s/jitsi-meet.example.com/$JVB_HOSTNAME/g" $JITSI_MEET_CONFIG
105
             sed -i "s/jitsi-meet.example.com/$JVB_HOSTNAME/g" $JITSI_MEET_CONFIG
107
         fi
106
         fi
108
 
107
 
108
+        JVB_CONFIG="/etc/jitsi/videobridge/sip-communicator.properties"
109
+
109
         # this is new install let's configure jvb to serve meet
110
         # this is new install let's configure jvb to serve meet
110
         # no-nginx, no-apache installed on machine, this is new install or reconfiguring old one which have jvb_serve set
111
         # no-nginx, no-apache installed on machine, this is new install or reconfiguring old one which have jvb_serve set
111
         if [[ "$JVB_SERVE" = "true" ]] ; then
112
         if [[ "$JVB_SERVE" = "true" ]] ; then
113
             echo "------------------------------------------------"
114
             echo "------------------------------------------------"
114
             echo "You are using jetty to serve jitsi-meet, it is recommended to uninstall(purge) and use default installation that comes with nginx!"
115
             echo "You are using jetty to serve jitsi-meet, it is recommended to uninstall(purge) and use default installation that comes with nginx!"
115
             echo ""
116
             echo ""
116
-            echo "When using the following command any custom config will be LOST!!!"
117
+            echo "When using the following command, any custom config will be LOST, please backup /etc/jitsi !!!"
117
             echo ""
118
             echo ""
118
             echo "You can purge your installation using the following command:"
119
             echo "You can purge your installation using the following command:"
119
             echo "apt-get purge jitsi-meet jitsi-meet-web-config jitsi-meet-prosody jitsi-meet-web jicofo jitsi-videobridge"
120
             echo "apt-get purge jitsi-meet jitsi-meet-web-config jitsi-meet-prosody jitsi-meet-web jicofo jitsi-videobridge"
120
             echo "------------------------------------------------"
121
             echo "------------------------------------------------"
121
             echo ""
122
             echo ""
122
         elif [[ "$FORCE_NGINX" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
123
         elif [[ "$FORCE_NGINX" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
124
+            # disables tcp harvester to make sure jvb will not take port 443
125
+            if [[ -f $JVB_CONFIG ]] && ! grep -q "org.jitsi.videobridge.DISABLE_TCP_HARVESTER" "$JVB_CONFIG"  ;then
126
+                echo "org.jitsi.videobridge.DISABLE_TCP_HARVESTER=true" >> $JVB_CONFIG
127
+                invoke-rc.d jvb restart || true
128
+            fi
129
+
123
             # this is a reconfigure, lets just delete old links
130
             # this is a reconfigure, lets just delete old links
124
             if [ "$RECONFIGURING" = "true" ] ; then
131
             if [ "$RECONFIGURING" = "true" ] ; then
125
                 rm -f /etc/nginx/sites-enabled/$JVB_HOSTNAME_OLD.conf
132
                 rm -f /etc/nginx/sites-enabled/$JVB_HOSTNAME_OLD.conf
149
 
156
 
150
             invoke-rc.d nginx reload || true
157
             invoke-rc.d nginx reload || true
151
         elif [[ "$FORCE_APACHE" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
158
         elif [[ "$FORCE_APACHE" = "true" && ( -z "$JVB_HOSTNAME_OLD" || "$RECONFIGURING" = "true" ) ]] ; then
159
+            # disables tcp harvester to make sure jvb will not take port 443
160
+            if [[ -f $JVB_CONFIG ]] && ! grep -q "org.jitsi.videobridge.DISABLE_TCP_HARVESTER" "$JVB_CONFIG"  ;then
161
+                echo "org.jitsi.videobridge.DISABLE_TCP_HARVESTER=true" >> $JVB_CONFIG
162
+                invoke-rc.d jvb restart || true
163
+            fi
164
+
152
             # this is a reconfigure, lets just delete old links
165
             # this is a reconfigure, lets just delete old links
153
             if [ "$RECONFIGURING" = "true" ] ; then
166
             if [ "$RECONFIGURING" = "true" ] ; then
154
                 a2dissite $JVB_HOSTNAME_OLD.conf
167
                 a2dissite $JVB_HOSTNAME_OLD.conf

Laden…
Annuleren
Opslaan