Nick Muller
Nick Muller

Reputation: 2313

Azure Web App for Containers state storage

According to this it's possible to mount a storage device to the /home directory, by setting the WEBSITES_ENABLE_APP_SERVICE_STORAGE app setting.

Is it recommended to use this storage mount to store irreplaceble data of my app (for example user content)?

Some sub questions that are a pre-requisite for the question above:

Honestly, it feels a bit dangerous, because I can't manage the underlying storage account by myself.

Upvotes: 1

Views: 503

Answers (1)

Tom Sun
Tom Sun

Reputation: 24569

Is it recommended to use this storage mount to store irreplaceble data of my app (for example user content)?

You could get the answer from this blog. You could use the mapped sharing path.

The absence of this app setting will result in the setting being "true". In other words, if this app setting does not exist in your app, you will see the /home directory mapped to Azure Storage.

According to the blog we could know that if you set WEBSITES_ENABLE_APP_SERVICE_STORAGE true, not add it in the app setting, you could use it normally.

  • Will this storage immediately be deleted if I accidantly remove the app setting?

If you want to use the mapped sharing path /home, I recommand that you don't add the WEBSITES_ENABLE_APP_SERVICE_STORAGE in the appsetting. If the appsetting is changed then, the instance will restart.

  • Can this storage be backed up?

Based on my knowledge, it seems that it is hard to get the files back if they are deleted.

Honestly, it feels a bit dangerous, because I can't manage the underlying storage account by myself.

If you are worry about that, I recommand that you could use that mapped sharing path and also backup the important file with self-owned Azure storage.

Upvotes: 1

Related Questions