Ghost Setup SSL Failure

Hello friends,

I am attempting to setup ghost but the “ghost setup ssl” command fails every time I try running it. Everything on my server is up-to-date;
I ran “sudo apt-get update” & “sudo apt-get upgrade”.

Here’s the output:

raj@vps-XXXXXXXX:/var/www/realraj39$ ghost setup ssl
? Enter your email (For SSL Certificate) realraj39@outlook.com
+ sudo /etc/letsencrypt/acme.sh --issue --home /etc/letsencrypt --domain realraj39.net --webroot /var/www/realraj39/system/nginx-root --reloadcmd "nginx -s reload" --accountemail realraj39@outlook.com
✖ Setting up SSL
One or more errors occurred.

1) ProcessError

Message: Command failed: /bin/sh -c sudo -S -p '#node-sudo-passwd#'  /etc/letsencrypt/acme.sh --issue --home /etc/letsencrypt --domain realraj39.net --webroot /var/www/realraj39/system/nginx-root --reloadcmd "nginx -s reload" --accountemail realraj39@outlook.com
[Thu May 27 20:25:58 UTC 2021] Sign failed, finalize code is not 200.
[Thu May 27 20:25:58 UTC 2021] {
  "type": "urn:ietf:params:acme:error:orderNotReady",
  "detail": "Order's status (\"invalid\") is not acceptable for finalization",
  "status": 403
}
[Thu May 27 20:25:58 UTC 2021] Please add '--debug' or '--log' to check more details.
[Thu May 27 20:25:58 UTC 2021] See: https://github.com/acmesh-official/acme.sh/wiki/How-to-debug-acme.sh

[Thu May 27 20:25:53 UTC 2021] Using CA: https://acme-v02.api.letsencrypt.org/directory
[Thu May 27 20:25:53 UTC 2021] Single domain='realraj39.net'
[Thu May 27 20:25:53 UTC 2021] Getting domain auth token for each domain
[Thu May 27 20:25:55 UTC 2021] Getting webroot for domain='realraj39.net'
[Thu May 27 20:25:55 UTC 2021] Verifying: realraj39.net
[Thu May 27 20:25:57 UTC 2021] Success
[Thu May 27 20:25:57 UTC 2021] Verify finished, start to sign.
[Thu May 27 20:25:58 UTC 2021] Lets finalize the order.
[Thu May 27 20:25:58 UTC 2021] Le_OrderFinalize='https://acme-v02.api.letsencrypt.org/acme/finalize/125043400/9995299117'

Exit code: 1


Debug Information:
    OS: Ubuntu, v20.04.2 LTS
    Node Version: v14.17.0
    Ghost Version: 4.6.4
    Ghost-CLI Version: 1.17.3
    Environment: production
    Command: 'ghost setup ssl'

Additional log info available in: /home/web/.ghost/logs/ghost-cli-debug-2021-05-27T20_25_58_303Z.log

Try running ghost doctor to check your system for known issues.

You can always refer to https://ghost.org/docs/ghost-cli/ for troubleshooting.