Re: Fwd: Reg: Reusing common configurations in main.cf config file in a multiple Postfix instances setup
On Wed, Jul 15, 2009 at 12:43:37PM -0700, Priyanka Tyagi wrote: Hello, I am running three Postfix instances (Postfix version - 2.6.2) on a single host. I have separate postfix configuration files (main.cf and master.cf) specific to each instance. I have most of the configurations common in all of the instances. I want to put all common configurations in one file, and each instance should include configuration details from common file + specific configuration to that particular instance like data_directory etc. Does Postfix -2.6.2 support such resue of common configurations? Use make(1) to machine-construct your main.cf files in such a way that the common files are stored and edited just once. Postfix does not attempt to solve this problem, because it is solved by other existing tools. -- Viktor. Disclaimer: off-list followups get on-list replies or get ignored. Please do not ignore the Reply-To header. To unsubscribe from the postfix-users list, visit http://www.postfix.org/lists.html or click the link below: mailto:majord...@postfix.org?body=unsubscribe%20postfix-users If my response solves your problem, the best way to thank me is to not send an it worked, thanks follow-up. If you must respond, please put It worked, thanks in the Subject so I can delete these quickly.
Re: Fwd: Reg: Reusing common configurations in main.cf config file in a multiple Postfix instances setup
Priyanka Tyagi: Hello, I am running three Postfix instances (Postfix version - 2.6.2) on a single host. I have separate postfix configuration files (main.cf and master.cf) specific to each instance. I have most of the configurations common in all of the instances. I want to put all common configurations in one file, and each instance should include configuration details from common file + specific configuration to that particular instance like data_directory etc. Does Postfix -2.6.2 support such resue of common configurations? Please let me know if you need any other details. Here is a complete example of how to maintain multiple main.cf files that share common content. Contents of /etc/postfix-shared/makefile: = /etc/postfix1/main.cf: /etc/postfix-shared/main.cf main.cf-private cat /etc/postfix-shared/main.cf main.cf-private /etc/postfix1/main.cf postfix -c /etc/postfix1 reload /etc/postfix2/main.cf: /etc/postfix-shared/main.cf main.cf-private cat /etc/postfix-shared/main.cf main.cf-private /etc/postfix2/main.cf postfix -c /etc/postfix2 reload Command to update Postfix: == $ cd /etc/postfix-shared $ vi main.cf $ make More details in the make(1) manpage. It is available since 1976 or so. Wietse
Re: Fwd: Reg: Reusing common configurations in main.cf config file in a multiple Postfix instances setup
Wietse Venema: Wietse Venema: Priyanka Tyagi: Hello, I am running three Postfix instances (Postfix version - 2.6.2) on a single host. I have separate postfix configuration files (main.cf and master.cf) specific to each instance. I have most of the configurations common in all of the instances. I want to put all common configurations in one file, and each instance should include configuration details from common file + specific configuration to that particular instance like data_directory etc. Does Postfix -2.6.2 support such resue of common configurations? Please let me know if you need any other details. Here is a complete example of how to maintain multiple main.cf files that share common content. One missing line added below (first line in the makefile). OK, third and final attempt. Wietse Contents of /etc/postfix-shared/makefile: = POSTFIX1= /etc/postfix1 POSTFIX2= /etc/postfix2 COMMON = /etc/postfix-common all:$(POSTFIX1)/main.cf $(POSTFIX2)/main.cf $(POSTFIX1)/main.cf: $(COMMON)/main.cf $(POSTFIX1)/main.cf-private cat $(COMMON)/main.cf $(POSTFIX1)/main.cf-private $(POSTFIX1)/main.cf postfix -c $(POSTFIX1) reload $(POSTFIX2)/main.cf: $(COMMON)/main.cf $(POSTFIX2)/main.cf-private cat $(COMMON)/main.cf $(POSTFIX2)/main.cf-private $(POSTFIX2)/main.cf postfix -c $(POSTFIX2) reload Commands to update multiple Postfix main.cf files: == $ cd /etc/postfix-common $ vi main.cf $ make More details in the make(1) manpage. It is available since 1976 or so. Wietse