Pixelquest
New Pleskian
- Server operating system version
- Debian 12
- Plesk version and microupdate number
- 8.0.62
Hello, I would like to synchronize all SSL certificates to another server. So far I have managed to replicate the databases, website installations, all email accounts and the backups exactly. I'm just having trouble with the certificates and can't find a way.
An rsync of /opt/psa/var/certificates doesn't help because the certificates on the other server have different abbreviations in the file name.
Rewriting the file names or adjusting the "psa" database table "certificates" also has no effect. Both Plesk and the web browser retrieve an old certificate.
Then I thought about simply transferring the certificates via pleskstore CLI. But that would be difficult because I always have to specify the file name of the backup. There is no "latest backup" variable. This also makes automation with script and cron job impossible.
I also had the idea of importing the certificate using the "plesk bin certificates" CLI. In theory, this would also work perfectly with a script. I could convert the PEM file into a .key and .der file and simply import them back onto the target server. Unfortunately, the Plesk CLI does not offer a command with which I can set the copied certificate as the default for web, mail, webmail.
There must be something I've overlooked. I'd prefer an rsync of a directory that I may not yet know about or an adjustment to the psa database.
Does anyone have an idea? I can also imagine something completely different. It just has to be able to be automated. After all, the task doesn't even have to run every day.
An rsync of /opt/psa/var/certificates doesn't help because the certificates on the other server have different abbreviations in the file name.
Rewriting the file names or adjusting the "psa" database table "certificates" also has no effect. Both Plesk and the web browser retrieve an old certificate.
Then I thought about simply transferring the certificates via pleskstore CLI. But that would be difficult because I always have to specify the file name of the backup. There is no "latest backup" variable. This also makes automation with script and cron job impossible.
I also had the idea of importing the certificate using the "plesk bin certificates" CLI. In theory, this would also work perfectly with a script. I could convert the PEM file into a .key and .der file and simply import them back onto the target server. Unfortunately, the Plesk CLI does not offer a command with which I can set the copied certificate as the default for web, mail, webmail.
There must be something I've overlooked. I'd prefer an rsync of a directory that I may not yet know about or an adjustment to the psa database.
Does anyone have an idea? I can also imagine something completely different. It just has to be able to be automated. After all, the task doesn't even have to run every day.