aws-s3

aws-s3
reads and writes from/to
Simple Storage Service.
Installation
go install github.com/TV4/aws-tools/cmd/aws-s3@latest
Usage
aws-s3 [-access-key-id=<...> -secret-access-key=<...>] -region=<...> -bucket=<...> <command>
-access-key-id string
AWS access key ID (ACCESS_KEY_ID)
-bucket string
bucket name (BUCKET)
-region string
AWS region (REGION)
-secret-access-key string
AWS secret access key (SECRET_ACCESS_KEY)
Each flag has a corresponding environment variable which will be read if set.
If both environment variable and flag have been set, the flag overrides the
environment variable.
Commands:
ls [<prefix>] Lists bucket objects, optionally filtered by the given prefix
download <object> [<object>...] Downloads given object(s) from the bucket
upload <file> [<file>...] Uploads given file(s) to the bucket
read <object> Reads a bucket object to stdout
write <object> Writes a bucket object from stdin
rm <object> [<object>...] Deletes the given object(s) from the bucket
version Shows version info
AWS Access Keys:
https://docs.aws.amazon.com/general/latest/gr/aws-sec-cred-types.html#access-keys-and-secret-access-keys
License
Copyright (c) 2022 Telia
Copyright (c) 2020-2022 TV4
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.