Azure also offers a cheap alternative to hosting static content. See here for more details.
Go to your Azure Storage account. In the Overview section open the Capabilities tab, and then the Static website capability.
Enable and configure the Static website
capability, setting index.html
as the
Index document name and then click the
Save button.
In the Containers section, two new containers should show up:
Go to the Shared access tokens section and check the Read and Write permissions, then click the Generate SAS token and URL button.
Copy the Blob SAS URL that appears.
Please note that this key has a validity period which is configured in this same page. After this period expires, you won't be able to use the same SAS URL and you will have to generate a new one.
Go to the Download AzCopy page and download the appropriate version of the software for your system.
Go to the location where you generated the Cloud App ZIP and extract the contents of the zip into that location. Then place the azcopy from the previous step into this directory.
Create an HTML file inside the salesdemo_cloud_Installer folder and write the following contents:
<html> <head> <meta http-equiv="refresh" content="5; URL=salesdemo_cloud/" /> </head> <body> <p>If you are not redirected in five seconds, <a href="salesdemo_cloud/">click here</a>.</p> </body> </html>
This will, after 5 seconds, redirect the browser to the app's URL if the root URL is accessed.
If you want the redirection to be instantaneous you can use embedded Javascript code:
Please note that this will only work if the client's browser supports Javascript.
<html> <head> <script>window.location.replace('salesdemo_cloud/')</script> </head> <body> <p>If you are not redirected in five seconds, <a href="salesdemo_cloud/">click here</a>.</p> </body> </html>
In the folder where the ZIP file is, open a Terminal window and run the following command:
azcopy copy 'salesdemo_cloud_Installer\*' '<SAS Token URL>' --recursive=true
Where <SAS TOKEN URL>
is the URL you
copied from the Azure portal.
The tool will upload the files into the $web container.
After the upload finishes, go to the Storage account's Overview section, and open the Capabilities/Static website page (like you did to enable the Static website capability).
Follow the Primary endpoint URL.
You should be redirected to the Cloud App Installer's page after 5 seconds (or immediately, depending on the index.html you placed at the root).