treeverse / lakeFS

lakeFS - Data version control for your data lake | Git for data
https://docs.lakefs.io
Apache License 2.0
4.46k stars 360 forks source link

Helm-installed lakeFS with ingress is not resolving bucket virtual hosting for S3 Gateway #3887

Closed charlie-innamed closed 2 years ago

charlie-innamed commented 2 years ago

Hello, I'm having some trouble getting virtual hosting for the S3 Gateway to work with my lakeFS installation through Helm. To test this, I have tried using AWS CLI as shown below.

The following seems to work correctly:

$ aws s3 --endpoint-url https://s3.my.path.net ls repo
                           PRE main/

However, when I set virtual hosting (or when I use a 3rd party's, AppSmith's, S3 integration with bucket virtual hosting), there is no response (however, exit code is 0 unless I specify a branch which returns 1):

$ aws configure set default.s3.addressing_style virtual
$ aws s3 --endpoint-url https://s3.my.path.net ls repo # exit code of 0, no response
$ aws s3 --endpoint-url https://s3.my.path.net ls repo/main/ # exit code of 1, no response

Supplemental debug log from the above exit code of 1: (redacted)

My Helm values is below:

lakefsConfig: |
  blockstore:
    type: s3
  gateways:
    s3:
      domain_name: s3.my.path.net
ingress:
  enabled: true
  ingressClassName: "nginx"
  tls:
  - hosts:
    - my.path.net
    - s3.my.path.net
    - "*.s3.my.path.net"
    secretName: <secret tls>
  hosts:
    - host: my.path.net
      paths: ["/"]
    - host: s3.my.path.net
      paths: ["/"]
    - host: "*.s3.my.path.net"
      paths: ["/"]

extraEnvVarsSecret: <secret env>

Thank you, @eden-ohana & @johnnyaug for your preliminary help! Any additional help on getting this re-configured or otherwise working for bucket virtual hosting would be much appreciated!

charlie-innamed commented 2 years ago

Resolved with a re-deployment of both lakeFS and associated PostgreSQL db. Will re-open if I can reproduce the issue. Thank you @Jonathan-Rosenberg @iddoavn, Amit.