diff options
author | Cecil Hugh Watson <knoppmyth@gmail.com> | 2009-09-26 03:21:16 (GMT) |
---|---|---|
committer | Cecil Hugh Watson <knoppmyth@gmail.com> | 2009-09-26 03:21:16 (GMT) |
commit | 632b5c764106d112caa36eeefb3759f9d7c8345b (patch) | |
tree | 7de24499f23871c77f07599046506f431f9abfa1 /build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay | |
parent | 4d4488bbddab439d66088b79e14354c4dd87a2ea (diff) | |
download | linhes_dev-632b5c764106d112caa36eeefb3759f9d7c8345b.zip |
synce_profile.sh:Added support for syncing release profile.
Diffstat (limited to 'build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay')
7 files changed, 157 insertions, 6 deletions
diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.bootsteps b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.bootsteps new file mode 100644 index 0000000..64bb6b7 --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.bootsteps @@ -0,0 +1 @@ +30 diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.conf b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.conf new file mode 100644 index 0000000..ddd88f8 --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.conf @@ -0,0 +1,8 @@ +# +# fbsplash.conf +# + +THEMES="linhes" +SPLASH_TTYS="1 2 3 4 5 6" + +#EOF diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.shutdownsteps b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.shutdownsteps new file mode 100644 index 0000000..7f8f011 --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/conf.d/fbsplash.shutdownsteps @@ -0,0 +1 @@ +7 diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/rc.local b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/rc.local index 216ec8e..2d488a2 100755 --- a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/rc.local +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/etc/rc.local @@ -2,15 +2,92 @@ # # /etc/rc.local: Local multi-user startup script. # +. /etc/rc.conf +. /etc/rc.d/functions +. /etc/profile +. ${MV_ROOT}/bin/install_functions.sh -#install initial database -pacman -S --noconfirm mythdb-initial 2>/dev/null +function mysql_check { + mysql -e "show databases;" 2>/dev/null >/dev/null + return $? +} -# Set up automatically logged in user (larch live system only) +function mythconverg_check { + mysql mythconverg -e "describe settings;" 2>/dev/null >/dev/null + return $? +} + +function install_db { + pacman --noconfirm -R mythdb-initial 2>/dev/null > /dev/null + pacman -S --noconfirm mythdb-initial 2>/dev/null > /dev/null +} + + + + +#check to see if mysql is running +stat_busy "Checking Mysql" +ATTEMPT=0 +mysql_check && printhl " Installing the initial database" &&install_db +mythconverg_check +status=$? +while [ ! $status = 0 ] +do + ((ATTEMPT=ATTEMPT+1)) + /etc/rc.d/mysqld stop + sleep 2 + /etc/rc.d/mysqld start + mysqlstatus=$? + if [ $mysqlstatus = 0 ] + then + mysql_check && install_db + mythconverg_check + status=$? + fi + if [ $ATTEMPT = 20 ] + then + printhl " Could not start mysql or install mythconverg within 20 attempts" + printhl " Aborting install" + exit 20 + fi +done +stat_done + +#check network parms +stat_busy "Checking network" +init_network +stat_done + +stat_busy "Probing network" +request_dhcp & +stat_done + +#save some cmdline options +stat_busy "Parsing command line" +parse_cmdline_2_db +bootsplash_setup +stat_done + +#search for remote +stat_busy "Checking for remote" +init_remote +stat_done +printhl "Finished" + + +echo $CMDLINE | grep -qi NoX +if [ $? = 0 ] +then + echo "" + printhl "No auto X option found" + # /usr/bin/chvt 2 +else + /root/startx & +fi + + +# Set up automatically logged in user if [ -f /.livesys/autologin ]; then cp /.livesys/autologin /tmp/newuser fi -# Restore saved sound volume, etc. -#alsactl restore -#install initial database diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/.fluxbox/apps b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/.fluxbox/apps new file mode 100644 index 0000000..68fae0a --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/.fluxbox/apps @@ -0,0 +1,2 @@ +[startup] {feh --bg-scale ~/.fluxbox/wallpaper.png} + diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/LinHES-install.sh b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/LinHES-install.sh new file mode 100755 index 0000000..6acd24a --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/LinHES-install.sh @@ -0,0 +1,34 @@ +#!/bin/bash +#redirect stderr to stdout, then rediret stdout to file +. /etc/profile +exec 2>&1 +exec > /tmp/mythvantage_install.log +#/usr/bin/nvidia-settings -a InitialPixmapPlacement=2 +#keylaunch & +#/usr/bin/tilda & +#/usr/X11R6/bin/unclutter -root -idle 0 -jitter 400 -noevents & +export MALLOC_CHECK_=0 +xset s off +xset -dpms +xhost + + +CMDLINE=$(cat /proc/cmdline) +echo $CMDLINE |grep -q nfsroot +NFSROOT=$? +echo $CMDLINE |grep -q clean_upgrade +if [ $? = 0 ] +then + export CLEAN_UPGRADE=YES +else + export CLEAN_UPGRADE=NO +fi +MythVantage -r + +if [ x$NFSROOT = x1 ] +then + unbuffer MythVantage & +else + NETBOOT=YES MythVantage & +fi + +exec fluxbox > /var/log/fluxbox.log 2>&1 diff --git a/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/startx b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/startx new file mode 100755 index 0000000..9274703 --- /dev/null +++ b/build_tools/clarch/larch/profiles/i686-RELEASE-REMOTE/rootoverlay/root/startx @@ -0,0 +1,28 @@ +#!/bin/bash +. /etc/profile + +export USER=root +export HOME=/root + +CMDLINE=$(cat /proc/cmdline) +TEMPVAR=${CMDLINE#*ip=} +IP=${TEMPVAR%% *} +echo $CMDLINE |grep -q vnc +USEVNC=$? + +if [ x$USEVNC = x1 ] +then + $MV_ROOT/bin/xconfig.sh 2>/dev/null + cat /etc/X11/xorg.conf | sed -e 's/dev\/mouse/dev\/psaux/g'> /root/xorg.conf.install + startx /root/LinHES-install.sh -- -logverbose 6 -config /root/xorg.conf.install -allowMouseOpenFail 2>/tmp/x.log + else + #VNC + pacman -Sf --noconfirm tightvnc + cd /root + mkdir .vnc + echo mythvantage |vncpasswd -f > /root/.vnc/passwd + chmod 500 /root/.vnc/passwd + rm /root/.vnc/xstartup + ln -s /root/LinHES-install.sh /root/.vnc/xstartup + vncserver +fi |