LetsEncrypt Cert with EC2 Bitnami

Awesome! Here goes…

/opt/bitnami/apps/wordpress/htdocs/xmlrpc.php

Hi,

I’m just wondering. Have you tried this link:
https://docs.bitnami.com/aws/how-to/generate-install-lets-encrypt-ssl/

That’s helpful to me when I’m using this service.

Thank you.

1 Like

Hi Steven!

No, I have not and do not know how it differs from the current script I am running from S3. Do you know it it will accomplish the same means?

Thanks,

sudo ./certbot-auto certonly --webroot -w /opt/bitnami/apps/wordpress/htdocs/ -d baim.tv

Fingers crossed.

1 Like

Awesome! It worked!!! YEA!!! Thank _az! Now I am attempting to restart the server but cannot

Say the Certificate was successful, but on restart it’s not found :frowning: confused!

Hey what happened? I was typing the commands when you pulled them back.

I gave an incorrect response. If you look at your ln -s commands, you accidentally typo’d .pen instead of .pem. That’s most likely the only issue.

1 Like

LOL! Awe man, so do I have to run them all again from the beginning?

No, just the two ln -s commands correctly typed should be sufficient, and then restart Bitnami at the end.

1 Like

For some reason, it says both links already exists…

Ah yeah you’ll need to use ln -sf rather than ln -s, to overwrite them.

You can press the ‘up’ and ‘down’ arrow key in the console to see previous commands and use left/right arrow keys to move around, if you were typing them out by hand every time.

1 Like

Awesome! Was able to rewrite. Now I am on this step and trying to add this renew code:

Extra if you would like to force https

sudo vim /opt/bitnami/apache2/conf/bitnami/bitnami.conf
Add the text below here:

< VirtualHost default:80 >
DocumentRoot “/opt/bitnami/apache2/htdocs”

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/(.*) https://%{SERVER_NAME}/$1 [R,L]

Before you do that, you may wish to change your WordPress Site URL to https://baim.tv , otherwise WordPress will use the insecure versions of your resources and fail to load them.

https://codex.wordpress.org/Changing_The_Site_URL

1 Like

Sure thing, but when I log into my WP both are greyed out :frowning:

For others running the bitnami wordpress on amazon LightSail (like this), here is a guide to using letsencrypt-auto : https://medium.com/unicorn-supplies/ssl-for-aws-lightsail-wordpress-8053359a774f

I’d advise against using WP Encrypt plugin as I’ve found it doesn’t renew properly.

1 Like

Hello,

I am sorry we did not finish this chat, but I am at the final steps and having trouble completing them. Here is where I am:

!Important to renew simply run in your tmp folder.

./certbot-auto renew
Extra if you would like to force https

sudo vim /opt/bitnami/apache2/conf/bitnami/bitnami.conf
Add the text below here:

< VirtualHost default:80 >
DocumentRoot “/opt/bitnami/apache2/htdocs”

RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^/(.*) https://%{SERVER_NAME}/$1 [R,L]

When I run this command:

sudo vim /opt/bitnami/apache2/conf/bitnami/bitnami.conf

the following screen pops up, but I cannot edit the settings as detailed.