I have following directories structure in my S3 bucket, I want run multiple sync jobs in such a way that I could sync all folders that start with 1 in one job and those which start with 2 in another sync job.
I know I can sync using aws s3 sync s3://bucket my_local_dir for all individual sub-directories.
/Root
Thanks in Advance.
You can:
--exclude
to "Exclude all files or objects from the command that matches the specified pattern"`--include
to "Don't exclude files or objects in the command that match the specified pattern"This seems to work:
aws s3 sync s3://my-bucket/ local_dir --exclude "*" --include "1*"