Skip to main content

CDN Configuration

This guide explains how to configure your CDN to work with OwnStak environments.

Origin Configuration

When setting up your CDN, you need to point it to your environment's backend URLs. These URLs are visible in your environment overview page in the OwnStak Console. You should configure one origin per cloud backend in your environment.

Header Configuration

To ensure proper routing and functionality, your CDN must be configured to send the correct host header. You have two options:

Option 1: Using Host Header

Configure your CDN to send the Host header matching the host from your environment link. If you need to preserve the original host, you can use the X-Forwarded-Host header to pass it through.

Example configuration:

Host: your-environment.backend1.your-org.ownstak.link
X-Forwarded-Host: your-original-domain.com

Option 2: Using X-Own-Host Header

Alternatively, you can use the X-Own-Host header to specify the environment host:

X-Own-Host: your-environment.backend1.your-org.ownstak.link