Create a Subdomain
You may want to purchase multiple subdomains when there are various functions for your website. For example, using store for an online store or support for your customer support site.
A subdomain reflects a completely different URL from the original domain.
Subdomain vs subdirectory
A subdomain goes before the TLD. For example blog.host.com, where blog is the subdomain.
A subdirectory resides under (after) the FQDN. For example www.host.com/blog/ is the subdirectory.
Each subdomain has its own public_html folder, which consists of the public-facing domain information.
Some hosting companies allow users to create an unlimited number of subdomains, but also remember that the subdomains share the resource for the primary domain.
So, use subdomains sparingly.
To create a subdomain in edjDNS:
In this tutorial, you will create two A records: primary domain host.com
and a subdomain support.host.com
.
TYPE | NAME | TARGET | TTL | PROXY |
---|---|---|---|---|
A |
@ |
192.168.1.6 |
1800 |
enabled |
A |
support |
192.168.1.6 |
1800 |
enabled |
Use EdjConsole
-
Log into EdjConsole.
-
Switch to the organization associated with the domain you want to add the record to.
-
Navigate to Main Menu > Domains.
The Domain page displays. -
Click on a domain.
The Domain Attributes page displays. -
Click Create Record.
-
Enter the following for the A record,
@
.-
TYPE: A
-
NAME: @
-
TARGET: 192.168.1.6
-
TTL: 1800
-
PROXY: enable
-
-
Click Save.
The A record is added to the list of resource records for the domain.
-
Click Create Record.
-
Enter the following for the A record,
support
.-
TYPE: A
-
NAME: support
-
TARGET: 192.168.1.6
-
TTL: 1800
-
PROXY: toggle right (enable)
-
-
Click Save.
The A record is added to the list of resource records for the domain.
Use EdjCLI
-
Log into EdjCLI.
edjx login Username: <string> ✔ Password: **********█ Logged in successfully root@edjx:~ #
-
Switch to the organization associated with the domain you want to add the record to.
edjx config organization -i
-
Select the domain to add the record to.
edjx config domain -i
-
Create the A record for your primary domain.
root@edjx:~ # edjx domain records create @ A 192.168.1.6 1800 --proxy Record created successfully. Record ID: 96cafdf6-df8b-4b95-bed3-46c1d8d21d17
-
Create the
support
A record.root@edjx:~ # edjx domain records create support A 192.168.1.6 1800 --proxy Record created successfully. Record ID: ed75a20a-e0b5-495a-9c02-f9e7540e0558
See edjx domain records create for additional details.