Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    Member
    Join Date
    Feb 2010
    Posts
    20

    Default how to get cpanel triggres external script when new account is created?

    Hello everybody,

    I'm changing my configuration from running php as mod_php to suphp

    i found out that open_basedir tweak is not supported in suphp. and i searched for a solution for this issue and came to believe that as it's mentioned in easy apache documentation it can be done only manually.

    so what i am doing is i added the suphp_configpath directive to point to dir where there's custom php.ini file.

    and this looks like a solution to me. but it's not 1 account that i want to change they are hundreds.

    i can write a script that changed vhosts containers in httpd.conf it's not a problem and this can copy the custom php.ini file and make the changes to it.

    but i can't do this each and every time a new account is created! this is to exhaustive.

    so what i am asking about here .. is it the right way to achieve my goal? "still make open_basedir directive effective under suphp"

    and if yes then how do i get whm to trigger a script whenever new account is created. i will write this script so it does copy php.ini and change open_basedir to point to the user's home directory so basedir restriction be in effect.

    or there's another way to do it?
    thanks in advance

  2. #2
    Member
    Join Date
    Feb 2010
    Posts
    20

    Default

    i should have noticed that cPanel will try to execute /scripts/postwwwacct if it exists

    thanks anyway

Similar Threads & Tags
Similar threads

  1. Execute Script after a Mail Account or Forwarder is created
    By CoolMike in forum cPanel Developers
    Replies: 0
    Last Post: 07-16-2010, 01:43 AM
  2. script to run when account created
    By kbuser in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 03-11-2009, 01:47 AM
  3. run script after domain is added/account created
    By izghitu in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 12-10-2007, 12:29 PM
  4. Example External account add/remove php script
    By tw12lve in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 11-27-2006, 03:49 AM
  5. Ftp account created with a php script
    By lucasmd in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 04-23-2006, 04:20 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube