Approve incoming Device ID from command line

For a headless VM, how to use command line to approve:

[FDJJY] 04:57:12 INFO: Connection from 33.55.222.111:33333 with unknown device ID YW2KWA2-...

Thanks.

The GUI “approves” this by crafting a configuration that includes the device and posting that to the backend. That requires some logic on the outside, so it’s not trivial to do from a shell script or so unfortunately.

Why it is not possible to make this call available from command line as syncthing add [DEVICEID]? It looks like the “Add” action is the only thing that is needed from user.

Oh, it’s possible, it’s just not implemented. You are the first to ask for it.

You can use syncthing-cli for that.

3 Likes

Let’s hope I’m not necro-bumping here, but is this still the way to go for headless node set-up?

I have to setup a distant machine powered with Ubuntu 14.04. Added ‘http://apt.syncthing.net/’ and installed Syncthing. syncthing-inotify is also available and that’s it AFAIK.

Is syncthing-cli available for Ubuntu Trusty?

I would suggest for headless VMs to connect via SSH and access the GUI through port forwarding (SSH tunnel).

http://blog.trackets.com/2014/05/17/ssh-tunnel-local-and-remote-port-forwarding-explained-with-examples.html

Thankss Intdel.

X11 forwarding the gui will do it thiss time as this is a remote desktop.

I find it hard (but possible) this very remarquable piece of software is so much CLI unfriendly. Will go back to the Documentation and check again.

EDIT: virtual keyboard sh*$^… joy!

Ok, thannk you for syncthing-cli Canton7

You can download syncthing-cli from here: http://build.syncthing.net/job/syncthing-cli/

I don’t believe it’s received much TLC since 0.12 came out so I’m not sure how well it works these days.

It’s all just a config file in the end. Just add a line or two for the device and restart.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.