Skip to content

A bash script that uses Amazons python package, awscli, to sync local files to Amazons S3.

Notifications You must be signed in to change notification settings

lakelandPBS/s3-sync

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 

Repository files navigation

This is a bash script that uses Amazon's python package, awscli, to sync local files to Amazons S3. WARNING!: This script will delete files from the S3 bucket if they don't exist on the local file system.

Once awscli is installed (e.g. pip install awscli) just run aws s3 configure which will request your credentials for the S3 bucket. Then choose a local directory to store files you want to sync with the S3 bucket. A suggested heirarchy is shown below. Keep in mind that all episodes will be renamed to their episode number followed by a file extension as shown below.

main_sync_directory
│
└───show-name
│   │   episode-001.mp4 (will be renamed to 001.mp4)
│   │   episode-001.scc (will be renamed to 001.scc)
│   
└───name-of-another-show
│   │   episode-1002.mp4 (will be renamed to 1002.mp4)
│   │   episode-1002.scc (will be renamed to 1002.scc)
│   │   episode-1003.mp4 (will be renamed to 1003.mp4)
│   │   episode-1003.scc (will be renamed to 1003.scc)
│   
└───yet-another-show
    │   episode-1201.mp4 (will be renamed to 1201.mp4)
    │   episode-1201.scc (will be renamed to 1201.scc)

Caution!!!

This script will delete files that do not exist on your local machine. This includes files that have been renamed. They will be deleted from the S3 bucket and re-uploaded with the new file name.

About

A bash script that uses Amazons python package, awscli, to sync local files to Amazons S3.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages