[root@rhce-ryanrudolf]# rm -rf / 2> /dev/null

things I break/fix for fun and learning

Dec 4, 2017 - 1 minute read - Comments

This Site Now Utilizes HTTPS!

This site now utilizes HTTPS! HTTPS is the secure version of HTTP, the ’S’ at the end of HTTPS stands for ‘Secure’. It means that the communication is encrypted.

Several things to make it work in my environment - edit hugo config file, create port forward rule in router, and finally configure HTTPS in Apache.

Edit hugo config file and make changes in baseurl, make sure it reads https -

vi config.toml

baseurl = "https://ryanrudolf.duckdns.org"


Login to OpenWRT via ssh and create port forward rule, change 192.168.1.x respectively -

config redirect
        option target 'DNAT'
        option src 'wan'
        option dest 'lan'
        option proto 'tcp'
        option src_dport '443'
        option dest_ip '192.168.1.x'
        option dest_ip '192.168.1.x'
        option dest_port '443'
        option name 'https'


While still logged in to OpenWRT, restart the firewall to apply the changes -

/etc/init.d/firewall restart

Check if there are errors, you should see something similar -

 * Populating IPv4 nat table
   * Zone 'lan'
   * Zone 'wan'
   * Redirect 'http'
   * Redirect 'ssh'
   * Redirect 'https'


The last part is to configure Apache to use SSL!

Like this page? Share it!