Magento Open Source, 1.9.x
Media Storage CDN Setup

Storing media files in a CDN is another alternative supported in Magento. There is no full integration with a specific CDN, and you are responsible for choosing and configuring a CDN on your own. After configuring the CDN, you must complete the configuration from the Admin. The changes can be made at either the global or website level.

Important! When a CDN is used as media storage, JavaScript may not function properly if the CDN is not in your subdomain. This is a browser security feature.

To configure a content delivery network:

1. On the Admin menu, select System > Configuration.
2. In the panel on the left, under General, select Web.
3. Set the Current Configuration Scope as needed.
4. Click to expand the Unsecure section. Then, do the following:
a. Change the value of the Base Media URL.
b. Change the value of the Base JavaScript URL.
5. Click to expand the Secure section.
a. Change the value of the Base Media URL.
b. Change the value of the Base JavaScript URL.
6. When complete, click the Save Config button.