Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added s3-ec2role provider; fix #431 #433

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

BOPOHA
Copy link

@BOPOHA BOPOHA commented Nov 1, 2021

No description provided.

@@ -445,6 +445,14 @@ func New() *Cmd {
} else {
options = append(options, server.UseStorage(storage))
}
case "s3-ec2role": // using AWS IAM Role and EC2 Profile
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is not really needed.

you should rather add something like s3-credentials-type config param, default to access-key and refactor

func NewS3Storage(accessKey, secretKey, bucketName string, purgeDays int, region, endpoint string, disableMultipart bool, forcePathStyle bool, logger *log.Logger) (*S3Storage, error) {
and https://github.com/dutchcoders/transfer.sh/blob/main/server/utils.go#L43

Copy link
Collaborator

@aspacca aspacca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see my comment, thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants