help.nextcloud.com is for home/non-enterprise users. If youâre running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.
In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:
example
Or for longer, use three backticks above and below the code snippet:
longer
example
here
Some or all of the below information will be requested if it isnât supplied; for fastest response please provide as much as you can
Nextcloud version (eg, 20.0.5): 22.1.1
Operating system and version (eg, Ubuntu 20.04): 20.04 LTS
Apache or nginx version (eg, Apache 2.4.25): Apache 2.4.25
PHP version (eg, 7.4): 7.4
default.conf is, as the name suggests, the default VirtualHost, which in most distributions points to /var/www/html and serves the Apache default page. When you install Nextcloud or any other service, you can either modify the default.conf to your needs or you can create a new VirtualHost respective a new.conf file, enable it with a2ensite new.conf and use that to serve the respective service. If you donât use the default.conf, you can disable it with a2dissite default.conf.
About the question when you need a reverse proxy and when you do not:
If Nextcloud is already running on this server, you donât need to change anything, you can just create additional VirtualHosts by adding more.conf files for the additional services and enable them with a2ensite name.conf. They can contain a reverse proxy configuration, if they for example point to another server or to a Docker container that already has itâs own web server running. Or they can contain a ânormalâ configuration if they point to services (most likley running on the same server) without their own web server. You can of course also install Apache on a third server, which then acts as a reverse proxy for all of your services and servers.
Thank you for taking the time to explain, now I have a better understanding.
From what Iâve read hear if I wanted to change default port 80/443 that Nextcloud is listening I would need to change that on Apache. Thereâs no way to have Apache stay on 80/443 and Nextcloud on ie. 8080/4434?
So far, I was able to make Reverse Proxy for Syntcthing which forwards to 8384. That is just an example, but Iâm thinking down the road that I will have more services that want to run on 80/443 and there be a conflict.
To be able to run multiple Web Services / VirtualHosts on one public IP address and / or on a single server, it is best to register a domain name. You can then use different subdomains for each service like nextcloud.yourdomain.com, syncthing.yourdomain.com, otherservice.yourdomain.com etc. and define them with the ServerName directive in the respective .conf file.
Examples:
VirtualHost for Nextcloud:
<VirtualHost *:443>
DocumentRoot "var/www/nextcloud"
ServerName nextcloud.yourdomain.com
# Other directives here
</VirtualHost>
VirtualHost for Synchthing:
<VirtualHost *:443>
ServerName syncthing.yourdomain.com
ProxyPass /syncthing/ http://localhost:8384/
<Location /syncthing/>
ProxyPassReverse http://localhost:8384/
Require all granted
</Location>
# Other directives here
</VirtualHost>