Skip to content
Commits on Source (2)
#!/bin/bash #!/bin/bash
DIR=$(realpath $(dirname $0))
USERS="direction" USERS="direction"
for u in $USERS for u in $USERS
do do
if [ -z "`grep '^exec /usr/local/bin/session.sh' /home/$u/.fluxbox/startup `" ] cat <<EOF >/home/$u/.config/autostart/mounts.desktop
then [Desktop Entry]
sed -i -e 's@^exec fluxbox$@exec /usr/local/bin/session.sh \&\nexec fluxbox@' /home/$u/.fluxbox/startup Version=1.0
fi Type=Application
Name=Montages reseau
Comment=
Exec=$DIR/session.sh
Icon=4137_winhlp32.0
Path=
Terminal=false
StartupNotify=false
EOF
done done
...@@ -24,7 +24,7 @@ for usr in 01-mini 02-super 03-maxi ...@@ -24,7 +24,7 @@ for usr in 01-mini 02-super 03-maxi
do do
mkdir -p /home/shares/$usr/ELEVES mkdir -p /home/shares/$usr/ELEVES
mkdir -p /home/shares/$usr/PROFESSEURS mkdir -p /home/shares/$usr/PROFESSEURS
chown -R $usr:$usr /home/shares/$usr chown -R direction:direction /home/shares/$usr
lvl=${LEVELS[$usr]} lvl=${LEVELS[$usr]}
if [ $lvl != 'CP' ] if [ $lvl != 'CP' ]
then then
......
...@@ -2,11 +2,12 @@ ...@@ -2,11 +2,12 @@
USERS="administrateur direction" USERS="administrateur direction"
for u in $USERS for u in $USERS
do do
profile=`awk -F = '/^Path/{print $2}' /home/$u/.mozilla/firefox/profiles.ini` for profile in `awk -F = '/^Path/{print $2}' /home/$u/.mozilla/firefox/profiles.ini`
#echo "$u uses profile $profile" do
preffile="/home/$u/.mozilla/firefox/$profile/user.js" echo "$u uses profile $profile"
#echo $preffile preffile="/home/$u/.mozilla/firefox/$profile/prefs.js"
for pref in "browser.newtabpage.activity-stream.prerender" "browser.newtabpage.activity-stream.showTopSites" echo $preffile
for pref in "browser.newtabpage.activity-stream.feeds.section.highlights" "browser.newtabpage.activity-stream.feeds.topsites"
do do
if [ -z "$(grep "$pref" $preffile)" ] if [ -z "$(grep "$pref" $preffile)" ]
then then
...@@ -16,3 +17,4 @@ do ...@@ -16,3 +17,4 @@ do
fi fi
done done
done done
done
#!/bin/bash #!/bin/bash
export https_proxy="http://dnsproxy:3128"
add-apt-repository ppa:libreoffice/ppa export http_proxy="http://dnsproxy:3128"
add-apt-repository -y ppa:libreoffice/ppa
key=$(apt-get update 2> /dev/null | grep NO_PUBKEY | rev | cut -d ' ' -f 1 | rev)
apt-key adv --keyserver-options http-proxy=$http_proxy --keyserver hkps://keyserver.ubuntu.com:443 --recv-keys $key
apt-get update apt-get update
DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y upgrade DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y dist-upgrade
#!/bin/bash
cat << EOF> /etc/lightdm/slick-greeter.conf
[Greeter]
activate-numlock=true
EOF
#!/bin/bash
# TODO install package
apt-get update
if [ -z "$(dpkg -l | grep language-selector-common)" ]
then
DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y install \
language-selector-common
fi
DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y install \
$(check-language-support)
#!/bin/bash #!/bin/bash
USERS="prof direction administrateur" USERS="prof direction administrateur"
for u in $USERS launcher_path="/usr/share/applications/conky.desktop"
do
launcher_path="/home/$u/.config/xfce4/panel/launcher-11/15502394761.desktop"
mkdir -p /home/$u/.config/xfce4/panel/launcher-11
cat << EOF > $launcher_path cat << EOF > $launcher_path
[Desktop Entry] [Desktop Entry]
Version=1.0 Version=1.0
...@@ -17,26 +14,8 @@ Path= ...@@ -17,26 +14,8 @@ Path=
Terminal=false Terminal=false
StartupNotify=false StartupNotify=false
EOF EOF
xml_path="/home/$u/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml" for u in $USERS
if [ -z "`grep plugin-11 $xml_path`" ] do
then echo TODO set conky in cinnamon applet
sed -i.bak \
-e 's@\(\s*\)\(<value type="int" value="2"/>\)@\1\2\n\1<value type="int" value="11"/>@' \
$xml_path
tmp_path="/tmp/$$"
head -n -2 $xml_path > $tmp_path
cat << EOF >> $tmp_path
<property name="plugin-11" type="string" value="launcher">
<property name="items" type="array">
<value type="string" value="15502394761.desktop"/>
</property>
</property>
</property>
</channel>
EOF
mv /tmp/$$ $xml_path
chown -R $u:$u $xml_path
chown $u:$u $xml_path
fi
done done
...@@ -41,13 +41,14 @@ DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y ...@@ -41,13 +41,14 @@ DEBIAN_FRONTEND='noninteractive' apt-get -o Dpkg::Options::="--force-confold" -y
conky \ conky \
cups-browsed \ cups-browsed \
libdvdcss2 \ libdvdcss2 \
language-selector-common \
netcat \ netcat \
numlockx \ numlockx \
tftp \ tftp \
ttf-mscorefonts-installer \ ttf-mscorefonts-installer \
vlc \
vlc-plugin-fluidsynth \ vlc-plugin-fluidsynth \
x11vnc \ x11vnc
xnview \
test_and_fail $? "Cannot install required packages" test_and_fail $? "Cannot install required packages"
echo "Adding x11vnc" echo "Adding x11vnc"
......
...@@ -31,3 +31,4 @@ run_script fix_firefox.sh ...@@ -31,3 +31,4 @@ run_script fix_firefox.sh
run_script fix_proxy.sh run_script fix_proxy.sh
run_script register.sh run_script register.sh
run_script install_polices.sh run_script install_polices.sh
run_script fix_locales.sh