I followed this tutorial ([Tutorial] Nextcloud on WSL2 (Windows 10 20H2)) and i successfully install owncloud. My only problem is i canât access owncloud in other computer/gadgets. Iâm total newbie here i might need some spoonfeeding on what specific command should i input. Attached is my config.php settings. Iâm confused what ip to use since my pc ip is 192.168.1.27 and if i use ifconfig it is inet 172.20.216.103 . Thank you for your input.
$CONFIG = array (
âinstanceidâ => ââ,
âpasswordsaltâ => 'â,
âsecretâ => 'â,
âtrusted_domainsâ =>
array (
0 => â172.26.143.206â,
),
âdatadirectoryâ => â/var/www/nextcloud/dataâ,
âdbtypeâ => âmysqlâ,
âversionâ => â22.1.0.1â,
âoverwrite.cli.urlâ => âhttp://localhostâ,
âdbnameâ => ânextcloudâ,
âdbhostâ => âlocalhostâ,
âdbportâ => ââ,
âdbtableprefixâ => âoc_â,
âmysql.utf8mb4â => true,
âdbuserâ => '*â,
âdbpasswordâ => â****â,
âinstalledâ => true,
âapp_install_overwriteâ =>
array (
0 => âdropitâ,
1 => âfiles_external_ipfsâ,
),
);
Your other devices should be configured to connect to Nextcloud using your PCâs IP address. The â172.20âŚâ address is on a virtual network inside your PC, so the others donât know how to reach it. The PowerShell script in the tutorial should make your computer pass on the connections from the other devices through to Nextcloud on that address.
Just to be sure things are working right, how are you currently accessing Nextcloud on your PC?
Do you enter 127.0.0.1 (or localhost), or the 17.20.216.103 address? Does it also work if you enter your PCâs IP address (192.168.1.27) or your PCâs hostname instead?
If it doesnât work on the PCâs address or hostname, you can add those to Nextcloudâs list of ânames I might be called byâ by editing your nextcloud.conf, like so:
That way, Nextcloud wonât say âyou asked for 192.168.1.27, so how did you end up here!?â, and block any connections from other devices.
In the skript, do i need to change this:
$addr=â0.0.0.0â; into my ip address, $addr=â192.168.1.27â; ?
I am accessing it through localhost (http://localhost/index.php/login) and I cannot access it through other addresses. I tried this but still not working. Iâll try to work around these things mentioned.
âtrusted_domainsâ =>
array (
0 => â172.26.143.206â,
1 => â192.168.1.27â,
2 => âlocalhostâ,
),
I think thatâs the address it should get, but you shouldnât need to set it. â0.0.0.0â is shorthand for âlisten on all addressesâ, in this case.
The script is definitely whatâs wrong/missing here. Iâd recommend you find a way to tell whether itâs running properly - whether by copy/pasting it line-by-line into a PowerShell prompt, or by inspecting the traffic rules that are in place after it finishes running. If you canât be sure itâs working, you can look up documentation for the commands in use or ask the author of the tutorial.