Results 1 to 3 of 3

Thread: [SOLVED] Tricky situation

  1. #1
    Join Date
    Feb 2006
    Posts
    7
    Rep Power
    11

    Default [SOLVED] Tricky situation

    I have a server connected to my zimbra server running a php web app. I have been able to automate a script t add users to zimbra but of course there's the problem of permissions because the zimbra cli requires you to be logged as as user zimbra. so there is my problem. I need to be able to update new users as they signup to our web app on a server attached to zimbra. Any suggestions?
    Last edited by iomari; 02-04-2008 at 02:10 PM.
    If I want any crap out of you, I'll squeeze your head.

  2. #2
    Join Date
    Mar 2007
    Location
    Austin
    Posts
    441
    Rep Power
    10

    Default

    I've got an internal web box set up with SSH keys to get the zimbra user to run commands. I scp over scripts, and run them.

  3. #3
    Join Date
    Feb 2006
    Posts
    7
    Rep Power
    11

    Default

    Quote Originally Posted by p24t View Post
    I've got an internal web box set up with SSH keys to get the zimbra user to run commands. I scp over scripts, and run them.
    That's exactly what I did. Check this out:

    in my sudoers file on my non zimbra server I entered:
    wwwrun myhostname = NOPASSWD: /usr/bin/ssh

    then on my php script:
    echo "<div align=\"center\"><font face=\"verdana\" size=\"4\"><b>Please wait while I update mail account.....</b></font></div>" ;
    $mstring = " $ADD_username1@mydomain $ADD_password1" ;
    $mresult = `sudo ssh zimbra@mail_server zmprov ca $mstring`;



    and it's all cool.


    Of course I already generated my keys for passwordless access.
    If I want any crap out of you, I'll squeeze your head.

Similar Threads

  1. OSS vs. Network - Different situation
    By dwill in forum Developers
    Replies: 21
    Last Post: 08-31-2010, 01:56 PM
  2. My Situation
    By afterwego in forum Installation
    Replies: 3
    Last Post: 03-29-2007, 02:09 PM
  3. Will Zimlet help me in this situation?
    By harshalx in forum Zimlets
    Replies: 3
    Last Post: 03-05-2007, 10:38 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •