Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • List objects in a bucket
    If there are any files at the bucket level, then this command will return the list of files. If there are only folders/prefixes under the bucket, then it will return the top level folder/prefix names of that bucket. Keep in mind, if you try to list objects that you do not have access to, you will get an access denied error.
    aws s3 ls s3://<bucketName>

  • List objects under a folder/prefix
    This command will list all the objects/files under that folder or prefix.
    aws s3 ls s3://<bucketName>/<prefix>/

  • Copy a local file to S3
    This command will copy a local file (test.txt) from your workstation over to an S3 bucket:
    aws s3 cp test.txt s3://<bucketName>/test.txt

  • Copy an S3 object to a local file
    The below command copies an S3 object to your workstation.
    aws s3 cp s3://<bucketName>/test.txt test.txt

Notification Service

Coming soonPlease see the documentation and example code on SDC’s GitLab: https://gitlab.prod.sdc.dot.gov/Commons/notification-service