Overview
Reseller free domains work like the unhosting.site free domain, but are specific to a particular reseller. They allow a reseller to maintain their own domain name branding while still using the unHosting server.
Reseller Setup Steps
Setup your free domain to be managed by Amazon Web Service (AWS) Route53
This can be the same AWS account you use to connect to unHosting, or a new dedicated account
If using a different account from your unHosting AWS connection, create a new key and security information
Provide the new credentials to Moodle US
Purchase a wildcard certificate for the free domain (GoDaddy Wildcard certs are known to work, but any provider should work)
Note: The quality of the certificate can impact your domain security scores, higher quality certificates will provide higher scores
Generate certificates
GoDaddy Download type, Apache
Securely provide Moodle US with certificates and AWS key and security
Lastpass or placing via Secure Shell (SSH) onto one of your unHosting stacks are both good methods
Note: Let's Encrypt certificates are technically compatible, but only have validity for 3 months. We do not currently have automation for Let's Encrypt certificate renewals. We don't recommend using free domains at this time (additional fees would apply from Moodle US for manual certificate maintenance).
Free Domain Rules
There are multiple AWS profiles that are tied to userid.
In each profile you can have as many different domains as needed.
AWS profile name is unique for a user (one user can not have two profiles with the same name).
Domains are unique. Domains can be tied to only one profile.
Each profile has attribute encrypted. If set to 1 (true), it signals that AWS key and secret are encrypted using Laravel encryption facility.
unHosting Control Panel (UHCP) Internal Setup
The profiles and domains are managed through new Laravel Command uhcp:freedomain.
Process is as follows:
Note: Replace vessel for php or other appropriate executable for non-dev setups
Enter the UHCP command line
To add new profile execute:
./vessel art uhcp:freedomain add profile --awsprofile='route53' --awskey='foo' --awssecret='faa' --awsaccountid='1234' --userid=1
Profile created through command line tool is always storing AWS key and secret encrypted for security reasons
To add domain to that profile execute:
./vessel art uhcp:freedomain add domain --awsprofile='route53' --domain='mydomain.net' --userid=1 --zoneid='SOMEZONEID'
To list existing profiles for a user execute:
./vessel art uhcp:freedomain list profile --userid=1
Apart from defining profile and domain, it is also important to add a certificate for the domain. The process for that is outlined here.
Removal
To delete profile execute:
./vessel art uhcp:freedomain delete profile --awsprofile='route53' --userid=1
To delete domain execute:
./vessel art uhcp:freedomain delete domain --domain='mydomain.net' --userid=1
For other details: ./vessel art uhcp:freedomain --help