From a0ac69006528da13a602d4f0c1bf7ec96bdfa9ae Mon Sep 17 00:00:00 2001 From: Daniel Stefan Haischt Date: Tue, 15 Aug 2006 20:45:17 +0000 Subject: added rc.freenas as a replacement for the original FreeNAS rc.bootup --- packages/freenas/pkg/freenas.inc | 6 ++++++ packages/freenas/pkg/freenas.xml | 5 +++++ packages/freenas/pkg/freenas_functions.inc | 1 + packages/freenas/pkg/freenas_system.inc | 2 ++ 4 files changed, 14 insertions(+) (limited to 'packages/freenas/pkg') diff --git a/packages/freenas/pkg/freenas.inc b/packages/freenas/pkg/freenas.inc index b95aa90b..4b21879f 100644 --- a/packages/freenas/pkg/freenas.inc +++ b/packages/freenas/pkg/freenas.inc @@ -193,6 +193,12 @@ function custom_php_install_command() { oninstall_copy_misc_binaries(); adjust_package_contents(); oninstall_setup_config(); + + if (! file_exists("/usr/local/etc/rc.d")) + mwexec("mkdir -p /usr/local/etc/rc.d"); + + rename("/usr/local/pkg/rc.freenas", "/usr/local/etc/rc.d/rc.freenas"); + chmod ("/usr/local/etc/rc.d/rc.freenas", 0755); } function custom_php_deinstall_command() { diff --git a/packages/freenas/pkg/freenas.xml b/packages/freenas/pkg/freenas.xml index ef90cf2b..881c9881 100644 --- a/packages/freenas/pkg/freenas.xml +++ b/packages/freenas/pkg/freenas.xml @@ -274,6 +274,11 @@ 0755 http://www.pfsense.com/packages/config/freenas/pkg/freenas_utils.inc + + /usr/local/pkg/ + 0755 + http://www.pfsense.com/packages/config/freenas/pkg/rc.freenas + /usr/local/pkg/ diff --git a/packages/freenas/pkg/freenas_functions.inc b/packages/freenas/pkg/freenas_functions.inc index e5ca52e3..77980ea9 100644 --- a/packages/freenas/pkg/freenas_functions.inc +++ b/packages/freenas/pkg/freenas_functions.inc @@ -36,4 +36,5 @@ require_once ("freenas_disks.inc"); require_once ("freenas_utils.inc"); require_once ("freenas_services.inc"); require_once ("freenas_system.inc"); + ?> \ No newline at end of file diff --git a/packages/freenas/pkg/freenas_system.inc b/packages/freenas/pkg/freenas_system.inc index 89c210e2..f3da6aa4 100644 --- a/packages/freenas/pkg/freenas_system.inc +++ b/packages/freenas/pkg/freenas_system.inc @@ -30,6 +30,8 @@ POSSIBILITY OF SUCH DAMAGE. */ +require_once("globals.inc"); + $freenas_config =& $config['installedpackages']['freenas']['config'][0]; function system_do_extensions($early = false) { -- cgit v1.2.3