The error message "Error setting certificate verify locations: CAfile: /etc/pki/tls/certs/ca-bundle.crt CApath: none" indicates that the SSL certificate verification failed. This can happen if the SSL certificate is not installed correctly or if the CA bundle is not configured properly.
To resolve this issue, you can try the following steps:
- Verify that the SSL certificate is installed correctly on the server. You can use the following command to check the SSL certificate:
openssl s_client -connect api.hetzner.cloud:443
If the SSL certificate is installed correctly, you should see the certificate chain and other details.
- Verify that the CA bundle is configured correctly. You can check the CA bundle location by running the following command:
php -r "echo ini_get('openssl.cafile');"
If the CA bundle location is incorrect, you can set it using the following command:
ini_set('openssl.cafile', '/path/to/ca-bundle.crt');
- If the above steps do not work, you can disable SSL certificate verification by adding the following option to the curl request:
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
Note that disabling SSL certificate verification is not recommended as it can make your application vulnerable to man-in-the-middle attacks.