nextcloud / nextcloud/ios

Feature Request: Automatic URL switching inside the IOS or Android app depending on network connectivity.

Open
#3,312 6 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Swift
Stars
2.5k
Forks
1k
Avg merge
2d 18h
Merged PRs (30d)
13

Description

Feature request

Is your feature request related to a problem? Please describe.

I have installed locally Nextcloud in my home network. (I have homeassistant installed on a N100 and nextcloud is installed as a addon. This does not change anything. It behaves as other normal installations.) To reach the instance from inside, I have issues a local certificate, and I use HTTPS. When I connect from the outside of my home network, I use the cloudflare addon, docker. Everything works fine from all devices. example: internal network address --> https://mysmarthomen.fritz.box:8099 and for external network I use --> https://nextcloud.mysmarthome.uk.
Important info: The Cloudflare docker with tunnels only start when I am not at home, thus when I am not connected to my home network. So when I am at home, cloudflare docker is stopped and external URL is unavailable. (This is an added measure to minimize possible external attacks)
Using local DNS to rederect me in my home network to my server when I use external URL will not HELP!!! Both URL have different SSL certificates. If I do that, I will then have SSL certificate error.

Describe the solution you'd like

I really like the solution homeassistant or Immich IOS app have implemented and would really appreciate if that could be added to nextcloud and nextcloud Talk apps. I don't know the details behind the solution but as per my understanding the app check if you are connected to your home network or other wifi networks or your mobile data. You define in the app your home network name.

  1. If you connect from your home WIFI network, use internal url, could be a IP address or a local DNS record example --> https://mysmarthomen.fritz.box:8099
  2. if app cheks and realizes you are connected with other WIFI network or mobile network then uses automatically external URL, in our case https://nextcloud.mysmarthome.uk.

Image

Describe alternatives you've considered
Currently I have created 2 login accounts in my IOS app with different URL, so when I am at home I switch to my account with internal URL. (External URL is down as Cloudflare is stopped.) When I am outside my home network I switch in my app to my account that uses external public network. The issue is I have always to remember to do it. My main issue is actually with Nextcloud TALK app as I don receive any message if I don't switch the account in the app.

Using always the external address or URL in theory and keeping cloudflare up and running should solve my issue, but it is counterproductive when coping large files to my phone or off my phone. Also I don't like the idea to have cloudflare always running and my apps always exposed to public when not necessary.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing how the iOS app stores and selects account URLs, then examine the requested network conditions: home Wi-Fi versus other Wi-Fi or mobile data. Done should include configurable internal and external URLs with automatic switching, including reliable Nextcloud Talk message delivery; the payload names no files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.