CategoryTagArticle

admin

I'm a Full-stack developer

Tag

Linked List
Data Structure
Chat GPT
Design Pattern
Microservices
API
AWS CDK
ReactJS
AWS Lightsail
Flutter Mobile
Part 2: Setup Custom Domain Zone + SSL for Ghost on AWS Lightsail
Published date: 17/06/2023

In this section, I will continue to show you how to point Ghost Instance Static IP to your domain. Don't worry because you don't have a Ghost blog page for yourself, you can follow my instructions in part 1


Enable HTTPS on your Ghost Instance


  • Connect to instance
  • Run bncert tool with the command below
sudo /opt/bitnami/bncert-tool
  • Enter the main domain name and the alternate domain name separated by a space as shown below

  • Type Y and press Enter to continue

  • Enter your email address

  • Type Y and press Enter to continue

  • The certificate has been successfully verified

  • Modify the Apache configuration file
sudo vi /opt/bitnami/apache2/conf/httpd.conf



  • Search in the file and update below
<IfModule headers_module>
    #
    # Avoid passing HTTP_PROXY environment to CGI's on this or any proxied
    # backend servers which have lingering "httpoxy" defects.
    # 'Proxy' request header is undefined by the IETF, not listed by IANA
    #
    RequestHeader unset Proxy early
    RequestHeader set X-Forwarded-Proto "https"
</IfModule>



  • Restart Ghost and Apache
sudo /opt/bitnami/ctlscript.sh restart ghost
sudo /opt/bitnami/ctlscript.sh restart apache


Check your website


Custom domain


  • I use matbao for SSL and domain management. dinhthanhcong.info was created on matbao. We need to delete the DNS and A, CNAME records then add 2 records to AWS Lightsail.

  • On matbao, we need to update the DNS records that we have from AWS Lightsail.

At this point, setting up the domain name for your Ghost blog has been successful. You can check by entering the URL https://www.dinhthanhcong.info/ from a web browser and something similar to https://<PusblishIP>


Thanks for reading !!!

Recommend

TypeScript Design Pattern - Abstract Factory
admin07/08/2023

TypeScript Design Pattern - Abstract Factory
The abstract factory pattern is one of five design patterns in the Creational Design Pattern group. The abstract factory provides an interface for creating families of related or dependent objects without specifying their concrete classes.
TypeScript Design Pattern - Singleton
admin07/08/2023

TypeScript Design Pattern - Singleton
The singleton ensures only a single install is created in a class and provides a method to access this instance everywhere in a codebase.
Newest

Extract data using web scraping with Python
admin14/03/2024

Extract data using web scraping with Python
A beginner’s guide to learn web scraping with Python!
ĐINH THÀNH CÔNG - Software Developer
admin12/01/2024

ĐINH THÀNH CÔNG - Software Developer
Cong Dinh - Software Developer - My personal website, where I write blogs on a variety of topics and where I have some experiments with new technologies.
What are the SOLID principles?
admin17/06/2023

What are the SOLID principles?
If we want to have good software, the infrastructure should be good first. We should learn more techniques that help to have better quality.
Đinh Thành Công Blog

My website, where I write blogs on a variety of topics and where I have some experiments with new technologies.

hotlinelinkedinskypezalofacebook
DMCA.com Protection Status
Feedback
Name
Phone number
Email
Content
Download app
hotline

copyright © 2023 - AGAPIFA

Privacy
Term
About