File tree Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Expand file tree Collapse file tree 2 files changed +25
-3
lines changed Original file line number Diff line number Diff line change @@ -209,6 +209,13 @@ putting it in `/opt/docker/zulip/zulip/certs/` (by default, the
209
209
` zulip ` container startup script will generate a self-signed certificate and
210
210
install it in that directory).
211
211
212
+ ** Load balancer** . To tell Zulip it's behind a load balancer, you can set
213
+ ` LOADBALANCER_IPS ` to a comma-separated list of IPs. This will tell Zulip
214
+ to pass the real IP of the client instead of the IP of the load balancer itself
215
+ by [ setting the IPs] [ loadbalancer-ips ] under ` [loadbalancer] ` in ` zulip.conf ` .
216
+
217
+ [ loadbalancer-ips ] : https://zulip.readthedocs.io/en/latest/production/deployment.html#configuring-zulip-to-trust-proxies
218
+
212
219
### Manual configuration
213
220
214
221
The way the environment variables configuration process described in
Original file line number Diff line number Diff line change @@ -133,17 +133,32 @@ nginxConfiguration() {
133
133
}
134
134
additionalPuppetConfiguration () {
135
135
echo " Executing additional puppet configuration ..."
136
+
137
+ local changedPuppetConf=false
138
+
136
139
if [ " $QUEUE_WORKERS_MULTIPROCESS " == " True" ] || [ " $QUEUE_WORKERS_MULTIPROCESS " == " true" ]; then
137
140
echo " Setting queue workers to run in multiprocess mode ..."
138
141
crudini --set /etc/zulip/zulip.conf application_server queue_workers_multiprocess true
142
+ changedPuppetConf=true
139
143
elif [ " $QUEUE_WORKERS_MULTIPROCESS " == " False" ] || [ " $QUEUE_WORKERS_MULTIPROCESS " == " false" ]; then
140
144
echo " Setting queue workers to run in multithreaded mode ..."
141
145
crudini --set /etc/zulip/zulip.conf application_server queue_workers_multiprocess false
146
+ changedPuppetConf=true
142
147
else
143
- echo " No additional puppet configuration executed."
144
- return 0
148
+ echo " No additional puppet configuration executed for queue workers."
149
+ fi
150
+
151
+ if [ -n " $LOADBALANCER_IPS " ]; then
152
+ echo " Setting IPs for load balancer"
153
+ crudini --set /etc/zulip/zulip.conf loadbalancer ips " ${LOADBALANCER_IPS} "
154
+ changedPuppetConf=true
155
+ else
156
+ echo " No additional puppet configuration executed for load balancer IPs."
157
+ fi
158
+
159
+ if [ " $changedPuppetConf " = true ]; then
160
+ /home/zulip/deployments/current/scripts/zulip-puppet-apply -f
145
161
fi
146
- /home/zulip/deployments/current/scripts/zulip-puppet-apply -f
147
162
}
148
163
configureCerts () {
149
164
case " $SSL_CERTIFICATE_GENERATION " in
You can’t perform that action at this time.
0 commit comments