I used Azure blob to store images. I tested on local machine (with emulator) and it works. As you know, it uses URI like
http://127.0.0.1/xxx
But after I deployed to Azure, it doesn't work. I have
(1) changed the StorageConnectionString to point to Azure blob (instead of local emulated blob)
(2) changed blob access from 'off' to 'container'
(3) linked this blob to my website
I cannot think of anything else I need to do to make it work.
Can anyone help me?
Edit:
More information:
on local:
<add key="StorageConnectionString" value="DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1" />
on Azure:
<add key="StorageConnectionString" value="DefaultEndpointsProtocol=http;AccountName=[myAccount];AccountKey=[myKey];BlobEndpoint=http://[myBolbName].blob.core.windows.net/" />
The error on Azure is (when I click a button to upload an image):
Application: 2014-05-09T07:45:12 PID[22228] Error Unable to connect to the remote server
Application: at Microsoft.WindowsAzure.Storage.Core.Executor.Executor.ExecuteSync[T](RESTCommand`1 cmd, IRetryPolicy policy, OperationContext operationContext)
Application: at Microsoft.WindowsAzure.Storage.Blob.CloudBlockBlob.UploadFromStreamHelper(Stream source, Nullable`1 length, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext)
Application: at xxx.Utility.AzureStorageAccess.UploadBlob(Stream stream, String containerName, String blobRelativeURI, String& blobURI)
Application: at xxx.xxx.xxx.btnSubmit_Click(Object sender, EventArgs e)