0

I'm using cmd tool for AWS S3 called s3cmd. I'm trying 'get' set of folders filtered by front part of name directory name like '/192.168.*/'. Basically I have S3 bucket with a lot of directories and I just need couple of them that start with particular string. Here is what I have so far. Will be grateful for any kind of help :) Thank you!

s3cmd get --recursive --include '192.168*' s3://mys3bucket/logfiles/

Code above pulls down all the directories from /logfiles/. :(

Alan Moore
  • 73,866
  • 12
  • 100
  • 156
lukabix22
  • 85
  • 1
  • 1
  • 4

2 Answers2

0
s3cmd get --recursive s3://mys3bucket/logfiles/192.168
Bharat Jain
  • 654
  • 4
  • 6
0

If you want to "filter" for files that match a certain name, you can do this:

s3cmd get --recursive --exclude '*' --include 'filename*' s3://my-bucket/cheese
Azor Ahai -him-
  • 123
  • 1
  • 7
damianesteban
  • 1,603
  • 1
  • 19
  • 36