serokell / coffer

Multi-backend password store with multiple frontends
4 stars 2 forks source link

[#61] Fixed bug with second `vault` instance in `run-bats-tests.sh` #64

Closed DK318 closed 2 years ago

DK318 commented 2 years ago

Description

Problem

Sometimes the second vault instance doesn't start. Probably the problem is that the first vault instance starts on port 8209 and the second one starts on 8210.

Solution

Changed port of the second instance from 8210 to 8211.

Related issue(s)

dcastro commented 2 years ago

Why did port 8210 not work sometimes? :thinking:

DK318 commented 2 years ago

Maybe when we start vault on port 8209 it uses two ports actually.

If we start manually first instance on port 8201 and try to start the second one on 8202 then we would get next error

Error parsing listener configuration.
Error initializing listener of type tcp: listen tcp 127.0.0.1:8202: bind: address already in use
DK318 commented 2 years ago

Yeah, it really listens two neighbor ports. lsof prints me this:

vault     39914 39926 vault                dk318    8u     IPv4             625209       0t0        TCP localhost:8200 (LISTEN)
vault     39914 39926 vault                dk318    9u     IPv4             625212       0t0        TCP localhost:8201 (LISTEN)
MagicRB commented 2 years ago

didnt know vault did that but LGTM