Django Blog Part 3 - Domain Registration and DNS Configuration
Oskar Ablimit
Cloudflare Enterprise Account Executive | Engineering in Cloud Computing |@ex-AWS| @ex-Alicloud | @ex-Tencent Cloud | Adjunct professor at Yeshiva University teaching Cloud Computing
This section, I will share how I made the blog available with custom domain, this will include registering a domain, configuring the DNS, SSL (CDN if needed).
-??????I registered a domain oskarcode from Cloudflare, it is 9.15 USD/year.
-??????Since Cloudflare also provide DNS service, you can configure DNS in Cloudflare, you need to define, 1) the type of record (can be A name or CNMAE), 2) The IP address, for my case I got it from AWS EC2 console, 3) Good thing about Cloudflare, it comes with auto TTL, so you don’t need to configure SSL by yourself. That is all, you need to wait a while for domain to be effective.?
?After it is effective, you can check by nslookup ,whois + domain to see if it is configured correctly.
2. I also listed some of the checklists.
- Buy domain
- Configure DNS: if your domain and DNS is not from the same registrar, you need to have name servers to add to DNS
- Configure reverse DNS: not sure if it is necessary, if the IP is from AWS, need to do with elastic IP
-Update the settings.py allowed hosts, add the domain as one of the allowed hosts. After change, reload the supervisor, otherwise the change is not synced
-Update the django.config in Nginx by adding new domains
Now, you can see your blog is live and is accessible from anywhere, try https://www.oskarcode.com/.
Cloudflare Enterprise Account Executive | Engineering in Cloud Computing |@ex-AWS| @ex-Alicloud | @ex-Tencent Cloud | Adjunct professor at Yeshiva University teaching Cloud Computing
2 年I newly added a simple todo app into my blog, with this app, you can add and manage todo lists, try it out, https://www.oskarcode.com/todo/