I deleted the ~/.config/syncthing/key.pem and cert.pem so that a new device id is created (I need to be able to clone my device drive onto another device). However, when I run the web gui and restart syncthing, the same device id as before the deletion shows up in the “Show ID” page.
Just tested it and it works for me, so it doesn’t seem normal. But I would always stop syncthing before deleting the certificate files and then start it again.
Ok, I’ve checked and, as expected, the config is somewhere else. Since I start the service as root, the config is in /root/.config/syncthing/. Deleting the key.pem and cert.pem in this folder then restarting syncthing from the Web UI changes the Device ID.
Yeah I know it is a bad idea, but the process creating the files to sync has to be run as root. Thus, if syncthing is not root it can’t read/write them … (it is a device that uses WiringPi GPIOs)