source: ipk/source.sh4/network_samba/CONTROL/postinst@ 33566

Last change on this file since 33566 was 33566, checked in by Stephan, 11 years ago

force new smb.conf, backup old

File size: 523 bytes
Line 
1#!/bin/sh
2INSTDIR="$1"
3
4if [ "$INSTDIR" != "/var" ]; then
5 ln -snf "$INSTDIR/bin/smbd" /var/bin/smbd
6 ln -snf "$INSTDIR/bin/nmbd" /var/bin/nmbd
7fi
8
9if [ -f /mnt/config/start-config ]; then
10 sed -i s#"sambaserver=n"#"sambaserver=y"#g /mnt/config/start-config
11fi
12
13if [ -e /mnt/config/smb.conf ]; then
14 mv -f /mnt/config/smb.conf /mnt/config/smb.conf.backup
15 cp /etc/titan.restore/mnt/config/smb.conf /mnt/config/smb.conf
16fi
17
18/var/bin/smbd -D -s /mnt/config/smb.conf; sleep 1; /var/bin/nmbd -D -s /mnt/config/smb.conf
19
20exit 0
Note: See TracBrowser for help on using the repository browser.