Discussion:
Custom startup scripts
Joe Laffey
2007-10-24 13:42:01 UTC
Permalink
Where is a safe place to put custom startup script that can be run at boot
time, and will not be wiped by future updates to pfsense?

Thanks,

--
Joe Laffey | Visual Effects for Film and Video
LAFFEY Computer Imaging | -------------------------------------
St. Louis, MO | Show Reel http://LAFFEY.tv/?e07510
USA | -------------------------------------
. | -*- Digital Fusion Plugins -*-
--------------------------------------------------------------------------
Mail here will be rejected --> "Real Trap" <r_trap-***@public.gmane.org>
Scott Ullrich
2007-10-24 15:50:24 UTC
Permalink
Post by Joe Laffey
Where is a safe place to put custom startup script that can be run at boot
time, and will not be wiped by future updates to pfsense?
Create a script in /usr/local/etc/rc.d/

Example:

/usr/local/etc/rc.d/startup.sh

Be sure the script is a+x and that it ends in .sh to run.

Scott
Joe Laffey
2007-10-24 18:35:51 UTC
Permalink
Post by Scott Ullrich
Post by Joe Laffey
Where is a safe place to put custom startup script that can be run at boot
time, and will not be wiped by future updates to pfsense?
Create a script in /usr/local/etc/rc.d/
/usr/local/etc/rc.d/startup.sh
Be sure the script is a+x and that it ends in .sh to run.
I shall give it a shot.

Thanks!

--
Joe Laffey | Visual Effects for Film and Video
LAFFEY Computer Imaging | -------------------------------------
St. Louis, MO | Show Reel http://LAFFEY.tv/?e07514
USA | -------------------------------------
. | -*- Digital Fusion Plugins -*-
--------------------------------------------------------------------------
Mail here will be rejected --> "Real Trap" <r_trap-***@public.gmane.org>
Tortise
2007-10-26 08:05:07 UTC
Permalink
Can this be done via the xml to be truly portable?

Kind regards David

----- Original Message -----
From: "Joe Laffey" <joe-***@public.gmane.org>
To: <support-***@public.gmane.org>
Sent: Thursday, October 25, 2007 7:35 AM
Subject: Re: [pfSense Support] Custom startup scripts
Post by Scott Ullrich
Post by Joe Laffey
Where is a safe place to put custom startup script that can be run at boot
time, and will not be wiped by future updates to pfsense?
Create a script in /usr/local/etc/rc.d/
/usr/local/etc/rc.d/startup.sh
Be sure the script is a+x and that it ends in .sh to run.
I shall give it a shot.

Thanks!

--
Joe Laffey | Visual Effects for Film and Video
LAFFEY Computer Imaging | -------------------------------------
St. Louis, MO | Show Reel http://LAFFEY.tv/?e07514
USA | -------------------------------------
. | -*- Digital Fusion Plugins -*-
--------------------------------------------------------------------------
Mail here will be rejected --> "Real Trap" <r_trap-***@public.gmane.org>

---------------------------------------------------------------------
To unsubscribe, e-mail: support-unsubscribe-***@public.gmane.org
For additional commands, e-mail: support-help-***@public.gmane.org
Chris Daniel
2007-10-26 13:39:06 UTC
Permalink
You can't make init scripts in the XML config file, no. I don't think
it's quite within the scope of a configuration file to store scripts,
anyway. But if you have something you want to be run on boot, use
<shellcmd> and <earlyshellcmd>.
Post by Tortise
Can this be done via the xml to be truly portable?
Kind regards David
----- Original Message -----
Sent: Thursday, October 25, 2007 7:35 AM
Subject: Re: [pfSense Support] Custom startup scripts
Post by Scott Ullrich
Post by Joe Laffey
Where is a safe place to put custom startup script that can be run at boot
time, and will not be wiped by future updates to pfsense?
Create a script in /usr/local/etc/rc.d/
/usr/local/etc/rc.d/startup.sh
Be sure the script is a+x and that it ends in .sh to run.
I shall give it a shot.
Thanks!
--
Joe Laffey | Visual Effects for Film and Video
LAFFEY Computer Imaging | -------------------------------------
St. Louis, MO | Show Reel http://LAFFEY.tv/?e07514
USA | -------------------------------------
. | -*- Digital Fusion Plugins -*-
--------------------------------------------------------------------------
---------------------------------------------------------------------
---------------------------------------------------------------------
Bill Marquette
2007-10-26 14:06:46 UTC
Permalink
Post by Chris Daniel
You can't make init scripts in the XML config file, no. I don't think
it's quite within the scope of a configuration file to store scripts,
anyway. But if you have something you want to be run on boot, use
<shellcmd> and <earlyshellcmd>.
Don't forget it's XML and needs to have html entities escaped (>
become &gt;) else you'll blow up your config file rather
spectacularly. rm /tmp/config.cache after editing also, else you'll
likely get your changes overwritten from cache.

--Bill

Loading...