I have quite a large number of devices that are running chirpstack alongside some software. At the moment the code is quite hacky using
internalServiceClient.login() to get a token an issue the requests to chirpstack over gRPC.
I’m trying to clean all of that up and use a persistent
api_key instead. Reading the doc/forum I can see that the only way to create an
api_key is through the admin interface (which is quite impractical in my case due to the large number of devices and the auto deployment using docker compose).
The idea would be to initialise all the chirpstack instances using a pre-defined api_key that the software can use. What i’ve tried so far is to add to
postgresql/initdb a new script to add a predefined api_key but at the time this script is executed chirpstack hasn’t yet created the tables. One way could be to create the table in the script before chirpstack does but that’s quite hacky…
Has anyone been handling a similar scenario? Any suggestions on how to go about this? Sorry if I missed something obvious.