Your site is reachable at an address like http://102.215.225.40. This article makes it answer to yourcompany.com instead.
Before you start
Your site must already open on the IP address. If it does not, finish Set up your server so a browser can open your site first, otherwise you will be guessing at two problems at once.
You also need to be able to sign in wherever you bought the domain. That is your registrar: for example Ricta for .rw names, or GoDaddy, Namecheap or Cloudflare.
The records to create
In your registrar's DNS or Name Server settings, create two records:
| Type | Name or Host | Value | TTL |
|---|---|---|---|
| A | @ |
your server's public IP | 3600 |
| A | www |
your server's public IP | 3600 |
@ means the domain itself (yourcompany.com) and www covers www.yourcompany.com. Some registrars want the full name instead of @; if the form rejects it, type yourcompany.com.
Delete any old A records for the same names, including ones pointing at a previous host or a parking page. Two A records for one name send visitors to both places at random.
How long it takes
Usually a few minutes, up to a few hours. The world does not update at once, so you may see the new site while a colleague still sees the old one. Do not change the records again while you wait, that only restarts the clock.
Check what the internet currently sees:
nslookup yourcompany.com
When the answer is your server's IP, you are done.
Then tell the web server its name
Open http://yourcompany.com. You should see your site. If you plan to host more than one site on the same server, or you use WordPress, set the name in the Apache configuration as well:
sudo nano /etc/apache2/sites-available/000-default.conf
Under <VirtualHost *:80>, add these two lines, then save with Ctrl+O and exit with Ctrl+X:
ServerName yourcompany.com
ServerAlias www.yourcompany.com
sudo systemctl reload apache2
If you use our DNS service
If your domain's name servers point at Gewape Cloud rather than your registrar, create the same records in the console instead. See Managing your DNS.
Next
With the domain answering, turn on HTTPS. The certificate is issued for your domain name, so it has to be this way round: domain first, certificate second.