Skip to content

Instantly share code, notes, and snippets.

@tavinus
Last active February 25, 2024 02:54
Show Gist options
  • Save tavinus/64b89730e8deb5253e66cce3b5a6b21f to your computer and use it in GitHub Desktop.
Save tavinus/64b89730e8deb5253e66cce3b5a6b21f to your computer and use it in GitHub Desktop.
Install OnlyOffice 7.2.4 on Debian 11 Bullseye
#!/bin/bash
##########################################################################
# Tavinus Nov 2022
#
# https://gist.github.com/tavinus/64b89730e8deb5253e66cce3b5a6b21f
# This is a work in progress, use at your own risk
#
# The POSTGRES password is 'onlyoffice' and
# it will be asked during install
##########################################################################
if [ "$EUID" -ne 0 ]
then echo "Please run as root"
exit
fi
# initial setup
apt update
apt upgrade -y
apt install -y sudo nano htop gnupg2
# postgresql
apt install -y postgresql
sudo -i -u postgres psql -c "CREATE DATABASE onlyoffice;"
sudo -i -u postgres psql -c "CREATE USER onlyoffice WITH password 'onlyoffice';"
sudo -i -u postgres psql -c "GRANT ALL privileges ON DATABASE onlyoffice TO onlyoffice;"
# rabbitmq
apt install -y rabbitmq-server
# nginx
apt install -y nginx-extras
# add gpg key
mkdir -p ~/.gnupg
chmod 700 ~/.gnupg
gpg --no-default-keyring --keyring gnupg-ring:/tmp/onlyoffice.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys CB2DE8E5
chmod 644 /tmp/onlyoffice.gpg
chown root:root /tmp/onlyoffice.gpg
mv /tmp/onlyoffice.gpg /etc/apt/trusted.gpg.d/
# add repo
echo "deb https://download.onlyoffice.com/repo/debian squeeze main" | tee /etc/apt/sources.list.d/onlyoffice.list
apt update
# add ms fonts
apt install -y ttf-mscorefonts-installer
# install only office
apt install -y onlyoffice-documentserver
# Show JWT info
documentserver-jwt-status.sh
echo
echo "ALL DONE"
exit 0
@tavinus
Copy link
Author

tavinus commented Nov 8, 2022

Troubleshooting

I was getting a weird error in Nextcloud when choosing fonts. Scrolling to the end would show 3 "empty" fonts and totally break the interface, even making the file not editable and displaying an error message. I noticed that this was not happening in the ds:example app, so I cleared my firefox cache and reloaded the Nextcloud page and document and all was fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment