Networking

Configuring DNS & IP Addresses

Cloud 66 hostnames

Cloud 66 creates unique DNS hostnames for each server you deploy with us. All servers are accessible via their Cloud 66 DNS name which follows the following pattern:

[server_name].[app_name].[environment].c66.me.

These use animal names to make them more easily recognizable. For example:

puma.railsdemo.development.c66.me
walrus.myapp.production.c66.me

Load Balancers also get a name from Cloud 66 DNS. The load balancer names look like [app_name].[environment].c66.me. For example, the DNS could look like: myapp.test.c66.me. Production applications don't have the environment in their names, for example myapp.c66.me.

This allows you to change the servers (and therefore IP addresses) for your application without needing to change any public DNS entries.

You will need to manage the DNS records of your domain name to ensure that it's pointing to Cloud 66.

Where possible, you should avoid using a DNS A-record (which points directly at an IP address). Instead, you should use CNAME records to point your domain at a hostname (either your server hostname or a failover group address).

However, this may not be possible with your DNS provider. While CNAME records do not require hard-coded IP addresses, they are not available to root domains (eg. example.com). In other words, you would not be able to set a CNAME record pointing example.com to a Cloud 66 hostname.

To use wildcard subdomains with Cloud 66 hostnames, simply create a CNAME record pointing *. .com to your Cloud 66 hostname.

Browsing your app via Cloud 66 DNS

You can browse your application directly by visiting the Cloud 66 address for the primary web server. To do this:

  1. Log into your Dashboard
  2. Open your Application Overview
  3. Click on the Visit Site link (next to the app's name)

Turn off HTTPS

You cannot call your app via the Cloud 66 host address over HTTPS. If you have a redirect from HTTP to HTTPS turned on, you will need to turn it off first.

Cloud 66 Agent

Cloud 66 automatically detects the internal and external IP addresses of your servers through an agent installed on each server. This agent sends information about your server back to us at a 5 minute interval, which is used to auto-generate the WEB_ADDRESS_INT and WEB_ADDRESS_EXT environment variables (among others) when necessary.

To allow users the flexibility of choosing which one to use in their application, we also provide a WEB_ADDRESS environment variable, which by default is set to {{WEB_ADDRESS_INT}} but can be modified by the user.

IP addresses can change

Some cloud providers automatically assign a new IP address to restarted servers.

New IP addresses

If the agent fails to send us information for 20 minutes, the server owner is notified by email. Should the server IP address subsequently change, we are notified by the agent, which in turn updates the environment variables affected.

If the new IP address is reachable, Cloud 66 ensures that firewall rules are reconstructed, ActiveProtect is reconfigured and DNS records are updated accordingly.

Furthermore, if required, the load balancer is updated to serve the new IP address. Once this process is complete, the server owner receives a notification of success by email and will be encouraged to redeploy the application.

Finding your Cloud 66 hostnames

To find the Cloud 66 hostname for any server:

  1. Open your Dashboard and click on the application
  2. Click the Servers tab.
  3. Click the name of your server. This page displays your server's Primary address (hostname) as well as the Secondary address (IP address).

Failover hostnames

In addition to unique hostnames per server, Cloud 66 also offers Failover Groups - managed, quick-response DNS addresses that automatically follow the web endpoints of applications.

Each Failover Group has a unique hostname with a 9 digit prefix (subdomain). For example 958-797-516.cloud66.net. For maximum reliability, you should point your DNS at a Failover Group address.

Previous
Understanding Cron syntax