AW: AW: AW: Custom quota exeed message

rudolf at padaru.de rudolf at padaru.de
Wed Feb 3 13:55:55 EET 2021


That works,

i take my hat off, thx mr Tuomi!

Mit freundlichen Grüßen
Yours sincerely 
Pascal Rudolf 



-----Ursprüngliche Nachricht-----
Von: dovecot <dovecot-bounces at dovecot.org> Im Auftrag von Aki Tuomi
Gesendet: Mittwoch, 3. Februar 2021 12:49
An: rudolf at padaru.de; dovecot mailing list <dovecot at dovecot.org>
Betreff: Re: AW: AW: Custom quota exeed message

You should maybe check that 

doveadm user user at name

produces correct output. Also, you might need to use %{userdb:mail_address} there.

Aki

> On 03/02/2021 13:47 rudolf at padaru.de wrote:
> 
>  
> Thx for response, now i have another question.. sry..
> 
> I´ve already tryed to create an custom variable with an new db field but i struggle there..
> 
> Now i have append my database with the column "mail_address" which 
> contains the real mail-adress, like peter.schmidt at schmidt.com
> 
> I select this value with my user_query and define an variable "mail_adress" with an userdb entry in the config:
> 
> userdb {
>        [...]
>         override_fields = mail_address=mail_address }
> 
> But if now some user login i become the message:
> 
> Error: Failed to expand plugin setting quota_exceeded_message = 'my Message and Domain: %{mail_address}': Unknown variable '%mail_address'
> 
> My quota plugin config:
> 
> plugin {
>     [...] 
>     quota_exceeded_message="my Message and Domain: %{mail_address}"
> }
> 
> whats the correct way to define an userdb variable? I have read alot about but dont yet understood, seemingly..
> 
> Mit freundlichen Grüßen
> Yours sincerely
> Pascal Rudolf
> 
> 
> 
> -----Ursprüngliche Nachricht-----
> Von: dovecot <dovecot-bounces at dovecot.org> Im Auftrag von Aki Tuomi
> Gesendet: Mittwoch, 3. Februar 2021 12:16
> An: rudolf at padaru.de; dovecot mailing list <dovecot at dovecot.org>
> Betreff: Re: AW: Custom quota exeed message
> 
> You can try putting %{correct_email_address} as expansion to the message, and making sure you set this in userdb.
> 
> Aki
> 
> > On 03/02/2021 13:13 rudolf at padaru.de wrote:
> > 
> >  
> > Thanks fort he answer, so know somebody if there is an way to manipulate the first line oft he message? Ist important for us, that the sender from the mail see the correct mail-adresse where he send the mail, and no internal user and servername.
> > 
> > Mit freundlichen Grüßen
> > Yours sincerely
> > 
> > 
> > Pascal Rudolf
> > 
> > 
> > -----Ursprüngliche Nachricht-----
> > Von: dovecot <dovecot-bounces at dovecot.org> Im Auftrag von Aki Tuomi
> > Gesendet: Mittwoch, 3. Februar 2021 08:00
> > An: rudolf at padaru.de; dovecot mailing list <dovecot at dovecot.org>
> > Betreff: Re: Custom quota exeed message
> > 
> > 
> > > On 02/02/2021 11:29 rudolf at padaru.de wrote:
> > > 
> > > 
> > > Hey there,
> > > 
> > > i need some help with custom quota messages with dovecot and postfix.
> > > 
> > > The quota setup is clear and easy, now i want to manipulate the exceed message, which is generated, if the mailbox is full.
> > > 
> > > Now i got something like that
> > > 
> > > Your message to <user at my.server.com> was automatically discarded:
> > > Quota exceeded (mailbox for user is full)
> > > 
> > > The first line – so i think – is generated from postfix and cant be edit or? The second line is generatet from dovecot and i can manipulate there with the „quota_exceeded_message“ variable.
> > > 
> > > My problem is, that the sender cant see the mail-adress where he originally send the mail. Because the ‚user‘ is an local user on my server. I need somethin like that:
> > > 
> > > 
> > > Your message to <peter.schmidt at schmidt.com> was automatically discarded:
> > > Quota exceeded (mailbox for user is full)
> > > 
> > > 
> > > Is there an way to manipulate the first line of answer?
> > > 
> > > Ori s there an way, that i can run a custom script in the „quota_exceeded_message“ var? With the latter variant i would be able to create something like:
> > > 
> > > Your message to <user at my.server.com> was automatically discarded:
> > > Quota exceeded (mailbox for user <peter.schmidt at schmidt.com> is 
> > > full)
> > > 
> > > 
> > > But configurations like „quota_exceeded_message = script /my/script.sh“ wont execute the script.
> > > 
> > > Does anybody have an idea?
> > > 
> > > Mit freundlichen Grüßen
> > > Yours sincerely
> > > Pascal Rudolf
> > 
> > Script is not supported, sorry. It is a static message which is read at startup.
> > 
> > Aki




More information about the dovecot mailing list