The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Want to add code to the CreateNewUser script. (cp /root/.bashrc $homedir, etc.)

Discussion in 'General Discussion' started by DudeBro, Mar 26, 2004.

  1. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    I want to add the following 2 lines:

    Can someone please tell me how I can manage this? I need to add this to the CreateAnAccount(/ADDUSER) script in WHM... Where is this script located... etc.
     
  2. elleryjh

    elleryjh Well-Known Member

    Joined:
    Apr 12, 2003
    Messages:
    479
    Likes Received:
    0
    Trophy Points:
    16
    Why not just add them to /root/cpanel3-skel/



    If you must, the script is /scripts/wwwacct, but that is updated frequently so you'll have to edit it a lot.
     
  3. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    what is /root/cpanel3-skel/? Where do I put it?
     
  4. elleryjh

    elleryjh Well-Known Member

    Joined:
    Apr 12, 2003
    Messages:
    479
    Likes Received:
    0
    Trophy Points:
    16
    /root/cpanel3-skel/ is the directory that is copied for every new user.


    If you are a reseller, then you can use /home/resellername/cpanel3-skel/
     
  5. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    OK. What do I change in there?

     
  6. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    Do i just copy the bashrc and everything in there?
     
  7. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    OK! :) GOT IT TO WORK.. THX A LOT!
     
  8. elleryjh

    elleryjh Well-Known Member

    Joined:
    Apr 12, 2003
    Messages:
    479
    Likes Received:
    0
    Trophy Points:
    16
    for the record, you could also make a script /scripts/postwwwacct that will run after account creation is complete.
     
  9. DudeBro

    DudeBro Well-Known Member

    Joined:
    Jan 30, 2004
    Messages:
    51
    Likes Received:
    0
    Trophy Points:
    6
    is that a /dir, or do I make it??
     
  10. elleryjh

    elleryjh Well-Known Member

    Joined:
    Apr 12, 2003
    Messages:
    479
    Likes Received:
    0
    Trophy Points:
    16
    no, you would make the script /scripts/postwwwacct, which is run every time a new user is created.

    It can be perl, php, shell, etc.

    If you just want to have those files in new users' dirs, then it's much easier to put them in /root/cpanel3-skel/
     
Loading...

Share This Page