JSON file error on ghost start

Hi all!

I’m having an issue starting my Ghost blog on AWS Lightsail. I get an error that the “Config file is not valid JSON”.

Here is the file in question:

{
        "url": "https://url.net",
        "server": {
"port": 2368,
"host": "0.0.0.0"
},
"database": {
"client": "mysql",
"connection": {
"host": "127.0.0.1",
"port": 3306,
"database": "bitnami_ghost",
"user": "bn_ghost",
"password": "REDACTED"
}
},
"mail": {
"transport": "SMTP",
"options": {
"service": "Mailgun",
"host": "smtp.mailgun.org",
"port": 587,
"secureConnection": false,
"auth": {
"user": "postmaster@mailer.redacted.net",
"pass": "redacted"
}
}
},
"logging": {
"transports": [
"file",
"stdout"
]
},
"process": "local",
"paths": {
"contentPath": "/opt/bitnami/ghost/content"
}
}

I can’t see anything wrong with what you posted, but here’s a tidy, valid JSON version.


{
	"url": "https://url.net",
	"server": {
		"port": 2368,
		"host": "0.0.0.0"
	},
	"database": {
		"client": "mysql",
		"connection": {
			"host": "127.0.0.1",
			"port": 3306,
			"database": "bitnami_ghost",
			"user": "bn_ghost",
			"password": "REDACTED"
		}
	},
	"mail": {
		"transport": "SMTP",
		"options": {
			"service": "Mailgun",
			"host": "smtp.mailgun.org",
			"port": 587,
			"secureConnection": false,
			"auth": {
				"user": "postmaster@mailer.redacted.net",
				"pass": "redacted"
			}
		}
	},
	"logging": {
		"transports": [
			"file",
			"stdout"
		]
	},
	"process": "local",
	"paths": {
		"contentPath": "/opt/bitnami/ghost/content"
	}
}

Thank you! It doesn’t work, it throws the same error. However, it does work with “ghost run” but of course, this is not the way to leave the website live. I don’t quite know what else to do and at this point I think I’ll make a new install and migrate everything :smiling_face_with_tear: