Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Nov 2018 20:12:05 +0000
From:      Carmel NY <carmel_ny@outlook.com>
To:        FreeBSD <freebsd-questions@freebsd.org>
Subject:   Re: Append to "command" in rec script
Message-ID:  <SN1PR20MB21090B23D17CCEBEC43C428380C50@SN1PR20MB2109.namprd20.prod.outlook.com>
In-Reply-To: <20181108193853.ee1404e2.freebsd@edvax.de>
References:  <SN1PR20MB2109DD8D5387A977F1F550B480C50@SN1PR20MB2109.namprd20.prod.outlook.com> <20181108193853.ee1404e2.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 8 Nov 2018 19:38:53 +0100, Polytropon stated:

>On Thu, 8 Nov 2018 18:13:24 +0000, Carmel NY wrote:
>> I am attempting to create an "rc" script to start a program I am working
>> on. I want, if possible, for the user to enter something in the rc.conf
>> file to be added to the "command" string when the program is started.
>>=20
>> EXAMPLE:
>>=20
>> In the rc script, this is present
>>=20
>> command=3D/usr/local/bin/MyProg
>>=20
>> Now, suppose the user wanted to activate logging. They could modify the =
rc
>> script and append an "-l" to the command string. However, I would rather
>> they entered options in the rc.conf file =20
>
>Maybe read "man 5 rc.conf" and put non-FreeBSD (or at
>least "experimental" stuff) in /etc/rc.conf.local.
>The difference between rc.conf and rc.conf.local is
>not as big in FreeBSD as it is in OpenBSD. ;-)

Actually, man 8 rc.subr is a lot more useful. However, it doesn't give me
what I want. Also, I have been having a problem with "run_rc_command"
chocking on complex startup options placed in the rc.conf file. I am still
trying to debug that one.

--=20
Carmel



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?SN1PR20MB21090B23D17CCEBEC43C428380C50>