Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/oob/post.sh
diff options
context:
space:
mode:
Diffstat (limited to 'oob/post.sh')
-rw-r--r--oob/post.sh46
1 files changed, 46 insertions, 0 deletions
diff --git a/oob/post.sh b/oob/post.sh
new file mode 100644
index 0000000..3b7deef
--- /dev/null
+++ b/oob/post.sh
@@ -0,0 +1,46 @@
+#!/bin/bash
+
+src_root=$(dirname $0)
+cd ${INSTALL_ROOT}
+
+creds=$(ls -aldn home/olpc | awk '{print $3 ":" $4}')
+gconf_set="gconftool-2 --direct --config-source xml:readwrite:etc/gconf/gconf.xml.defaults --set"
+
+$gconf_set --type float /desktop/sugar/font/default_size 7
+$gconf_set --type bool /desktop/sugar/show_logout false
+$gconf_set --type bool /desktop/sugar/power/automatic true
+$gconf_set --type string /desktop/sugar/user/default_nick 'disabled'
+$gconf_set --type bool /desktop/sugar/network/adhoc true
+
+echo "echo 0 > /sys/class/net/eth0/lbs_mesh" >> etc/rc.local
+
+cat > etc/sweets.conf << EOF
+[sweets]
+# enable Sugar Network support in Sugar Shell
+sugar-network = True
+
+[local-document]
+# url to connect to Sugar Network server API
+# make it empty to discover local servers via Avahi
+api-url =
+# start server to share local documents
+server-mode = False
+EOF
+
+# modules.d/base swipes locale-archive
+cp opt/sweets/locales/locale-archive /usr/lib/locale/
+
+# XXX IPTables init.d script is disabled but something starts anyway
+# blacklisting doesn't help
+find lib -type d -name netfilter -exec rm -rf {} \; || true
+
+mkdir -p home/olpc/{Activities,Library}
+for bundle in $(ls $src_root/activities/*.xo); do
+ unzip -q $bundle -d home/olpc/Activities/
+done
+chown ${creds} -R home/olpc/{Activities,Library}
+
+cat > home/olpc/.xsession << EOF
+exec sweets-sugar
+EOF
+chown ${creds} home/olpc/.xsession