• The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Make plugins

B

Bill Jobs

Guest
Hi,

How in the world do you make plugins for Plesk ?
I am a hoster and I wanted to make a plugin for my Plesk Panel.

I wanted to know how should you add links to the left panel and also what would be the path where we can place our PHP files that will process users input.

Something like how 4psa products, installatron add pages to plesk !

Regards,
Wbots
 
Hi,

I got most of it.
I just wanted to know one last thing.
When the module files are placed here:
/usr/local/psa/admin/htdocs/modules/module.php

What USER does PHP run as ?
Will it be running as the User who owns the file, the logged in user or NOBODY ?

Basically I want PHP to run as the Logged in user as we have to copy and delete files as per my module.

Regards,
Bill
 
Also this documentation is really bad and has no info of how to get information of a USER, CLIENT, DOMAIN
I found out that db_query() function is available.

And yes if you ask your PTN they say the question is quite DIRECT. So its not within their scope to help.
They say ask Parallels support.

Parallels support doesnt accept my ticket as I have my VPS from a VPS Provider and so tickets are not accepted!
This is really poor Documentation and Support for Developers.

Anyways can I know that to create a DB what entries do I need to put in the :
1) psa.data_bases table
2) psa.db_users table

If any other table is to be affected ?

Please let me know how to contact support for asking for help ?
I have a ACTIVE VPS for it and an Active License!

Regards,
BIll
 
I have some open source plesk modules (written in PHP) if you'd like to take a look at them.

Your PHP scripts will run as the userid "psaadm". I don't believe there is any way plesk would enable you to invoke the script as the user ID of the domain directly, however one workaround might be to make the script perform the copy/move/etc operations through ftp. In which case you could extract the username and password for the domain directly through the psa database.

One module you can look at for examples is:
http://www4.atomicorp.com/channels/source/atomic-yum/

this is a web front end for yum, and the src rpm also has the triggers to add it to the plesk custom buttons menu for the administrative user.
 
I think the documentation is enough from PLESK (you don't want to see the cPanel one, is a nightmare).
Of course you need to dig a little bit and also to know how it is working.

Usually PLESK API let you to do some stuffs what also can be done from PLESK Admin panel.
To do more, you will need to use tricks, wrappers, and so on.
 
atomicturtle, thanks for the inputs.
I will test that whether it runs as the user or not for the logged in user.
And yes FTP can be used as you suggested if it doesnt.

If you know anything on tables that are to be changed when MySQL DBs are created in Plesk then please let me know.
I know the two tables above need to be inserted with data.
But other than that are there any more changes to be done e.g. increase count of user dbs created or something of that sort.

And does Plesk help Developers by answering their questions/doubts ?
If so how to contact them. I tried the PTN nad Support but they refused!

Regards,
Bill
 
Bill,

I think that easy way for found all mysql related tables would be enabling logging in my.cnf, create test database and analyse mysql.log for all related inserts during database creation.
 
Hi,

I think that will work IgorG.
I will test it ASAP when I get back to the office tomorrow.
I also needed to add CRON Jobs for a USER.
Is there no documentation by Plesk for the information that I seek ??

It will help all of us and save time.

Regards,
Bill
 
If you're just trying to insert tables into database creation events, you might be able to put that together quickly with the event manager. If you wanted to tie that to a specific application, then I'd look at doing that with an application vault package.
 
Hi,

Almost got the whole thing working except PHP to running as the user.
Will a PERL Wrapper work ?

Regards,
Bill
 
Back
Top