Nicolas
Nicolas, I have tried twice more with no luck. Not sure what it is...
Here are the steps as I have cut and pasted them - the only change is the server name - would the proxy address need changing too?:
sudo -Es
mkdir -p /opt/kiwix/bin/ /opt/kiwix/data/
cd /opt/kiwix/bin/
wget -c https://download.kiwix.org/release/kiwix-tools/kiwix-tools_linux-armhf-3.1.2-5.tar.gz
tar -xzf kiwix-tools_linux-armhf-3.1.2-5.tar.gz --strip-components=1
cd /opt/kiwix/data/
wget -c http://download.kiwix.org/zim/storybox_en.zim
/opt/kiwix/bin/kiwix-manage /opt/kiwix/data/kiwixlib.xml \
add /opt/kiwix/data/storybox_en.zim
cat > /etc/nginx/sites-available/kiwix.conf <<EOF
server {
server_name kiwix.chatterbox.home;
location / {
proxy_pass http://127.0.0.1:8080;
proxy_set_header Host \$host;
proxy_set_header Port \$server_port;
proxy_set_header X-Forwarded-For \$proxy_add_x_forwarded_for;
proxy_set_header X-Real-Ip \$remote_addr;
proxy_redirect off;
}
}
EOF
ln -s /etc/nginx/sites-available/kiwix.conf /etc/nginx/sites-enabled/kiwix.conf
systemctl restart nginx.service
cat > /etc/systemd/system/kiwix.service <<EOF
[Unit]
Description=Kiwix web server.
After=network.target
[Service]
Type=forking
ExecStart=/opt/kiwix/bin/kiwix-serve --port 8080 --daemon --library /opt/kiwix/data/kiwixlib.xml
[Install]
WantedBy=multi-user.target
EOF
sudo systemctl enable kiwix.service
reboot
Seems like the indents did not copy across but the layout is the same as in your example above