added optional CDN support