What is gateways.s3.domain_name precisely used for...
# help
s
What is gateways.s3.domain_name precisely used for? (Please don't share the "Configuration Reference" link, we have reviewed it already.)
o
it is the dns name configured to serve S3 API requests for your lakeFS installation
since the s3 api uses subdomains to address buckets, lakefs needs to know which portion of the received
Host
header is the bucket name
s
can you please share some examples of this config?
o
if you put
<http://s3.example.com|s3.example.com>
as the domain name, you’d need to configure both
<http://s3.example.com|s3.example.com>
and
*.<http://s3.example.com|s3.example.com>
as DNS records, pointing at your lakefs instance or loaf balancer
s
thank you Oz. Sorry and sadly team is not able get their head around this. bcoz without using on LB/DNS also this worked.
o
it depends on the specific aws sdk or clients being used. some of them will specifiy the bucket name as a subdomain and some as a path prefix. only the former require this setting to work correctly. it is possible you’re using clients that only use the path prefix approach. to learn more, see this AWS doc: https://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html
s
For test..
changing config file gatewayss3domain_name: s3.local.lakefs.io:80 to gatewayss3domain_name: s3.us-east-1.amazonaws.com . lakefs stopped working
o
of course, as you are not using this address when making requests to lakefs
s
and we know the reason why it stopped working with s3.us-east1.amazonaws.com.. but we are failing to understand why remote users are able to connect to lakefs and work when config (gatewayss3domain_name: s3.local.lakefs.io:80)
o
s3.local.lakefs.io points to localhost. it’ll work with local clients. what did you use as the s3 endpoint url in your client’s configuration?
s
e s3 endpoint url = where?
o
how do clients connect to lakefs?
s
through browser http://102.45.32.12:80
n they get the lakefs console
o
so they are not using the s3 gateway at all. they are using the openapi endpoint. see https://docs.lakefs.io/architecture.html#overview
s
😞 yes that we know.
This is from one of the documention: aws s3 --profile lakefs \ --endpoint-url https://s3.lakefs.example.com \ ls s3://example-repo/master/example-directory
which endpoint-url shall we use in above gatewayss3domain_name: s3.local.lakefs.io:80 case?
o
http://s3.local.lakefs.io — but this will only work on the local machine running the lakefs instance. To work properly across a network you’d need to define the appropriate DNS records and set both the endpoint-url in the client AND the domain_name setting on the server to the same DNS name
s
DNS should point to what?
o
whatever is appropriate for your internal network. see this example: https://docs.lakefs.io/deploying/lb_dns.html#dns the records should point to the load balancer (if you’re using one) or to the ip of an instance running lakefs (102.45.32.12 in your example above)
s
lb is working .. but using above documentation dns isn't
o
please provide more detail: what did you do? what was the result? I want to help but you’re not providing any details to make that possible
s
Sure, I wrote on DM for u.
Shared the screenshots on DM and error logs and commands