Be in the foler that the certificate is in or else write the path to certificate. Dont include '[ ]'
CD into folder containing SSH Key
ssh bitnami@[ip-address] -i [name-of-certificate]
If you get an error about the certificate being insecure, cd into the directory that the certificate is located in and run the following:
sudo chmod 600 [name-of-the-cert]` (Remove the brackets when writing in terminal)
Then try the first instruction again.
cat bitnami_application_password
ssh -N -L 8888:127.0.0.1:80 -i KEYFILE bitnami@SERVER-IP
Then go to: http://127.0.0.1:8888/phpmyadmin/
Login with username: root and password is the bitnami application password in the bitnami folder on the server. FTP into the server to get it. It will be different for every instance.
Once in the database, create a new database for wordpress and a user for the database
Every Folder in wp-content ( Root ) 775 bitnami:daemon
cd into the root directory
sudo chown -R daemon:bitnami htdocs/
sudo find htdocs/ -type d -exec chmod 775 {} \;
sudo find htdocs/ -type f -exec chmod 664 {} \;
Emails do not use www in their domain lookup, so you must specify the root domain
Stop Server sudo /opt/bitnami/ctlscript.sh stop
Start Server sudo /opt/bitnami/ctlscript.sh start
By default lightsail has a pretty hardcore cache which is one of the reasons its so fast. During development this is annoying because the files take a while to refresh after a new upload to the ftp. During development edit line 1906 of the php.ini file to have the opcache.enable=0 instead of 1. Once going live this should be turned back on with a value of 1.
Location of php.ini
/opt/bitnamii/php/etc/php.ini
Location of httpd.conf
/opt/bitnami/apache2/conf/httpd.conf
comment out lines 526 and 527
Include conf/pagespeed.conf
Include conf/pagespeed_libraries.conf
Now restart the Server
https://docs.bitnami.com/aws/how-to/generate-install-lets-encrypt-ssl/
If you want to use (www) in your domain then you need specify www.example.com for any reference of DOMAIN in the instructions above.
bitnami@server-ip -i keyfile
sudo /opt/bitnami/ctlscript.sh stop
sudo pico
sudo /opt/bitnami/ctlscript.sh stop apache
sudo /usr/local/bin/lego --email="EMAIL-ADDRESS" --domains="DOMAIN" --path="/etc/lego" renew
sudo /opt/bitnami/ctlscript.sh start apache
sudo chmod +x ./renew-certificate.sh
sudo mv ./renew-certificate.sh /etc/lego/renew-certificate.sh
sudo crontab -e
0 0 1 * * /etc/lego/renew-certificate.sh 2> /dev/null
sudo /opt/bitnami/ctlscript.sh start