We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on v1 candidate and expect to engage more with the community over the coming months. We are committed to open source, and we encourage contributors to help us build the future of Vesta.
Error use "v-add-letsencrypt-domain" on my server
-
- Posts: 13
- Joined: Sat Sep 30, 2017 3:17 am
Error use "v-add-letsencrypt-domain" on my server
On my localhost, every ok (return 0 - success).
On centos server, I can't add letsencrypt with curl, return like the image
My script
Error image
Please help me, thank you!
On centos server, I can't add letsencrypt with curl, return like the image
My script
Code: Select all
<?php
// Server credentials
$vst_hostname = 'xxxxxxx';
$vst_username = 'xx';
$vst_password = 'xx';
$vst_returncode = 'yes';
$vst_command = 'v-add-letsencrypt-domain';
// Prepare POST query
$postvars = array(
'user' => $vst_username,
'password' => $vst_password,
'returncode' => $vst_returncode,
'cmd' => $vst_command,
'arg1' => $vst_username,
'arg2' => 'phanhuuhien.aztest.vn'
);
$postdata = http_build_query($postvars);
// Send POST query via cURL
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, 'https://' . $vst_hostname . ':8083/api/');
curl_setopt($curl, CURLOPT_RETURNTRANSFER,true);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_POST, true);
curl_setopt($curl, CURLOPT_POSTFIELDS, $postdata);
$return = curl_exec($curl);
// Check result
if($return == 0) {
echo "ok";
} else {
echo "no ok";
}
?>
Please help me, thank you!
-
- Posts: 13
- Joined: Sat Sep 30, 2017 3:17 am