Build your Nextcloud Server using one shell script
The initial script (install-nextcloud.sh) will install your self hosted Nextcloud within few minutes fully automated. Your server will be built of:
- Fail2Ban (Nextcloud and SSH jails)
- Nextcloud 13.0.4
- NGINX 1.15. 1
- OpenSSL 1.1.0h
- PHP 7.2.7
- self signed or Let’s Encrypt SSL using the second script
- UFW (22, 80, 443)
The only precondition for the install-nextcloud.sh script is to utilize Ubuntu 18.04 LTS as your on-prem server OS. Optionally request your ssl certificate from Let’s Encrypt by issuing the second script called “ssl-certificate.sh”.
Ready to go? Let’s start:
(1) Build your self hosted Nextcloud server
If you are on Ubuntu 18.04 LTS:
sudo -s apt install git -y cd /usr/local/src git clone https://github.com/riegercloud/install-nextcloud.git cd install-nextcloud chmod +x install-nextcloud.sh ./install-nextcloud.sh
… be patient
Open your browser and call the shown URL from your shell
Nextcloud is already up, optimized and running!
(2) Optionally: Request your ssl certificate from Let’s Encrypt
Before you request your certificate ensure that your web-ports (80+443) are forwared to your server and your dyndns is properly configured to point to your server!
sudo -s cd /usr/local/src/install-nextcloud chmod +x ssl-certificate.sh ./ssl-certificate.sh
You only have to enter your DYNDNSNAME (YOUR.DEDYN.IO).
Then LetsEncrypt will ask you for
- your email adress
Enter email address (used for urgent renewal and security notices) (Enter 'c' to cancel):
- to agree to their Terms of Service
- if you are willing to share your email address with the Electronic Frontier Foundation
Y or N
Wait while your certificates are obtained.
If you receive this message:
Call: https://your.dedyn.io and enjoy your Nextcloud
your server is up and running using a verified certificate from Let’s Encrypt.
Enjoy your personal data in your secured and hardened Nextcloud.
Don’t forget to Backup your Nextcloud
Find more instructions here: Nextcloud Backup and Restore