aws s3 sync --delete
removed some new files.
For example:
There is a file in the bucket - S3://my-bucket/images/1.jpg
Then, I uploaded a file to the server: 2.jpg
There are 2 files in the server: 1.jpg
and 2.jpg
Start running the sync cronjob:
aws s3 sync s3://my-bucket/ ./ --delete
aws s3 sync ./ s3://my-bucket/ --delete
Why do we add --delete
- we want to delete the files in s3 and sync it to the server.
We will upload files to the server and remove the files in s3.
Is there any way to fix it?