Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Dev Section Scripting / API
  • Search

Extending the Admin API

Questions regarding the API
Application Programming Interface
Locked
  • Print view
Advanced search
10 posts • Page 1 of 1
Graham
Posts: 57
Joined: Wed Sep 25, 2013 6:32 pm

Extending the Admin API

Post by Graham » Sat Oct 19, 2013 9:35 am

Is there a recommended approach to extending the admin API in Vesta?

For example, if I have another command line tool that I would like to make available through the Vesta admin api.

Any examples that I could perhaps take a look at or that would make a good starting point?

Thanks
Top

skid
VestaCP Team
Posts: 1476
Joined: Wed Apr 06, 2011 11:12 pm

Re: Extending the Admin API

Post by skid » Sat Oct 19, 2013 12:33 pm

For now you can put additional scripts in /usr/local/vesta/bin/ and they will become available via API. Unfortunately, such method isn't sustainable across updates.

I will think about how we can cover this in feature releases.
Top

Graham
Posts: 57
Joined: Wed Sep 25, 2013 6:32 pm

Re: Extending the Admin API

Post by Graham » Sat Oct 19, 2013 12:54 pm

skid wrote:For now you can put additional scripts in /usr/local/vesta/bin/ and they will become available via API. Unfortunately, such method isn't sustainable across updates.

I will think about how we can cover this in feature releases.
Thanks skid. If I do add scripts now, do you think the updates will wipe them or just make them inoperable?
Top

skid
VestaCP Team
Posts: 1476
Joined: Wed Apr 06, 2011 11:12 pm

Re: Extending the Admin API

Post by skid » Sat Oct 19, 2013 1:17 pm

That's a good question. It all depends on system package manager and it seems like rpm doesn't wipe bin directory. Not sure about dpkg. I will check it later today.
Top

Graham
Posts: 57
Joined: Wed Sep 25, 2013 6:32 pm

Re: Extending the Admin API

Post by Graham » Sat Oct 19, 2013 1:33 pm

Thanks. At the moment I'm not sure whether to put my additions somewhere else with their own API or try and integrate them with the Vesta API.
Top

skid
VestaCP Team
Posts: 1476
Joined: Wed Apr 06, 2011 11:12 pm

Re: Extending the Admin API

Post by skid » Sat Oct 19, 2013 8:07 pm

I have a good news, apt-get upgrade didn't wiped directory. So you are safe to go.
Top

Graham
Posts: 57
Joined: Wed Sep 25, 2013 6:32 pm

Re: Extending the Admin API

Post by Graham » Sat Oct 19, 2013 8:16 pm

Fantastic. The approach I have taken so far has been to create additional v-xxxx-xxx-xxx commands. Works perfectly from the command line but I've yet to test it through the API.

Do you know if 'apt-get upgrade' does much to the 'skel' in the vesta templates?
Top

skid
VestaCP Team
Posts: 1476
Joined: Wed Apr 06, 2011 11:12 pm

Re: Extending the Admin API

Post by skid » Sat Oct 19, 2013 8:29 pm

Anything in /usr/local/vesta/data is beyond the apt or yum knowledge. Feel free to modify and change any file there.
Top

Graham
Posts: 57
Joined: Wed Sep 25, 2013 6:32 pm

Re: Extending the Admin API

Post by Graham » Sat Oct 19, 2013 8:41 pm

:-) this just gets better and better.
Top

skurudo
VestaCP Team
Posts: 8079
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: Extending the Admin API

Post by skurudo » Fri Sep 23, 2016 12:29 pm

API documentation and examples:
http://vestacp.com/docs/API.pdf

CLI commands list and descriptions:
http://vestacp.com/docs/CLI.txt

-> viewtopic.php?f=18&t=12610
-> DigitalOcean competition - please, support us
-> fix for phpmyadmin - nice and sweet now
Top


Locked
  • Print view

10 posts • Page 1 of 1

Return to “Scripting / API”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password