- my url: https://rbcse.ridvan.org
- latest version of ghost
- ghost was installed via the digital ocean marketplace droplet
- node v16.19.1
- mysql Ver 8.0.32-0ubuntu0.20.04.2 for Linux on x86_64 ((Ubuntu))
- Browser, firefox
So initially I took the following steps to move to a different domain:
- point the new domain to the server with an a record
- ghost config url “newurl.com”
- ghost restart
When I did that and visited the new url I get an unsafe warning, so its clear I don’t have an SSL cert for the new domain. So I tried
- ghost setup ssl
which returns
SSL has already been set up, skipping
ℹ Setting up SSL [skipped]
So I tried to install certbot and generate the certificates that way with:
- sudo snap install core; sudo snap refresh core
- sudo snap install --classic certbot
- sudo ln -s /snap/bin/certbot /usr/bin/certbot
- sudo certbot --nginx
which errored with:
The requested nginx plugin does not appear to be installed
So I installed certbot with get-apt and then try to run it:
- sudo apt-get install python3-certbot-nginx
- sudo certbot --nginx
I get the following error:
Error while running nginx -c /etc/nginx/nginx.conf -t.
nginx: [emerg] cannot load certificate "/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer": BIO_new_file() failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer','r') error:2006D080:BIO routines:BIO_new_file:no such file)
nginx: configuration file /etc/nginx/nginx.conf test failed
The nginx plugin is not working; there may be problems with your existing configuration.
The error was: MisconfigurationError('Error while running nginx -c /etc/nginx/nginx.conf -t.\n\nnginx: [emerg] cannot load certificate "/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer": BIO_new_file() failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen(\'/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer\',\'r\') error:2006D080:BIO routines:BIO_new_file:no such file)\nnginx: configuration file /etc/nginx/nginx.conf test failed\n')
So I tried to reboot the server, and now ghost is running, but nginx is not serving it properly. Ghost doctor returns:
✔ Checking system Node.js version - found v16.19.1
✔ Checking logged in user
✔ Ensuring user is not logged in as ghost user
✔ Checking if logged in user is directory owner
✔ Checking current folder permissions
System checks failed with message: 'Missing package(s): nginx'
Some features of Ghost-CLI may not work without additional configuration.
For local installs we recommend using `ghost install local` instead.
? Continue anyway? (y/N)
So I tried reinstalling ghost cli with the following, but still get the same result as above with ghost doctor.
ghost update 5.24.2 --force
When I run sudo nginx
I get the following:
nginx: [emerg] cannot load certificate "/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer": BIO_new_file() failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/etc/letsencrypt/rbc.johnnypaycash.com/fullchain.cer','r') error:2006D080:BIO routines:BIO_new_file:no such file)
So I tried removing the following files, hoping that they were preventing new ones from being generated:
- sudo rm rbc.johnnypaycash.com.conf
- sudo rm rbc.johnnypaycash.com-ssl.conf
No luck.
Can I have some help to either restore the site and move to a new domain?