I am writing a test app. For this, it would be ideal if my libp2p nodes would keep their IDs across restarts - otherwise I need to think of some intermediate service which keeps track of NodeIDs for the nodes to connect during a test.
Can I do this?
Currently, if I just run the https://docs.libp2p.io/guides/getting-started/go/ tutorial, after each restart, it prints a different Node ID.
❯ go run ./main.go
Listen addresses: /ip4/127.0.0.1/tcp/9436/p2p/12D3KooWNK774CCm9b48H84qZu3mp2Jq4wvDBh9813omB712qqLW
^CReceived signal, shutting down...
❯ go run ./main.go
Listen addresses: /ip4/127.0.0.1/tcp/9436/p2p/12D3KooWGLgDLUaNiuruX5umaExyFQJQBsf3yyXgC9MPy7cGS99F
^CReceived signal, shutting down...