Date: Fri, 13 Sep 2019 16:44:52 +0900 From: "kouya" <kouya@ryuhoku.jp> To: <freebsd-users-jp@freebsd.org> Subject: [FreeBSD-users-jp 96450] rc.local Message-ID: <C08496BEFD8A4EE9A42EEA8E1F1DE3FF@pv.ryuhoku.jp>
next in thread | raw e-mail | index | archive | help
$B>/$7CTJr$,F~$j$+$1$?O7?M$G$9!#(B OS FreeBSD ah45.pv.ryuhoku.jp 12.0-RELEASE-p10 FreeBSD 12.0-RELEASE-p10 GENERIC amd64 $B$G$9!#(B /etc/rc.local ------------------$B:!=h$+$i(B------------------- # /usr/local/bin/picogw & # ------------------$B:!=h$^$G(B------------------- $BLdBj$J$N$O(B reboot $B$7$F$b(B rc.local $B$K=q$$$?(B picogw $B$,5/F0$7$J$$;v$G$9!#(B OS $B5/F08e(B console $B$G(B /etc/rc.d/local start $B$H(Btype$B$9$k$H(B picogw $B$,5/F0$7(B console $B$KLa$j(B $BLdBj$J$/F0$$$F$$$^$9!#(B $B$I$3$+$K(B /usr/local/etc/rc.d $B$r;H$$$J$5$$!"8+$?$$$J$3$H$,=q$$$F$"$C$?$N$G!#(B /usr/local/etc/rc.d $B$K(B picogw $B$H$7$F(B ------------------$B:!=h$+$i(B------------------- #!/bin/sh # . /etc/rc.subr name="picogw" rcvar="picogw_enable" command="/usr/local/bin/picogw" load_rc_config $name run_rc_command "$1" # ------------------$B:!=h$^$G(B------------------- $B$rEPO?(B /etc/rc.conf $B$K(B ------------------$B:!=h$+$i(B------------------- picogw_enable="YES" ------------------$B:!=h$^$G(B------------------- $B$G:F5/F0$9$k$H!"(Bpicogw $B$O5/F0$9$k$,!"(Bconsole $B$rJ|$5$J$$0Y!"(B $B8e$N%5!<%S%9$,!"5/F0$7$J$$!#(B /usr/local/bin/picogw $B$NFbMF!!(Blink --> /usr/local/lib/nod_module/picogw/bin/picogw ------------------$B:!=h$+$i(B------------------- #!/usr/bin/env node const forever = require('forever-monitor'); // Sometimes, npm i -g target directory is missing from module search path. // So set this script module path as current path. let pi = __filename.lastIndexOf('node_modules'); let pathstr; if( pi == -1 ){ pathstr = require('path').dirname(__filename); } else { pathstr = __filename.substring( 0,pi )+'node_modules'; } const child = new (forever.Monitor)(require.resolve('picogw'),{cwd:pathstr,args:process.argv}); child.start(); ------------------$B:!=h$^$G(B------------------- #!/usr/bin/env node $B$N9T$r(B node --> /usr/local/bin/node $B$KJQ99(B $B?=$7Lu$"$j$^$;$s!"$I$3$N4V0c$$$+!"8+Ev$,IU$-$^$;$s!"$465<x4j$($?$i9,$$$G$9!#(B /etc/rc.local $B$G5/F0=PMh$k$N$,NI$$$N$G$9$,!#(B ??? $B$J$s$+(B rc $BJQ$G$9$M(B moused $B;_$a$h$&$H(B moused_enable="NO" $B$GBLL\(B moused_type="NO" $B$GDd;_(B? $BH,Be;T><OBF1?ND.#9#4#8(B $B!!!!!!1:8}!!9LLi(B
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?C08496BEFD8A4EE9A42EEA8E1F1DE3FF>