You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the problem
API Address only accepts either localhost or an IP address, which makes sense when we use this address to bind to when running the HTTP server. However, we use the same config value for HTTP clients (ie: defradb client .... command) meaning when clients can only access defra nodes by IPs and not by hostnames.
This is problematic for a number of reasons, but most notably so when trying to communicate between docker containers (one running the HTTP server, and the other running a client command), since docker sets up inter container networking via hostnames.
So trying to run docker run -v $PWD:/etc/defradb ghcr.io/sourcenetwork/defradb:0.9.0 client p2p info --url host.docker.internal:9181 it fails with Error: failed to validate config: cannot provide port with domain name.
To Reproduce client schema p2p info --url <hostname>:<port> where hostname isn't localhost or an IP Address
We either need to drop the URL validation for IP addresses, and just let the server error propagate when trying to "run" the server (which will fail if you cant bind to the specific hostname), or need to split client/server Address config value into two separate entries.
The text was updated successfully, but these errors were encountered:
Describe the problem
API Address only accepts either localhost or an IP address, which makes sense when we use this address to bind to when running the HTTP server. However, we use the same config value for HTTP clients (ie:
defradb client ....
command) meaning when clients can only access defra nodes by IPs and not by hostnames.This is problematic for a number of reasons, but most notably so when trying to communicate between docker containers (one running the HTTP server, and the other running a
client
command), since docker sets up inter container networking via hostnames.So trying to run
docker run -v $PWD:/etc/defradb ghcr.io/sourcenetwork/defradb:0.9.0 client p2p info --url host.docker.internal:9181
it fails withError: failed to validate config: cannot provide port with domain name
.To Reproduce
client schema p2p info --url <hostname>:<port>
where hostname isn't localhost or an IP AddressWe either need to drop the URL validation for IP addresses, and just let the server error propagate when trying to "run" the server (which will fail if you cant bind to the specific hostname), or need to split client/server Address config value into two separate entries.
The text was updated successfully, but these errors were encountered: