Filename in main.cf, specifically myorigin = /etc/mailname

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Filename in main.cf, specifically myorigin = /etc/mailname

Chris Green-11
Is the use of a filename in main.cf possible for any parameter or is
it only applicable to myorigin (or just to a few)?

I notice that installing postfix on my laptop from the Ubuntu
repositories has set myorigin = /etc/mailname in main.cf.

This is handy in relation to my 'how to synchronise configurations'
question as one can set myorigin = /etc/mailname in every system and
just set /etc/mailname to the required name on each system.  

I couldn't find any reference to this (use of a file) in man 5 postconf.

--
Chris Green
Reply | Threaded
Open this post in threaded view
|

Re: Filename in main.cf, specifically myorigin = /etc/mailname

Wietse Venema
Chris Green:

> Is the use of a filename in main.cf possible for any parameter or is
> it only applicable to myorigin (or just to a few)?
>
> I notice that installing postfix on my laptop from the Ubuntu
> repositories has set myorigin = /etc/mailname in main.cf.
>
> This is handy in relation to my 'how to synchronise configurations'
> question as one can set myorigin = /etc/mailname in every system and
> just set /etc/mailname to the required name on each system.  
>
> I couldn't find any reference to this (use of a file) in man 5 postconf.

That's a DEBIAN-specific feature.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: Filename in main.cf, specifically myorigin = /etc/mailname

Matus UHLAR - fantomas
>Chris Green:
>> Is the use of a filename in main.cf possible for any parameter or is
>> it only applicable to myorigin (or just to a few)?
>>
>> I notice that installing postfix on my laptop from the Ubuntu
>> repositories has set myorigin = /etc/mailname in main.cf.
>>
>> This is handy in relation to my 'how to synchronise configurations'
>> question as one can set myorigin = /etc/mailname in every system and
>> just set /etc/mailname to the required name on each system.
>>
>> I couldn't find any reference to this (use of a file) in man 5 postconf.

On 06.12.20 12:10, Wietse Venema wrote:
>That's a DEBIAN-specific feature.

but debian-specific is only the defaut value, postfix support /file/name for myorigin by
default, correct?

looking at sources, it does for some time:

src/global/mail_params.c as to be build with MYORIGIN_FROM_FILE set:

#ifdef MYORIGIN_FROM_FILE
    if (*var_myorigin == '/') {
        char   *origin = read_param_from_file(var_myorigin);

        if (*origin == 0)
            msg_fatal("%s file %s is empty", VAR_MYORIGIN, var_myorigin);
        myfree(var_myorigin);                   /* FIX 20070501 */
        var_myorigin = origin;
    }
#endif


--
Matus UHLAR - fantomas, [hidden email] ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Saving Private Ryan...
Private Ryan exists. Overwrite? (Y/N)
Reply | Threaded
Open this post in threaded view
|

Re: Filename in main.cf, specifically myorigin = /etc/mailname

Wietse Venema
Matus UHLAR - fantomas:

> >Chris Green:
> >> Is the use of a filename in main.cf possible for any parameter or is
> >> it only applicable to myorigin (or just to a few)?
> >>
> >> I notice that installing postfix on my laptop from the Ubuntu
> >> repositories has set myorigin = /etc/mailname in main.cf.
> >>
> >> This is handy in relation to my 'how to synchronise configurations'
> >> question as one can set myorigin = /etc/mailname in every system and
> >> just set /etc/mailname to the required name on each system.
> >>
> >> I couldn't find any reference to this (use of a file) in man 5 postconf.
>
> On 06.12.20 12:10, Wietse Venema wrote:
> >That's a DEBIAN-specific feature.
>
> but debian-specific is only the defaut value, postfix support
> /file/name for myorigin by default, correct?

THIS CODE is NOT COMPILED IN by default.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: Filename in main.cf, specifically myorigin = /etc/mailname

Matus UHLAR - fantomas
>> >Chris Green:
>> >> Is the use of a filename in main.cf possible for any parameter or is
>> >> it only applicable to myorigin (or just to a few)?
>> >>
>> >> I notice that installing postfix on my laptop from the Ubuntu
>> >> repositories has set myorigin = /etc/mailname in main.cf.
>> >>
>> >> This is handy in relation to my 'how to synchronise configurations'
>> >> question as one can set myorigin = /etc/mailname in every system and
>> >> just set /etc/mailname to the required name on each system.
>> >>
>> >> I couldn't find any reference to this (use of a file) in man 5 postconf.

>> On 06.12.20 12:10, Wietse Venema wrote:
>> >That's a DEBIAN-specific feature.

>Matus UHLAR - fantomas:
>> but debian-specific is only the defaut value, postfix support
>> /file/name for myorigin by default, correct?

On 22.12.20 10:30, Wietse Venema wrote:
>THIS CODE is NOT COMPILED IN by default.

this is the best explanation, thanks.

--
Matus UHLAR - fantomas, [hidden email] ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Atheism is a non-prophet organization.