Skip to content

[Bug] Garage S3 doesn't work behind a reverse proxy #34

@Arlind-dev

Description

@Arlind-dev

Describe the bug

When using garage with

this config

storage-type: "themeinerlp:s3"
compression: gzip
bucket-name: "bluemap"
region: "garage"
access-key-id: "REDACTED"
secret-access-key: "REDACTED"
endpoint-url: "http://garage:3900"
root-path: "srv1"
force-path-style: true

it works, but using it like this:

storage-type: "themeinerlp:s3"
compression: gzip
bucket-name: "bluemap"
region: "garage"
access-key-id: "REDACTED"
secret-access-key: "REDACTED"
endpoint-url: "https://s3.local.domain.tld"
root-path: "srv1"
force-path-style: true

It does not, the error will look like this:

Caused by: software.amazon.awssdk.services.s3.model.S3Exception
(Service: S3, Status Code: 400, Request ID: null)
(SDK Attempt Count: 1)

    at software.amazon.awssdk.services.s3.model.S3Exception$BuilderImpl
        .build(S3Exception.java:113)
    at software.amazon.awssdk.services.s3.model.S3Exception$BuilderImpl
        .build(S3Exception.java:61)
    at software.amazon.awssdk.core.internal.http.pipeline.stages.utils
        .RetryableStageHelper.retryPolicyDisallowedRetryException(
            RetryableStageHelper.java:168
        )
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .AsyncRetryableStage$RetryingExecutor
        .maybeAttemptExecute(AsyncRetryableStage.java:139)
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .AsyncRetryableStage$RetryingExecutor
        .maybeRetryExecute(AsyncRetryableStage.java:157)
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .AsyncRetryableStage$RetryingExecutor
        .lambda$attemptExecute$1(AsyncRetryableStage.java:127)
    at java.util.concurrent.CompletableFuture
        .uniWhenComplete(CompletableFuture.java:863)
    at java.util.concurrent.CompletableFuture$UniWhenComplete
        .tryFire(CompletableFuture.java:841)
    at java.util.concurrent.CompletableFuture
        .postComplete(CompletableFuture.java:510)
    at java.util.concurrent.CompletableFuture
        .complete(CompletableFuture.java:2179)
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .MakeAsyncHttpRequestStage
        .lambda$execute$0(MakeAsyncHttpRequestStage.java:110)
    at java.util.concurrent.CompletableFuture
        .uniWhenComplete(CompletableFuture.java:863)
    at java.util.concurrent.CompletableFuture$UniWhenComplete
        .tryFire(CompletableFuture.java:841)
    at java.util.concurrent.CompletableFuture
        .postComplete(CompletableFuture.java:510)
    at java.util.concurrent.CompletableFuture
        .complete(CompletableFuture.java:2179)
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .MakeAsyncHttpRequestStage
        .completeResponseFuture(MakeAsyncHttpRequestStage.java:253)
    at software.amazon.awssdk.core.internal.http.pipeline.stages
        .MakeAsyncHttpRequestStage
        .lambda$executeHttpRequest$3(MakeAsyncHttpRequestStage.java:167)
    at java.util.concurrent.CompletableFuture
        .uniHandle(CompletableFuture.java:934)
    at java.util.concurrent.CompletableFuture$UniHandle
        .tryFire(CompletableFuture.java:911)
    at java.util.concurrent.CompletableFuture$Completion
        .run(CompletableFuture.java:482)
    at java.util.concurrent.ThreadPoolExecutor
        .runWorker(ThreadPoolExecutor.java:1144)
    at java.util.concurrent.ThreadPoolExecutor$Worker
        .run(ThreadPoolExecutor.java:642)
    ... 1 more

Steps to reproduce the bug

See above

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions