haiwen / seadroid

Android client for Seafile
Other
541 stars 278 forks source link

Upload only on specific ESSIDs #427

Closed CarlvO closed 6 months ago

CarlvO commented 9 years ago

I installed Seafile on a Raspberry and it's looking good. I just want something simple to sync pics and the occasional doc. Where I live bandwidth is an issue so I upload on WiFi only when I'm at home. It would be nice if the Android client allowed me to select one or more ESSIDs so that upload is only intended when my phone is connected to my home network.

forouher commented 9 years ago

So you want to Seadroid file upload to work:

That's a pretty specific restriction. I think it would be easier for you to just add an IP range filter on your Seafile server. So that it will only accept clients from within your home network.

e.g. for apache:

    <Location />
       deny from all
       Allow from 192.168.0.0/24 # <- put your home network here
    </Location>
CarlvO commented 9 years ago

IMO, it's something that should be configurable on the Android client. Considering that part of the Seafile user base will be people that setup a 'home cloud' I don't think it's too restrictive. Lots of people will want to be able to sync their phone's content (especially pictures) to their own cloud, but many people may have poor ADSL connections or may be worried about security implications of opening up ports on their routers. So being able to tell the Android client to 'only sync when connected to this SSID' sounds like a pretty reasonable solution.

if the Android client behaves decently and will just gracefully exit after trying an upload on a Wifi net without succes, and retry when connected to a different Wifi, that's also an option. But from a programming and performance point of view, I think it would be less optimized.

shoeper commented 9 years ago

I'd recommand to use foldersync (or similar apps) for such use cases.

forouher commented 9 years ago

if the Android client behaves decently and will just gracefully exit after trying an upload on a Wifi net without succes, and retry when connected to a different Wifi, that's also an option.

Retry on network state change events is not currently done and indeed a good idea.

However I would argue that the photo upload feature has bigger problems right now.(#375, #336, #330, #301).

CarlvO commented 9 years ago

@shoeper Mmm, I also want my wife to use this and I like the idea of a 'set it and forget it' app such as Seafile (well, I could use Dropbox but the point is exactly I prefer to have my own solution)

@forouher Thanks for considering. I agree there's some tender love and care to be given to pic upload. If it's any comfort, I tried Mega for a while and they suffer some of the same bugs: upload stalled, pics duplicated (even with different names rather than the (1) suffix) or pics not uploaded at all. That being said: a reliable personal cloud solution is what we all want, so enjoy the fixing....

shoeper commented 9 years ago

@shoeper Mmm, I also want my wife to use this and I like the idea of a 'set it and forget it' app such as Seafile (well, I could use Dropbox but the point is exactly I prefer to have my own solution)

that's exactly what FolderSync allows you to do. Enable WebDAV in Seafile, configure FolderSync (https://play.google.com/store/apps/details?id=dk.tacit.android.foldersync.full) once and it runs and runs. You have dozens of options (far more than Seafile will ever have).

CarlvO commented 9 years ago

OK, I'll check it out. Thanks for the heads-up.

forouher commented 9 years ago

@CarlvO I'm not a Seadroid developer, my thoughts are just my own. I agree with @shoeper, FolderSync might be worth checking out. I've used it in the past, e.g. to sync Titanium backups.