diff --git a/.github/workflows/development.yml b/.github/workflows/development.yml index da13c088b..64d6a9629 100644 --- a/.github/workflows/development.yml +++ b/.github/workflows/development.yml @@ -298,7 +298,7 @@ jobs: MYSQL_USER: sftpgo MYSQL_PASSWORD: sftpgo options: >- - --health-cmd "mysqladmin status -h 127.0.0.1 -P 3306 -u root -p$MYSQL_ROOT_PASSWORD" + --health-cmd "mariadb-admin status -h 127.0.0.1 -P 3306 -u root -p$MYSQL_ROOT_PASSWORD" --health-interval 10s --health-timeout 5s --health-retries 6 diff --git a/internal/vfs/s3fs.go b/internal/vfs/s3fs.go index f6b58eeca..1f5d71518 100644 --- a/internal/vfs/s3fs.go +++ b/internal/vfs/s3fs.go @@ -115,19 +115,6 @@ func NewS3Fs(connectionID, localTempDir, mountPath string, s3Config S3FsConfig) awsConfig.Credentials = aws.NewCredentialsCache( credentials.NewStaticCredentialsProvider(fs.config.AccessKey, fs.config.AccessSecret.GetPayload(), "")) } - if fs.config.Endpoint != "" { - endpointResolver := aws.EndpointResolverWithOptionsFunc(func(service, region string, options ...any) (aws.Endpoint, error) { - return aws.Endpoint{ - URL: fs.config.Endpoint, - HostnameImmutable: fs.config.ForcePathStyle, - PartitionID: "aws", - SigningRegion: fs.config.Region, - Source: aws.EndpointSourceCustom, - }, nil - }) - awsConfig.EndpointResolverWithOptions = endpointResolver - } - fs.setConfigDefaults() if fs.config.RoleARN != "" { @@ -137,6 +124,9 @@ func NewS3Fs(connectionID, localTempDir, mountPath string, s3Config S3FsConfig) } fs.svc = s3.NewFromConfig(awsConfig, func(o *s3.Options) { o.UsePathStyle = fs.config.ForcePathStyle + if fs.config.Endpoint != "" { + o.BaseEndpoint = aws.String(fs.config.Endpoint) + } }) return fs, nil }