github.com/aavshr/aws-sdk-go@v1.41.3/example/aws/request/withContext/README.md (about) 1 # Example 2 3 Uploads a file to S3 given a bucket and object key. Also takes a duration 4 value to terminate the update if it doesn't complete within that time. 5 6 The AWS Region needs to be provided in the AWS shared config or on the 7 environment variable as `AWS_REGION`. Credentials also must be provided. 8 Will default to shared config file, but can load from environment if provided. 9 10 ## Usage: 11 12 # Upload myfile.txt to myBucket/myKey. Must complete within 10 minutes or will fail 13 go run -tags example withContext.go -b mybucket -k myKey -d 10m < myfile.txt