diff --git a/extra/raptor/config.factor b/extra/raptor/config.factor index ecdbf98f17..29e26d4381 100644 --- a/extra/raptor/config.factor +++ b/extra/raptor/config.factor @@ -44,7 +44,10 @@ IN: raptor ! rcS.d "mountvirtfs" start-service - "hostname.sh" start-service + + ! "hostname.sh" start-service + "narodnik" set-hostname + "keymap.sh" start-service "linux-restricted-modules-common" start-service "udev" start-service diff --git a/extra/raptor/cronjobs.factor b/extra/raptor/cronjobs.factor index 894e8e5ce7..91263a31d9 100644 --- a/extra/raptor/cronjobs.factor +++ b/extra/raptor/cronjobs.factor @@ -6,8 +6,6 @@ IN: raptor ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -: fork-exec-args-wait ( args -- ) [ first ] [ ] bi fork-exec-wait ; - : run-script ( path -- ) 1array [ fork-exec-args-wait ] curry in-thread ; ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! diff --git a/extra/raptor/raptor.factor b/extra/raptor/raptor.factor index e6f960cd8d..ef5359c313 100644 --- a/extra/raptor/raptor.factor +++ b/extra/raptor/raptor.factor @@ -22,6 +22,8 @@ SYMBOL: networking-hook : fork-exec-wait ( pathname args -- ) fork dup 0 = [ drop exec drop ] [ 2nip wait-for-pid drop ] if ; +: fork-exec-args-wait ( args -- ) [ first ] [ ] bi fork-exec-wait ; + ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! : forever ( quot -- ) [ call ] [ forever ] bi ; @@ -59,6 +61,10 @@ SYMBOL: swap-devices : start-networking ( -- ) networking-hook get call ; +: set-hostname ( name -- ) `{ "/bin/hostname" , } fork-exec-args-wait ; + +! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + : boot ( -- ) boot-hook get call ; : reboot ( -- ) reboot-hook get call ; : shutdown ( -- ) shutdown-hook get call ;