Skip to content

Commit a8d73cf

Browse files
authored
check if brotli is installed
1 parent 50adafa commit a8d73cf

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

lets-encrypt/activate-tls.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,12 @@ fi
104104
# To get the correct version for the Nginx conf file
105105
check_php
106106

107+
# Check Brotli support
108+
if is_this_installed libnginx-mod-brotli
109+
then
110+
BROTLI_ON="brotli on;"
111+
fi
112+
107113
# Generate wordpress_tls_domain.conf
108114
if [ ! -f "$tls_conf" ]
109115
then
@@ -121,7 +127,7 @@ server {
121127
listen 443 ssl;
122128
listen [::]:443 ssl;
123129
http2 on;
124-
brotli on;
130+
$BROTLI_ON
125131
126132
## Your website name goes here.
127133
server_name $TLSDOMAIN;

0 commit comments

Comments
 (0)