Config.production.json url property https error

Hello,
new to Ghost in production even i tested it on local installation for a while.

my config

  • ubuntu 18
  • apache
  • node js v12

working configuration
(because i can’t have more than 3 links as a new user)
$HTTP=http://127.0.0.1:2368
$HTTPS=https://127.0.0.1:2368

if i configure ghost blog with http everyting works well, the apache proxy redirect is ok and i can get the site on my dedicated domain with a virtualhost in apache. the apache redirection is on $HTTP

I setup SSL with let’s encrypt and got key, the apache configuration works well again i can contact the site using HTTPS, however some links has HTTPS and other still HTTP. cert keys are configured in apache.

configuration with error
So in config.production.conf, i set url=https://mydomain.com and let apache redirection to $HTTP.
This does not work, here is a wget output:

> wget $HTTP
--2020-02-26 12:03:26--  $HTTP
Connecting to 127.0.0.1:2368... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: $HTTP [following]
--2020-02-26 12:03:26--  $HTTPS
Connecting to 127.0.0.1:443... connected.
ERROR: certificate common name ‘anotherdomaine.com’ doesn't match requested host name ‘127.0.0.1’.
To connect to 127.0.0.1 insecurely, use `--no-check-certificate'.

So i changed the “redirection to” in apache with https://127.0.0.1:2368 with no more success, here is wget output:

> wget $HTTPS
--2020-02-26 11:54:01--  $HTTPS
Connecting to 127.0.0.1:2368... connected.
OpenSSL: error:1408F10B:SSL routines:ssl3_get_record:wrong version number
Unable to establish SSL connection.

questions
looks like ‘url’ config definition is used to generate link in site AND to configure redirection if request is on HTTP.

  • how to disable ghost redirection on localhost on port 443, just answer to port 2368 request?
  • how to correct SSL error in ghost website.?
  • any idea to fix this and get whole site in https?

comment

  • sad as a new user i can’t write the redirection links of my config more than 3 times :frowning:

Than you in advance for your help.
keep on the good work.
Éric

Hey, did you follow the instructions provided here?

Thank you for your fast answer.

Yes i did it, however, biggest part of installation documentation is about nginx. And

> ghost setup ssl

requires nginx.
Unfortunetly, apache is configured on my server hosting several domain.

Eric