haiwen / seafile-client

Seafile desktop client.
http://seafile.com
Apache License 2.0
471 stars 279 forks source link

Configurable ccnet location from applet #723

Closed kevinvalk closed 5 years ago

kevinvalk commented 9 years ago

I would like to sync my complete home folder up to my private cloud. However, this is not allowed due to the fact that ccnet folder (and or seafile-data) is inside my home folder. This holds for windows and linux. There are other issues with the same problem #42 #715.

The problem currently

[09/20/15 22:32:44]starting seaf-daemon:  ("-c", "C:/Users/Kevin/ccnet", "-d", "C:/ProgramData/seafile-data", "-w", "C:/ProgramData")
[09/20/15 22:32:44]The latest version is 4.3.4
[09/20/15 22:33:53]Failed to add download task:
 The path "C:/Users/Kevin" conflicts with system path
[09/20/15 22:34:33]The path "C:/Users/Kevin" conflicts with system path
[09/20/15 22:36:55]The path "C:/Users/Kevin/ccnet" conflicts with system path

To me it looks like they check those three paths (-c, -d, -w) to the given path. If the given path points to one of those a parent folder of those it is not allowed. I guess this is done to prevent syncing its own settings.

The most easy fix to implement, is to let us configure were our ccnet config folder is stored (the "-c" parameter for seaf-daemon and ccnet). Adding a path in the "advanced" settings of the seafile-applet would work like a charm (perhaps even let the applet move the folder when applying).

kevinvalk commented 9 years ago

Hahaha, only after writing this I remembered that this is an open source project. So without further ado, you can already set the ccnet path by changing the "CCNET_CONF_DIR" environment variable (cross platform). https://github.com/haiwen/seafile-client/blob/master/src/utils/utils.cpp#L101

However, I still think this is a good addition to the client to have this better configurable.

chuegel commented 9 years ago

Can confirm: it works. Thank you

MathiasRenner commented 8 years ago

Well, this fix is gone after installing an update of the client. Is there any chance that this will be fixed?

freeplant commented 8 years ago

As I just tried, it works with version 5.0.4. What I do:

Add a variable to current user’s variable list:

CCNET_CONF_DIR C:\ccnet

Restart seafile. Now I can sync the whole home folder.

partoneoftwo commented 7 years ago

I just hit this defect in the Seafile sync client on Windows. OS: Windows 10 Seafile client Sync Version: 6.1.0

Solution, as above: Add a variable to current user’s variable list:

CCNET_CONF_DIR C:\ccnet

Thanks a lot freeplant and friends.

egodigitus commented 1 year ago

Example for Linux

export CCNET_CONF_DIR=/opt/seafile/.ccnet

Put this line in your .profile and restart seafile