monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: monit *.conf files


From: Martin Pala
Subject: Re: monit *.conf files
Date: Thu, 5 Jan 2012 12:34:45 +0100

Hi,

there is no such option in Monit. If you need to load the variables when 
starting some process (or exec action), you can wrap the start/stop program for 
example like this:

    start program = "/bin/bash -c '. /etc/machine.env; …'"

If you want to use the variables to reuse some configuration template which 
loads machine-specific options from the env file, then it cannot be done via 
monit directly, but you'll need to generate the configuration from the template 
externally (using for example custom Makefile).

Regards,
Martin


On Jan 5, 2012, at 11:32 AM, Alon Lahav wrote:

> Hi,
> 
> I would like to use variables in my conf files.
> The variables should get the data from a file
> in bash the setting look like: env=`cat /etc/machine.env` 
> and the variable usage is done like $env
> 
> Can you please guide me how to do it in?
> 
> -- 
> alon
> --
> To unsubscribe:
> https://lists.nongnu.org/mailman/listinfo/monit-general




reply via email to

[Prev in Thread] Current Thread [Next in Thread]