Simple CDN provides a simple way of re-writing your URL's for specific assets using custom defined rules.
Offload your assets to a content delivery network by using an origin-pull and re-writing your URL's to point to your off-site host.
Note that URL's will only be rewritten in your production environment!
Simple CDN provides easy configuration options for various situations. You could for example only rewrite URL's for images and video files, and even cycle between multiple hosts.
Simple CDN comes with a configuration file that you can edit at your leisure.
You'll need to run php artisan config:publish damianromanowski/simplecdn to publish the configuration to your application.
Step 1: Enable the rewriter
This is a global setting, if this is disabled, no rules will be processed.
'enabled' => true,
Step 2: Set your URL
If you want to cycle between multiple hosts, just add them to the array.
Define each group of patterns that you want, you can have one for images, css, js and video files that you can quickly enable or disable at any time.
The url parameter works just like the global url option, specify multiple to cycle between hosts.