Setting up and ssl with Nextcloud on a virtual machine

Hi, I know there a lots of posts describing how to have external access to nextcloud. However, I feel that my problem is unique. I have gotten a custom domain name. I forwarded it my ip address of the virtual machine and I have set the port forwarding on my router to 443. However, when I try configure my ssl settings the script doesnt see the domain name. I check my ports for the ip adress and it says they are closed. I am not sure what ip address I should be using external or the ip address from the vm? Heres a link with the setup procedure for reference. Link:


One more reference link for help:

I have mine set up with a domain name. For the DNS servers you will use your externl IP. As for opening the ports for access on the virtual machine you will open the ports using the internal IP of the virtual machineā€¦ the inet addr.

also the port checker like canyouseeme will only see the port if something is actively using it.

Ok, it worked thankyou! The last problem Iā€™m having is locating the trusted domain file. Iā€™m running Ubuntu 16.0.4 with Apache and PHP7. I m just having trouble try to get rid of the country figure trusted domain message.

Get Outlook for Android

are you talking about the config.php. nano /var/www/nextcloud/config/config.php

in there, there is a trusted domains section.

I have mine set as:
ā€˜trusted_domainsā€™ =>
array (
0 => ā€˜site.comā€™,
1 => ā€˜site.netā€™,
2 => ā€˜www.site.comā€™,
3 => ā€˜www.site.netā€™,

and you have to be root to access it ā€¦ I use sudo su and then find the file and edit it

Thank you so much! Now I have it running! Thank you so much! Now I am just testing the cloud. Would you recommned running the cloud on a vm?

well ā€¦ I`d say it depends on what you are going to do with it ā€¦a nextcloud for company usage ā€¦probably not a good idea. I have mine running on virtual box right nowā€¦ just because I am not formatting my desktop tower to run ubuntu. Eventually I will get a setup just for this.

But I am only using this for my personal picture backup and sharing it with family and they have some space to use on there as well ā€¦ so for something small like that I think it runs fine.

I have also on my virtual box set it up with 4gb and 2 processors each at 2.4GHz.

so it just depends on what you are going to use it forā€¦ also hardware on the computer will also determine how it runs on the virtualbox. Higher end hardware will run better than lower end of course. Also your connection speed as well.

hello , Iā€™m having problems to publish my nextcloud online. May you explain better what do you mean with ā€œFor the DNS servers you will use your externl IPā€. ??

My situation summary:

Iā€™m trying to use Proxmox with a VM nextcloud downloaded from Techandme. I tried to create a dmz too in my router who is 192.168.1.1 as internal IP. As external IP I have freedns.org services who are giving me 5 subdomains free to use, and freedns change my dynamin router IP when itā€™s necessary. I bought a cheap domain too with the idea to use it with nextcloud, but I donā€™t know how to use it cause if I point it to my external IP then my external IP will changeā€¦

My problem is always that when I test my router for ports 80 & 443 ,they are closed, even if I forwarded them in my router.

My proxmox main ā€œnetworkā€ is configured with a network address(one from a dmz or one from my usual home network) , netmask, and gateway(192.168.1.1). Then Proxmox has a dns server who is setted as my internal router IP (192.168.1.1)
When I create a VM on proxmox , my VM network hardware option is a Bridge(as a default), ( NAT is an option) .

Proxmox has a general option FIREWALL that is disabled by dfault.
Inside each VM I have an option ā€œFIREWALLā€ that I can enable, and I have an option ā€œDHCPā€ that I can enable too. Anyway in any VM I created dhcp is already working so I never enabled anything.

reading in Proxmoxā€™s help I have read :

Security Groups
A security group is a collection of rules, defined at cluster level, which can be used in all VMsā€™ rules. For example you can define a group named ā€œwebserverā€ with rules to open the http and https ports.

/etc/pve/firewall/cluster.fw

[group webserver]
IN ACCEPT -p tcp -dport 80
IN ACCEPT -p tcp -dport 443
Then, you can add this group to a VMā€™s firewall

/etc/pve/firewall/.fw

[RULES]
GROUP webserver

Does it mean as to you that I have to enable the main firewall of Proxmox and the option ā€œFIREWALLā€ in each VM and open ports there too ?? I hope itā€™s not so complicated sincerely.

finish of the summary

my question is always:
May you explain better what do you mean with ā€œFor the DNS servers you will use your externl IPā€ ?? in the post :slightly_smiling_face:

rmarkjrDec '16
I have mine set up with a domain name. For the DNS servers you will use your externl IP. As for opening the ports for access on the virtual machine you will open the ports using the internal IP of the virtual machineā€¦ the inet addr.

also the port checker like canyouseeme will only see the port if something is actively using it.

thanks in advance