FAQ
Hi --

My mailman URL and from header are not consistent. I could us a bit of
help and clarification of the virtualhost config.

The issue:
I want emails to look as though they are coming from the virtual hosts
address (lists.domain.com). However the from address says
From: list at realhostname.domain.com.

The body of the does message has the proper URLs
(https://lists.domain.com/)


Here is what I've done.
I've added the following to mm_cfg.py

add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
OWNERS_CAN_ENABLE_PERSONALIZATION = 1
DEFAULT_EMAIL_HOST = 'lists.domain.com'
DEFAULT_URL_HOST = 'lists.domain.com'
DEFAULT_URL_PATTERN = 'https://%s/mailman/'


In my Defaults.py (I may have changed this from what was originally
there [shoot first aim later]


# If you don't need to change DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
your
# mm_cfg.py, then you're done; the default mapping is added
automatically. If
# however you change either variable in your mm_cfg.py, then be sure to
also
# include the following:
#
# add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
#
# because otherwise the default mappings won't be correct.
DEFAULT_EMAIL_HOST = 'lists.domain.com'
DEFAULT_URL_HOST = 'lists.domain.com'
DEFAULT_URL_PATTERN = 'http://%s/mailman/'




From the INSTALL file:
----------------------------------------------------------
- Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
Defaults.py. Make any necessary changes in the mm_cfg.py file.
Note that if you change either of these two values, you'll want
to add the following afterwards in the mm_cfg.py file:

add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)





--
Bradley Glonka <bradley at pistonbroke.com>

Search Discussions

  • Todd at Jul 19, 2003 at 4:41 pm

    Bradley Glonka wrote:
    I want emails to look as though they are coming from the virtual hosts
    address (lists.domain.com). However the from address says
    From: list at realhostname.domain.com. [...]
    I've added the following to mm_cfg.py

    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/' [...]
    From the INSTALL file:
    ----------------------------------------------------------
    - Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
    Defaults.py. Make any necessary changes in the mm_cfg.py file.
    Note that if you change either of these two values, you'll want
    to add the following afterwards in the mm_cfg.py file:
    ^^^^^^^^^^
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    I could be wrong (and I could just still be asleep), but I believe you want
    to move the add_virtualhost line *below* the the DEFAULT_*_HOST settings.
    And then be sure to restart the mailmanctl daemon.

    - --
    Todd OpenPGP -> KeyID: 0xD654075A | URL: www.pobox.com/~tmz/pgp
    ===========================================================================If you don't drink, smoke, or drive a car, you're a tax evader.
    -- Rep. Thomas S. Foley, 1990
  • Bradley Glonka at Jul 19, 2003 at 5:02 pm

    Bradley Glonka wrote:
    I want emails to look as though they are coming from the virtual hosts
    address (lists.domain.com). However the from address says
    From: list at realhostname.domain.com. [...]
    I've added the following to mm_cfg.py

    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/' [...]
    From the INSTALL file:
    ----------------------------------------------------------
    - Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
    Defaults.py. Make any necessary changes in the mm_cfg.py file.
    Note that if you change either of these two values, you'll want
    to add the following afterwards in the mm_cfg.py file:
    ^^^^^^^^^^
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    I could be wrong (and I could just still be asleep), but I believe you want
    to move the add_virtualhost line *below* the the DEFAULT_*_HOST settings.
    And then be sure to restart the mailmanctl daemon.
    No Luck!!
    I'm wondering if I'm using add_virtualhost incorrectly?
    Maybe its usage is:
    add_virtualhost('lists.domain.com', 'lists.domains.com')
    ????

    OR maybe this is a function of Sendmail? (I don't think so) I'm using a default
    Red Hat config of sendmail.

    Or maybe the add_virtualhost needs to be in the Default.py?

    --
  • Richard Barrett at Jul 19, 2003 at 8:01 pm
    There is a FAQ entry on thius topic. As it points out, changing things
    in mm_cfg.pyt will not affect existing lists. For that you need to run
    fix_url.py; see the FAQ entry:

    http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq04.029.htp
    On Saturday, July 19, 2003, at 05:57 PM, Bradley Glonka wrote:

    Bradley Glonka wrote:
    I want emails to look as though they are coming from the virtual
    hosts
    address (lists.domain.com). However the from address says
    From: list at realhostname.domain.com. [...]
    I've added the following to mm_cfg.py

    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/' [...]
    From the INSTALL file:
    ----------------------------------------------------------
    - Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
    Defaults.py. Make any necessary changes in the mm_cfg.py file.
    Note that if you change either of these two values, you'll want
    to add the following afterwards in the mm_cfg.py file:
    ^^^^^^^^^^
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    I could be wrong (and I could just still be asleep), but I believe
    you want
    to move the add_virtualhost line *below* the the DEFAULT_*_HOST
    settings.
    And then be sure to restart the mailmanctl daemon.
    No Luck!!
    I'm wondering if I'm using add_virtualhost incorrectly?
    Maybe its usage is:
    add_virtualhost('lists.domain.com', 'lists.domains.com')
    ????

    OR maybe this is a function of Sendmail? (I don't think so) I'm using
    a default
    Red Hat config of sendmail.

    Or maybe the add_virtualhost needs to be in the Default.py?

    --
  • Bradley Glonka at Jul 19, 2003 at 8:39 pm
    Thanks for the feedback but my problem is not trying to change a list.
    Things are set as I mentioned below and I've restarted mailman. My from
    address is still showing as realhost.domain.com Isn't it the purpose
    of add_virtualhost to make the From: line some other value? Is there a
    doc that says how to use add_virtualhost?

    I've even tried creating the list like
    bin/newlist listname at lists.domain.com <--- This didn't help


    mm_cfg.py:
    ---------------------------------------------
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/'
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    DEFAULT_HOST_NAME = 'lists.domain.com'


    Defaults.py
    ---------------------------------------------
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'http://%s/mailman/'





    Thanks
    Brad


    There is a FAQ entry on thius topic. As it points out, changing things
    in mm_cfg.pyt will not affect existing lists. For that you need to run
    fix_url.py; see the FAQ entry:

    http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq04.029.htp
    On Saturday, July 19, 2003, at 05:57 PM, Bradley Glonka wrote:

    Bradley Glonka wrote:
    I want emails to look as though they are coming from the virtual
    hosts
    address (lists.domain.com). However the from address says
    From: list at realhostname.domain.com. [...]
    I've added the following to mm_cfg.py

    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/' [...]
    From the INSTALL file:
    ----------------------------------------------------------
    - Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
    Defaults.py. Make any necessary changes in the mm_cfg.py file.
    Note that if you change either of these two values, you'll want
    to add the following afterwards in the mm_cfg.py file:
    ^^^^^^^^^^
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    I could be wrong (and I could just still be asleep), but I believe
    you want
    to move the add_virtualhost line *below* the the DEFAULT_*_HOST
    settings.
    And then be sure to restart the mailmanctl daemon.
    No Luck!!
    I'm wondering if I'm using add_virtualhost incorrectly?
    Maybe its usage is:
    add_virtualhost('lists.domain.com', 'lists.domains.com')
    ????

    OR maybe this is a function of Sendmail? (I don't think so) I'm using
    a default
    Red Hat config of sendmail.

    Or maybe the add_virtualhost needs to be in the Default.py?

    --
    --
    Bradley Glonka <bradley at pistonbroke.com>
  • Thomas Schröer at Jul 20, 2003 at 10:24 am
    Hello,

    I had a similar problem, even though the other way around (I wanted to have
    the realhost "adr at host.domain.tld", but got only "adr at domain.tld"). Anyway,
    in my case it was a "sendmail" problem. "sendmail" can be configured to
    "masquerade" the host/domain, so that in every outgoing mail the address
    is replaced by the setting of this option. Because "mailman" is delivering
    any mail to the MTA (i. e. "sendmail"), this setting supersedes everything
    that mailman is configured for.

    As soon as I fixed this setting of sendmail, I got what I wanted as "From:"
    address.

    HTH

    Tom

    Bradley Glonka wrote:
    Thanks for the feedback but my problem is not trying to change a list.
    Things are set as I mentioned below and I've restarted mailman. My from
    address is still showing as realhost.domain.com Isn't it the purpose
    of add_virtualhost to make the From: line some other value? Is there a
    doc that says how to use add_virtualhost?

    I've even tried creating the list like
    bin/newlist listname at lists.domain.com <--- This didn't help


    mm_cfg.py:
    ---------------------------------------------
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/'
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    DEFAULT_HOST_NAME = 'lists.domain.com'


    Defaults.py
    ---------------------------------------------
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'http://%s/mailman/'





    Thanks
    Brad



    There is a FAQ entry on thius topic. As it points out, changing things
    in mm_cfg.pyt will not affect existing lists. For that you need to run
    fix_url.py; see the FAQ entry:

    http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq04.029.htp

    On Saturday, July 19, 2003, at 05:57 PM, Bradley Glonka wrote:

    Bradley Glonka wrote:
    I want emails to look as though they are coming from the virtual
    hosts
    address (lists.domain.com). However the from address says
    From: list at realhostname.domain.com. [...]
    I've added the following to mm_cfg.py

    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    OWNERS_CAN_ENABLE_PERSONALIZATION = 1
    DEFAULT_EMAIL_HOST = 'lists.domain.com'
    DEFAULT_URL_HOST = 'lists.domain.com'
    DEFAULT_URL_PATTERN = 'https://%s/mailman/' [...]
    From the INSTALL file:
    ----------------------------------------------------------
    - Check the values for DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST in
    Defaults.py. Make any necessary changes in the mm_cfg.py file.
    Note that if you change either of these two values, you'll want
    to add the following afterwards in the mm_cfg.py file:
    ^^^^^^^^^^
    add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
    I could be wrong (and I could just still be asleep), but I believe
    you want
    to move the add_virtualhost line *below* the the DEFAULT_*_HOST
    settings.
    And then be sure to restart the mailmanctl daemon.
    No Luck!!
    I'm wondering if I'm using add_virtualhost incorrectly?
    Maybe its usage is:
    add_virtualhost('lists.domain.com', 'lists.domains.com')
    ????

    OR maybe this is a function of Sendmail? (I don't think so) I'm using
    a default
    Red Hat config of sendmail.

    Or maybe the add_virtualhost needs to be in the Default.py?

    --

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupmailman-users @
categoriespython
postedJul 19, '03 at 2:46p
activeJul 20, '03 at 10:24a
posts6
users4
websitelist.org

People

Translate

site design / logo © 2022 Grokbase