Closed tkluck closed 6 years ago
@kdehairy the CI failure seems related to #45 :
INFO [4890]: pac4cli: Starting proxy server on localhost:23129
INFO [4890]: pac4cli: resolving interface: localhost
INFO [4890]: pac4cli: localhost => 127.0.0.1
INFO [4890]: pac4cli: localhost => 127.0.0.1
INFO [4890]: pac4cli: localhost => 0000:0000:0000:0000:0000:0000:0000:0001
['127.0.0.1', '127.0.0.1', '0000:0000:0000:0000:0000:0000:0000:0001']
INFO [4890]: pac4cli: Binding to interface: '127.0.0.1'
INFO [4890]: pac4cli: Binding to interface: '127.0.0.1'
ERROR [4890]: pac4cli: Problem starting the server
<snip>
OSError: [Errno 98] Address already in use
Thoughts?
Weird!
This will happen if the localhost
is mapped to 127.0.0.1
multiple times in the /etc/hosts
(in this case twice). I also checked this and reproduced it on my local machine by editing my /etc/hosts
.
But anyways we should be resilient to this. I'll check for duplicates and remove them after resolving the domain name.
This is a few changes that seemed to make sense to me when I dug deeper into the startup process for #47 and #48. The changes are not needed to fix those issues but seem to make the process better overall.
Specifically:
READY=1
signal to systemd, but that was ignored because we didn't have the corresponding configuration inpac4cli.service
pac4cli.service
This pull request makes these improvements.