问题
When I try to resize an image, using AzureReader2, I get a 404. However, this does not happen in development with the storage emulator, only when deployed to Azure. It also doesn't happen when there is no resizing.
So
http://myapp.azurewebsites.net/c-images/product-images/1dc870bd-21a2-4e02-9b60-4750f6b20a7e.png
redirects to
http://mystorage.blob.core.windows.net/product-images/1dc870bd-21a2-4e02-9b60-4750f6b20a7e.png
but
http://myapp.azurewebsites.net/c-images/product-images/1dc870bd-21a2-4e02-9b60-4750f6b20a7e.png?width=100
results in a 404.
Here is my config
<add name="AzureReader2" prefix="~/c-images/" connectionString="DefaultEndpointsProtocol=https;AccountName=mystorage;AccountKey=***" endpoint="http://mystorage.blob.core.windows.net/" />
Any ideas?
回答1:
The issue was that I was precompiling the site when I published it to Azure. Specifically, I had Allow precompiled site to be updated
checked and Do on merge
selected. Bug filed.
来源:https://stackoverflow.com/questions/17685102/resizing-an-image-using-azurereader2-results-in-404