Report this

What is the reason for this report?

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

Posted on June 12, 2019

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: https://www.digitalocean.com/community/tutorials/how-to-speed-up-wordpress-asset-delivery-using-digitalocean-spaces-cdn#offloading-additional-assets-(optional)



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

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.

that’s a bummer! how beautiful would be that when you upload a file to ask you: keep metadata or reset…

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.