Jump to content

Vestacp + Blesta = Awesome


EidolonHost

Recommended Posts

And they have an API

https://vestacp.com/docs/api/#add_user

<?php

// Server credentials
$vst_hostname = 'server.vestacp.com';
$vst_username = 'admin';
$vst_password = 'p4ssw0rd';
$vst_returncode = 'yes';
$vst_command = 'v-add-user';

// New Account
$username = 'demo';
$password = 'd3m0p4ssw0rd';
$email = 'demo@gmail.com';
$package = 'default';
$fist_name = 'Rust';
$last_name = 'Cohle';

// Prepare POST query
$postvars = array(
    'user' => $vst_username,
    'password' => $vst_password,
    'returncode' => $vst_returncode,
    'cmd' => $vst_command,
    'arg1' => $username,
    'arg2' => $password,
    'arg3' => $email,
    'arg4' => $package,
    'arg5' => $fist_name,
    'arg6' => $last_name
);
$postdata = http_build_query($postvars);

// Send POST query via cURL
$postdata = http_build_query($postvars);
$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);
$answer = curl_exec($curl);

// Check result
if($answer == 0) {
    echo "User account has been successfuly created\n";
} else {
    echo "Query returned error code: " .$answer. "\n";
}
?>
Link to comment
Share on other sites

True but...

 

Lowendbox put vestaCP as the best free cpanel out there they have tested so far. 

http://lowendbox.com/blog/editorial-review-of-free-web-hosting-panels/

 

vesta_CP.png

 

 

True it was built by Russians, but hey, no ones' perfect! ;)

 

It depends on who does the star rating, from what I know everyone prefers Webmin and others prefer CentOS Webpanel.

Link to comment
Share on other sites

It depends on who does the star rating, from what I know everyone prefers Webmin and others prefer CentOS Webpanel.

 

True...

 

At least 1 module for a popular free control panel, would really be a good thing for blesta.  Im not a vestacp fan boy,  I don't mind which distro or cpanel, i need to install, as long as it's secure and free :)

Link to comment
Share on other sites

  • 1 year later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...