Subversion Repositories DevTools

Rev

Rev 6823 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6823 Rev 6825
Line 87... Line 87...
87
 
87
 
88
#
88
#
89
#   Self install and removal
89
#   Self install and removal
90
#   Normally run from the installer
90
#   Normally run from the installer
91
#
91
#
92
kdeScriptCfg=/.kde/share/config/configureVM
92
kdeScriptCfg="/.kde/share/config/configureVM /var/lib/lightdm/.kde/share/config/configureVM"
93
if [ "$startupMode" = "install" ] ; then
93
if [ "$startupMode" = "install" ] ; then
94
    ln -s $0 /root/Desktop/configureVM
94
    ln -s $0 /root/Desktop/configureVM
95
    rm -f /root/.vix/config
95
    rm -f /root/.vix/config
96
    createHelpText
96
    createHelpText
97
    rm -f $kdeScriptCfg
97
    rm -f $kdeScriptCfg
Line 123... Line 123...
123
HostName: $(hostname)
123
HostName: $(hostname)
124
IP address: $ipaddress
124
IP address: $ipaddress
125
 
125
 
126
Continue to login"
126
Continue to login"
127
  # May create /.kde/share/config/configureVM ($kdeScriptCfg)
127
  # May create /.kde/share/config/configureVM ($kdeScriptCfg)
-
 
128
  # Or "/var/lib/lightdm/.kde/share/config/configureVM"
128
  kdialog --msgbox "$text" --dontagain configureVM:noipaddressmsg
129
  kdialog --msgbox "$text" --dontagain configureVM:noipaddressmsg
129
  exit
130
  exit
130
fi  
131
fi  
131
rm -f $kdeScriptCfg
132
rm -f $kdeScriptCfg
132
 
133
 
Line 160... Line 161...
160
#
161
#
161
#   Set defaults, before overiding with users last values
162
#   Set defaults, before overiding with users last values
162
#
163
#
163
mname=$(cat /etc/hostname)
164
mname=$(cat /etc/hostname)
164
mode='Automount home drives'
165
mode='Automount home drives'
165
pkgServer='auperaarc02'
166
pkgServer='auperaarc01'
166
[ -f /root/.vix/config.data ] && source /root/.vix/config.data
167
[ -f /root/.vix/config.data ] && source /root/.vix/config.data
167
 
168
 
168
ok=false
169
ok=false
169
prompt="Unique machine name\
170
prompt="Unique machine name\
170
        <pre>Suggested format: AUPERAWSxxxVMnn\
171
        <pre>Suggested format: AUPERAWSxxxVMnn\
Line 296... Line 297...
296
        sed -i /etc/apt/apt.conf -e 's~http://.*@proxy~http://username:password@proxy~'
297
        sed -i /etc/apt/apt.conf -e 's~http://.*@proxy~http://username:password@proxy~'
297
    fi
298
    fi
298
fi
299
fi
299
 
300
 
300
#
301
#
-
 
302
#   Save the VM image name
-
 
303
#   Should be held in the hostname
-
 
304
#   Save it on first use
-
 
305
#
-
 
306
if [ ! -f /root/.vix/vix-image-name ] ; then
-
 
307
    cp /etc/hostname /root/.vix/vix-image-name
-
 
308
fi
-
 
309
 
-
 
310
#
301
#   Set new machine name
311
#   Set new machine name
302
#
312
#
303
echo $mname > /etc/hostname
313
echo $mname > /etc/hostname
304
sed -i /etc/hosts -e "s~^127\.0\.1\.1.*~127.0.1.1\t$mname~"
314
sed -i /etc/hosts -e "s~^127\.0\.1\.1.*~127.0.1.1\t$mname~"
305
hostname -b -F /etc/hostname
315
hostname -b -F /etc/hostname
Line 350... Line 360...
350
#         May not be an issue as we are about to reboot
360
#         May not be an issue as we are about to reboot
351
systemctl stop autofs 
361
systemctl stop autofs 
352
 
362
 
353
#
363
#
354
#   Configure the package server
364
#   Configure the package server
-
 
365
#   Support old - /etc/profile.d
-
 
366
#   and New     - /etc/dpkg_archive
355
#
367
#
356
echo "Configure Package Server"
368
echo "Configure Package Server"
357
sed -i /etc/profile.d/jats.sh -e "s~^\(GBE_DPKG=/net\)/\([^/]*\)/\(.*\)~\1/$pkgServer/\3~"
369
sed -i /etc/profile.d/jats.sh -e "s~^\(GBE_DPKG=/net\)/\([^/]*\)/\(.*\)~\1/$pkgServer/\3~"
-
 
370
echo "/net/$pkgServer/export/devl/dpkg_archive" > /etc/dpkg_archive
358
 
371
 
359
#
372
#
360
#   Flag - configuration done
373
#   Flag - configuration done
361
#   This should stop the auto script from running again
374
#   This should stop the auto script from running again
362
#
375
#