[SOLVED] Getting folders_defaults. stuff working from a json config file


Tupsi

Recommended Posts

I am trying the achieve the following:

 

instead of fixing "Advanced Preferences" every here and then when my server does a resilio update and deletes all Advanced Preferences I want the info put into my config.json file which the server executes when starting the service.

Took me a while to figure out that you guys use different names inside Advanced Pref and the .json, but after finally getting around each "invalid key" complain and luckily other people here on the forum which happen to have stuff used in the past I managed to come up with this:

 

    "folder_defaults.use_relay" : false,
    "folder_defaults.use_tracker" : false,
    "folder_defaults.use_lan_broadcast" : false,
    "folder_defaults.known_hosts" : "mylist of hosts seperated by ,"

(interestingly enough the program complains about that folders_defaults.know_hosts MUST NOT BE of Array, although the samples for the individual shared folder examples say it must).

Anyway, neither of the above line works. Every NEW key I add comes up with the respective settings of true, true, true, empty (which is the normal behavior), so my conclusion would be that either "_defaults" do not do anything, or that I put them in the wrong context without managing the program to complain about it at startup.

 

So my question is, did anyone managed to set this up inside a .json file? Of so, any pointers would be much appreciated.

 

Edit: The initial statement from me is bs, the Adv Params are exactly named as the ones in the config file, only the sample config put me on the wrong track with the shared folder settings "search_lan" which seems to be "use_lan_broadcast" in the Prefs.

 

 

Edited by Tupsi
solved
Link to comment
Share on other sites

ok, fixed this. But instead of just deleting my whole post I though maybe letting it sit here will help others in the future.

 

Just out of desperation I just stopped my resilio service again, deleted ALL stuff from /var/lib/resilio-sync and started the service again. Guess what? After having to set the servername/identity new (which makes sense as I just deleted my logs, database config, history etc.) the stuff I put into my config.json is no present in Advanced Preferences and gets used with new shares!

Fair warning, you will lose all your shares of course that way, so you have to recreate them.

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.