2015-09-04 39 views
12

Come escludere più cartelle mentre si utilizza aws s3 syn?Escludere più cartelle utilizzando AWS S3 syn

ho provato:

# aws s3 sync s3://inksedge-app-file-storage-bucket-prod-env s3://inksedge-app-file-storage-bucket-test-env --exclude 'reportTemplate/* orders/* customers/*' 

Ma ancora si sta facendo di sincronizzazione per la cartella "cliente"

uscita:

copy: s3://inksedge-app-file-storage-bucket-prod-env/customers/116/miniimages/IMG_4800.jpg to s3://inksedge-app-file-storage-bucket-test-env/customers/116/miniimages/IMG_4800.jpg 
copy: s3://inksedge-app-file-storage-bucket-prod-env/customers/116/miniimages/DSC_0358.JPG to s3://inksedge-app-file-storage-bucket-test-env/customers/116/miniimages/DSC_0358.JPG 

risposta

20

Finalmente questo ha funzionato per me!

sudo aws s3 sync s3://xxxx-app-file-storage-bucket-prod-env s3://xxxx-app-file-storage-bucket-test-env --exclude 'customers/*' --exclude 'orders/*' --exclude 'reportTemplate/*' 

Suggerimento: in particolare si deve racchiudere i vostri caratteri jolly e caratteri speciali tra virgolette singole o doppie per funzionare correttamente, di seguito sono esempio di caratteri corrispondenti. per ulteriori informazioni sui comandi S3, controllarlo in amazon here.

*: Matches everything 
?: Matches any single character 
[sequence]: Matches any character in sequence 
[!sequence]: Matches any character not in sequence 
+0

Perché hai bisogno di sudo qui? – agathver

Problemi correlati