How to get and use your CloudFront CDN
The Jitterx Panel Cloud CloudFront CDN gives you your own endpoint inside the CloudFront network that forwards traffic to your server. Instead of connecting straight to your VPS IP, your app connects to a CloudFront domain, and CloudFront hands the connection to your server. This guide explains what you need, how to buy it and how to keep it active.
How it works
Each CDN service has three pieces: a CDN host (a domain ending in cloudfront.net), your own path (for example /c1a2b3cmypath) and an origin, which is your server's domain or IP. When your app opens a WebSocket connection to the CDN host with your path, CloudFront forwards it to the origin on port 80. The path carries a prefix unique to your account, so nobody else can use yours.
What you need first
- Your own server (VPS) running a service that accepts WebSocket connections on port 80, for example an SSH tunnel over WebSocket.
- The origin: the server's public IPv4 or a domain that already points to it. If you don't have a domain, you can create one for free with the guide on pointing a subdomain to your VPS.
- An account on the site: you log in with your email and a 6-digit code, no passwords.
Step by step
- Go to the site, log in and open the CDN section in the menu.
- Choose how to pay: Card, Mercado Pago or PayPal.
- In Origin, type your server's domain or public IP.
- In Your path name, choose 2 to 20 lowercase letters or numbers, no hyphens or spaces. Your account prefix is added in front automatically.
- Tap the pay button. Each service costs $17.000 and lasts 30 days.
- Once the payment is approved, the service is created on its own. A few seconds later it shows up in My CDN services as Active, with the CDN host and the payload ready to copy.
Before charging you, the site checks that the origin and path are valid. If the service still couldn't be created after payment because of invalid details, the money is refunded automatically.
Copy the details into your app
Your service card shows the CDN host, port 80, the path and the CloudFront payload, each with a copy button. It also shows the service's traffic when the CDN provides it. The payload looks like this:
GET /your-path HTTP/1.1[crlf]Host: your-host.cloudfront.net[lf]Connection: Upgrade[lf]Upgrade: websocket[crlf][crlf]
How to load it into the app is explained in the guide on setting up HTTP Custom with your CDN.
Renewing and changing the origin
- Renew: on your service card tap Renew, choose how to pay and pay again. 30 days are added and you keep the same host, path and payload, so you don't need to touch the app.
- Change origin: if you move to another server, tap Change origin, type the new domain or IP and save. It's free.
- The site warns you when a service has less than 3 days left.
Common problems
"The origin domain doesn't resolve"
The domain you typed doesn't point to any IP yet. Check its A record or use the server's public IP directly.
The service is active but the app won't connect
Check that your server accepts WebSocket on port 80 and that your provider's firewall has that port open. Also make sure the payload is complete, including the last line.
"That path is already in use"
You already have a service with that name. Choose another path name.
Responsible use. The CDN is for connecting to your own services. Using it for spam, attacks or any illegal activity is forbidden; services that break this rule are suspended without notice.