Modify

Opened 15 years ago

Closed 15 years ago

#96 closed setup (fixed)

QMail can't use sudo method in documentation

Reported by: sweeney@… Owned by: bas
Priority: major Milestone:
Component: email2trac Version: 0.4
Keywords: Cc:

Description

I'm running email2trac 0.9.40 with Qmail. I've built the application as an rpm package and installed it. My web user is apache and my QMail user is nobody. I've tested the app using the local command line method and it works:

/usr/bin/email2trac --project=info < msg.txt

However, I tried the first method of setting up Qmail and it didn't work. It fails with a return message:

preline: fatal: unable to run /usr/bin/run_email2trac --project=info: file does not exist

I'm assuming that this is the failure noted in the documentation under the Qmail heading:

https://subtrac.sara.nl/oss/email2trac/wiki/Email2tracMta#QmailSetup

And so, I try the optional method. I've added an entry to sudoers:

nobody ALL = (apache)NOPASSWORD: /usr/bin/run_email2trac

and I change the execute command in the mail user's .qmail file to the following:

|PYTHON_EGG_CACHE=/var/trac/tracenv/attachments /var/qmail/bin/preline /usr/bin/sudo -u apache /usr/bin/run_email2trac --project=info

This produces an error:

sudo: sorry, you must have a tty to run sudo

Very frustrating. What am I doing wrong?

Attachments (0)

Change History (5)

comment:1 Changed 15 years ago by bas

  • Status changed from new to assigned
  • Type changed from defect to setup

I am not a qmail expert. We use postfix for our mail servers. Just a question did you adjust the MTA_USER en TRAC_USER in the rpm spec file. because the defaults are :

  • nobody
  • www-data

The apache user is different then the default!, see:

comment:2 Changed 15 years ago by Sweeney, David

I did adjust them both, but I'm not sure that nobody is the MTA_USER.
Is
there a way to tell what the actual MTA_USER is?


--
David Sweeney
sweeney@tamu.edu

-----Original Message-----
From: email2trac [mailto:email2trac@sara.nl]
Sent: Monday, November 03, 2008 3:54 PM
Cc: basv@sara.nl
Subject: Re: [email2trac] #96: QMail can't use sudo method in
documentation

#96: QMail can't use sudo method in documentation
-----------------------------+----------------------------------------
--
-----------------------------+----
Reporter:  sweeney@tamu.edu  |        Owner:  bas
    Type:  setup             |       Status:  assigned
Priority:  major             |    Component:  email2trac
 Version:  0.4               |   Resolution:
Keywords:                    |
-----------------------------+----------------------------------------
--
-----------------------------+----
Changes (by bas):

  * status:  new => assigned
  * type:  defect => setup


Comment:

 I am not a qmail expert. We use postfix for our mail servers. Just a
question did you adjust the MTA_USER en TRAC_USER in the rpm spec
file.
 because the defaults are :
  * nobody
  * www-data

 The apache user is different then the default!, see:
  * https://subtrac.sara.nl/oss/email2trac/wiki/Email2tracInstallation

--
Ticket URL:
<https://subtrac.rc.sara.nl/oss/email2trac/ticket/96#comment:1>
email2trac <https://subtrac.sara.nl/oss/email2trac>
Documentation server for email2trac

comment:3 Changed 15 years ago by bas

You can make a script that redirects its output to a file in /var/tmp/id. Then you know what the id is of your MTA:

#!/bin/sh
id > /var/tmp/id

comment:4 Changed 15 years ago by Sweeney, David

How do I invoke the script?

--
David Sweeney
Sweeney@tamu.edu


-----Original Message-----
From: email2trac [mailto:email2trac@sara.nl]
Sent: Thursday, November 06, 2008 2:06 PM
Cc: basv@sara.nl
Subject: Re: [email2trac] #96: QMail can't use sudo method in
documentation

#96: QMail can't use sudo method in documentation
-----------------------------+----------------------------------------
------
Reporter:  sweeney@tamu.edu  |        Owner:  bas
    Type:  setup             |       Status:  assigned
Priority:  major             |    Component:  email2trac
 Version:  0.4               |   Resolution:
Keywords:                    |
-----------------------------+----------------------------------------
------

Comment(by bas):

 You can make a script that redirects its output to a file in
/var/tmp/id.
 Then you know what the id is of your MTA:
 {{{
 #!/bin/sh
 id > /var/tmp/id
 }}}

comment:5 Changed 15 years ago by bas

  • Resolution set to fixed
  • Status changed from assigned to closed

fixed

Add Comment

Modify Ticket

Change Properties
Action
as closed The owner will remain bas.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.