How do I make sure Spaces preserves existing metadata for updated files?

June 12, 2019 101 views
DigitalOcean CentOS

Updating assets of the same name and file path within DO-Spaces doesn’t preserve existing metadata settings. How do I ensure it preserves the existing metadata etc?
I am pushing assets to Spaces via s3cmd as recommended in this tutorial:

1 Answer

Unfortunately I don’t think that’s possible through s3cmd today. The best workaround I can this of would be to (a) get the metadata for an object, and then either (b) upload the new object to the same path with that saved metadata OR (b) upload the object first, and then modify / update the metadata of the object subsequently from the saved metadata.

Have another answer? Share your knowledge.