Magellan Linux

Diff of /trunk/mlivecdbuild/profiles/alx-0_7_branch/prepare_custom

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2664 by niro, Wed Jul 9 07:22:35 2014 UTC revision 3071 by niro, Fri Sep 1 09:36:13 2017 UTC
# Line 26  updateconfig() Line 26  updateconfig()
26   done   done
27  }  }
28    
29  ##  # prepare_custom_baseconfig $_OSROOT $_OSHOSTNAME $_OSHOSTDOMAIN
30  # create the install tarball  prepare_custom_baseconfig()
 ##  
 create_install_tarball()  
31  {  {
32   install -d ${LIVECDROOT}/install-temp   local _OSROOT="$1"
33   install -d ${CDISOROOT}/system   local _OSHOSTNAME="$2"
34     local _OSHOSTDOMAIN="$3"
35     if [[ -z ${_OSROOT} ]]
36     then
37     echo "no _OSROOT given"
38     return 1
39     fi
40     if [[ ! -d ${_OSROOT} ]]
41     then
42     echo "Root dir '${_OSROOT}' does not exist"
43     return 1
44     fi
45     if [[ -z ${_OSHOSTNAME} ]]
46     then
47     echo "no _OSHOSTNAME given"
48     return 1
49     fi
50     if [[ -z ${_OSHOSTDOMAIN} ]]
51     then
52     echo "no _OSHOSTDOMAIN given"
53     return 1
54     fi
55    
56   # use all settings from the global config, but the basesystem   # generate a new machine-id on first-boot
57   # has to be the normal install basesystem not for livecds   :> ${_OSROOT}/etc/machine-id
  mage-bootstrap \  
  --root ${LIVECDROOT}/install-temp \  
  --profile ${MAGE_PROFILE} \  
  --magerc ${MAGERC} \  
  --toolchain ${TOOLCHAIN} \  
  --update-tarball \  
  --basesystem basesystem || die "bootstrapping target system failed!"  
58    
59   # set an empty root password for the install system too   # fix localtime symlink
60   chroot ${LIVECDROOT}/install-temp passwd -d root   ln -snf ../usr/share/zoneinfo/Europe/Berlin ${_OSROOT}/etc/localtime
61    
62   # add user station with empty password   # activate timeserver via dhcp (NTP - option 42)
63   chroot ${LIVECDROOT}/install-temp adduser -G users -h /home/station -s /bin/bash -D station   CDCHROOTDIR=${_OSROOT} custom_services add systemd-timesyncd.service
64    
65   # install xinitrc   # empty root password
66   echo 'exec startfluxbox' > ${LIVECDROOT}/install-temp/home/station/.xinitrc   chroot ${_OSROOT} passwd -d root
67    
68     # empty user password
69     chroot ${_OSROOT} passwd -d station
70    
71     if [ -x ${_OSROOT}/usr/bin/mcorepasswd ] ||
72     [ -L ${_OSROOT}/usr/bin/mcorepasswd ]
73     then
74     # add mcored default user
75     ( echo "foobar"; sleep 0.1; echo "foobar" ) | chroot ${_OSROOT} /usr/bin/mcorepasswd mcore
76     fi
77    
78   # fix hostname and hosts file   # fix hostname and hosts file
79   echo "alx-i486" > ${LIVECDROOT}/install-temp/etc/hostname   echo "${_OSHOSTNAME}" > ${_OSROOT}/etc/hostname
80   echo "127.0.0.1 localhost alx-i486.magellan-linux.de alx-i486" > ${LIVECDROOT}/install-temp/etc/hosts   echo "127.0.0.1 localhost ${_OSHOSTNAME}.${_OSHOSTDOMAIN} ${_OSHOSTNAME}" > ${_OSROOT}/etc/hosts
81   cat >> ${LIVECDROOT}/install-temp/etc/hosts << EOF   cat >> ${_OSROOT}/etc/hosts << EOF
82  ::1             ip6-localhost   ip6-loopback  ::1             ip6-localhost   ip6-loopback
83  fe00::0         ip6-localnet  fe00::0         ip6-localnet
84  ff00::0         ip6-mcastprefix  ff00::0         ip6-mcastprefix
# Line 64  ff02::1         ip6-allnodes Line 86  ff02::1         ip6-allnodes
86  ff02::2         ip6-allrouters  ff02::2         ip6-allrouters
87  ff02::3         ip6-allhosts  ff02::3         ip6-allhosts
88  EOF  EOF
89    }
90    
91   # create a default network interface config file  # prepare_custom_installertarball $_OSROOT $_TARBALLNAME $_TARBALLTARGET
92   cat > ${LIVECDROOT}/install-temp/etc/conf.d/net.eth0 << EOF  prepare_custom_installertarball()
93  ONBOOT="yes"  {
94  NETWORKING="dhcp"   local _OSROOT="$1"
95  EOF   local _TARBALLNAME="$2"
96     local _TARBALLTARGET="$3"
97   # fix mage.rc and config.rc   if [[ -z ${_OSROOT} ]]
98   NEW_SQL_USER="alx_install"   then
99   NEW_SQL_PASS="@lx"   echo "no _OSROOT given"
100   NEW_SQL_HOST="128.20.41.110"   return 1
101   NEW_SQL_DB="alx_web"   fi
102   NEW_SMB_UPDATE_HOST="//${NEW_SQL_HOST}/magetmp"   if [[ ! -d ${_OSROOT} ]]
103   NEW_SMB_UPDATE_USER="${NEW_SQL_USER}"   then
104   NEW_SMB_UPDATE_PASS="${NEW_SQL_PASS}"   echo "Root dir '${_OSROOT}' does not exist"
105   NEW_MAGE_MIRRORS="http://${NEW_SQL_HOST}/magellan/alx-070"   return 1
106   NEW_MAGE_RSYNC="rsync://${NEW_SQL_HOST}/mage-alx-070"   fi
107   NEW_RSYNC="${NEW_MAGE_RSYNC}"   if [[ -z ${_TARBALLNAME} ]]
108   NEW_SMAGE2RSYNC="rsync://${NEW_SQL_HOST}/smage-alx-070"   then
109   NEW_MIRRORS="${NEW_MAGE_MIRRORS}"   echo "no _TARBALLNAME given"
110   NEW_MAGE_UNINSTALL_TIMEOUT="0"   return 1
111   CONFIG="${LIVECDROOT}/install-temp/etc/mage.rc"   fi
112   updateconfig RSYNC SMAGE2RSYNC MIRRORS MAGE_UNINSTALL_TIMEOUT   if [[ -z ${_TARBALLTARGET} ]]
113   CONFIG="${LIVECDROOT}/install-temp/etc/alxconfig-ng/config.rc"   then
114   updateconfig SQL_USER SQL_PASS SQL_HOST SQL_DB SMB_UPDATE_HOST SMB_UPDATE_USER SMB_UPDATE_PASS MAGE_MIRRORS MAGE_RSYNC   echo "no _TARBALLTARGET given"
115     return 1
116     fi
117    
118   # create tarball   # create tarball
119   [[ -f ${CDISOROOT}/system/alx-i486.tar.bz2 ]] && rm ${CDISOROOT}/system/alx-i486.tar.bz2   [[ -f ${_TARBALLTARGET}/${_TARBALLNAME}.tar.bz2 ]] && rm ${_TARBALLTARGET}/${_TARBALLNAME}.tar.bz2
120   ( cd ${LIVECDROOT}/install-temp; tar cvjpf ${CDISOROOT}/system/alx-i486.tar.bz2 ./ | tee log)   ( cd ${_OSROOT}; tar cvjpf ${CDISOROOT}/${_TARBALLTARGET}/${_TARBALLNAME}.tar.bz2 ./ | tee ${LIVECDROOT}/${_TARBALLNAME}.log )
121    
122   # create images.conf   # create images.conf
123   echo "CDIMAGENAME=alx-i486.tar.bz2" > ${CDISOROOT}/system/images.conf   echo "CDIMAGENAME=${_TARBALLNAME}.tar.bz2" > ${_TARBALLTARGET}/images.conf
124   echo "TOTALLINES=$(wc -l ${LIVECDROOT}/install-temp/log | cut -d' ' -f1)" >> ${CDISOROOT}/system/images.conf   echo "TOTALLINES=$(wc -l ${LIVECDROOT}/${_TARBALLNAME}.log | cut -d' ' -f1)" >> ${_TARBALLTARGET}/images.conf
   
  create_netboot_image  
125    
126   # clean up   # clean up
127   if [[ -d ${LIVECDROOT}/install-temp ]]   if [[ -z ${SKIP_REMOVE_INSTALLROOT} ]]
128     then
129     if [[ -d ${_OSROOT} ]]
130     then
131     rm -r ${_OSROOT}
132     fi
133     if [[ -f ${LIVECDROOT}/${_TARBALLNAME}.log ]]
134     then
135     rm ${LIVECDROOT}/${_TARBALLNAME}.log
136     fi
137     fi
138    }
139    
140    ##
141    # create the install tarball
142    ##
143    create_install_tarball()
144    {
145     install -d ${LIVECDROOT}/install-chroot
146     install -d ${CDISOROOT}/system
147    
148     # use all settings from the global config, but the basesystem
149     # has to be the normal install basesystem not for livecds
150     mage-bootstrap \
151     --root ${LIVECDROOT}/install-chroot \
152     --profile ${MAGE_PROFILE} \
153     --magerc ${MAGERC} \
154     --toolchain ${TOOLCHAIN} \
155     --update-tarball \
156     --basesystem basesystem || die "bootstrapping target system failed!"
157    
158    ## DEV SERVER ##
159    # NEW_MCORE_CONTROL_SERVER="alx-control-dev.dom-aka-nt.intern"
160    # CONFIG="${LIVECDROOT}/install-chroot/etc/mcore/mcore.conf"
161    # updateconfig MCORE_CONTROL_SERVER
162    ###
163    
164     # fix missing symlink
165     if [ ! -L ${LIVECDROOT}/install-chroot/usr/bin/X ]
166   then   then
167   rm -rf ${LIVECDROOT}/install-temp   ln -snf Xorg ${LIVECDROOT}/install-chroot/usr/bin/X
168   fi   fi
169    
170     # os config
171     prepare_custom_baseconfig "${LIVECDROOT}/install-chroot" "alx-${CDOSARCH}" "magellan-linux.de"
172    
173     # create tarball
174     prepare_custom_installertarball "${LIVECDROOT}/install-chroot" "alx-${CDOSARCH}" "${CDISOROOT}/system"
175  }  }
176    
177  ##  ##
# Line 113  EOF Line 180  EOF
180  create_netboot_image()  create_netboot_image()
181  {  {
182   install -d ${CDISOROOT}/netboot   install -d ${CDISOROOT}/netboot
183   install -d ${LIVECDROOT}/network-temp   install -d ${LIVECDROOT}/netboot-chroot
184     install -d ${LIVECDROOT}/network-squashfs-temp
185    
186     # use all settings from the global config, but use netbootsysten as basesystem
187     mage-bootstrap \
188     --root ${LIVECDROOT}/netboot-chroot \
189     --profile ${MAGE_PROFILE} \
190     --magerc ${MAGERC} \
191     --toolchain ${TOOLCHAIN} \
192     --update-tarball \
193     --basesystem netbootsystem || die "bootstrapping target system failed!"
194    
195     # os config
196     prepare_custom_baseconfig "${LIVECDROOT}/netboot-chroot" "alx-${CDOSARCH}" "magellan-linux.de"
197    
198   install -d ${LIVECDROOT}/network-temp/{LiveOS,mnt} || die   # creating netboot image from here on
199     install -d ${LIVECDROOT}/network-squashfs-temp/{LiveOS,mnt} || die
200    
201     # fix fstab, use the livecd fstab without rootfs and swap
202     install -m 0644 $(get_profile fstab) ${LIVECDROOT}/netboot-chroot/etc/fstab || die
203    
204   # get the actual size of the chroot   # get the actual size of the chroot
205   size=$(du -s ${LIVECDROOT}/install-temp | sed 's:^\(.*\)[[:space:]].*:\1:')   size=$(du -s ${LIVECDROOT}/netboot-chroot | sed 's:^\(.*\)[[:space:]].*:\1:')
206    
207   # generate a ext3fs file for devicemapper   # generate a ext3fs file for devicemapper
208   dd if=/dev/zero of=${LIVECDROOT}/network-temp/LiveOS/ext3fs.img bs=1024 count=$(( ${size} + 10 )) || die   dd if=/dev/zero of=${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img bs=1024 count=$(( ${size} + 20000 )) || die
209   # create a filesystem   # create a filesystem
210   mkfs.ext3 -L "_${CDID}_EXT3" -m 1 -b 1024 -F ${LIVECDROOT}/network-temp/LiveOS/ext3fs.img || die   mkfs.ext3 -L "_${CDID}_EXT3" -m 1 -b 1024 -F ${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img || die
211   # set mount_counts and check_intervals to 0   # set mount_counts and check_intervals to 0
212   # set dir_index top, to speed up thing with hashed b-trees   # set dir_index top, to speed up things with hashed b-trees
213   # allow acls too   # allow acls too
214   tune2fs -c0 -i0 -Odir_index -ouser_xattr,acl ${LIVECDROOT}/network-temp/LiveOS/ext3fs.img || die   tune2fs -c0 -i0 -Odir_index -ouser_xattr,acl ${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img || die
215     # strip the journal
216    # tune2fs -O^has_journal ${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img || die
217     # fsck after journal removal
218    # fsck ${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img || die
219    
220   # losetup the device   # losetup the device
221   loopdev=$(losetup -f)   loopdev=$(losetup -f)
222   [[ -z ${loopdev} ]] && die "No unused loopdev found. Maybe you want 'modprobe loop'?"   [[ -z ${loopdev} ]] && die "No unused loopdev found. Maybe you want 'modprobe loop'?"
223    
224   # mount the image   # mount the image
225   losetup ${loopdev} ${LIVECDROOT}/network-temp/LiveOS/ext3fs.img || die   losetup ${loopdev} ${LIVECDROOT}/network-squashfs-temp/LiveOS/ext3fs.img || die
226   mount ${loopdev} ${LIVECDROOT}/network-temp/mnt || die   mount ${loopdev} ${LIVECDROOT}/network-squashfs-temp/mnt || die
227    
228   # copy everything to the image file and preserve permissions   # copy everything to the image file and preserve permissions
229   ( cd ${LIVECDROOT}/install-temp && tar cpf - . ) | ( cd ${LIVECDROOT}/network-temp/mnt && tar xvpf - )   ( cd ${LIVECDROOT}/netboot-chroot && tar cpf - . ) | ( cd ${LIVECDROOT}/network-squashfs-temp/mnt && tar xvpf - )
230   sleep 3   sleep 3
231    
232   # now umount everything and create the squashfs image   # now umount everything and create the squashfs image
233   umount ${LIVECDROOT}/network-temp/mnt || die   umount ${LIVECDROOT}/network-squashfs-temp/mnt || die
234   losetup -d ${loopdev} || die   losetup -d ${loopdev} || die
235   # remove mount to not ending up in the squashfs image   # remove mount to not ending up in the squashfs image
236   if [[ -d ${LIVECDROOT}/network-temp/mnt ]]   if [[ -d ${LIVECDROOT}/network-squashfs-temp/mnt ]]
237   then   then
238   rm -r ${LIVECDROOT}/network-temp/mnt || die   rm -r ${LIVECDROOT}/network-squashfs-temp/mnt || die
239   fi   fi
240   mksquashfs ${LIVECDROOT}/network-temp ${CDISOROOT}/netboot/squashfs.img || die   mksquashfs ${LIVECDROOT}/network-squashfs-temp ${CDISOROOT}/netboot/squashfs.img || die
241    
242   # copy kernel and create initramfs to isoroot/netboot   # copy kernel, bootloader and create initramfs to isoroot/netboot
243   install -d ${CDISOROOT}/netboot || die   install -d ${CDISOROOT}/netboot || die
244   # kernel   # kernel
245   kimg="$(find ${CDCHROOTDIR}/boot -name kernel-\* -printf '%f\n')"   kimg="$(find ${CDCHROOTDIR}/boot -name kernel-\* -printf '%f\n')"
246   install ${CDCHROOTDIR}/boot/${kimg} ${CDISOROOT}/netboot/${CDKERNELNAME} || die   install ${CDCHROOTDIR}/boot/${kimg} ${CDISOROOT}/netboot/${CDKERNELNAME} || die
247   # initrd   # initrd
248   install -d ${CDCHROOTDIR}/etc/dracut.conf.d || die   install -d ${CDCHROOTDIR}/etc/dracut.conf.d || die
249   echo 'add_dracutmodules+=" livenet busybox"' > ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf || die   echo 'add_dracutmodules+=" livenet busybox "' > ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf || die
250   echo 'omit_dracutmodules+=" systemd plymouth mcored"' >> ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf || die   echo 'omit_dracutmodules+=" mcored "' >> ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf || die
251     echo 'hostonly="no"' >> ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf || die
252   # install dracut-dev package to have all modules   # install dracut-dev package to have all modules
253   custom_packages install dracut-dev curl curl-dev || die   custom_packages install "dracut-dev curl curl-dev" || die
254   ## mlivecdbuild function   ## mlivecdbuild function
255   generate_initrd   generate_initrd
256   mv ${CDISOROOT}/isolinux/initrd.gz ${CDISOROOT}/netboot/ || die   mv ${CDISOROOT}/isolinux/initrd.gz ${CDISOROOT}/netboot/ || die
257   custom_packages uninstall dracut-dev curl curl-dev || die   # fix initrd permissions
258     chmod 0644 ${CDISOROOT}/netboot/initrd.gz || die
259   if [ -e ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf ]   if [ -e ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf ]
260   then   then
261   rm ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf   rm ${CDCHROOTDIR}/etc/dracut.conf.d/03-netboot.conf
262   fi   fi
263     # bootloader pxelinux
264     install -d ${CDISOROOT}/netboot/pxelinux/pxelinux.cfg
265     [ -f $(get_profile netboot/pxelinux.0) ] && install -m0644 $(get_profile netboot/pxelinux.0) ${CDISOROOT}/netboot/pxelinux/
266     [ -f $(get_profile netboot/pxelinux.cfg/pxelinux-default) ] && install -m0644 $(get_profile netboot/pxelinux.cfg/pxelinux-default) ${CDISOROOT}/netboot/pxelinux/pxelinux.cfg
267     [ -f $(get_profile netboot/pxelinux.cfg/boot.cat) ] && install -m0644 $(get_profile netboot/pxelinux.cfg/boot.cat) ${CDISOROOT}/netboot/pxelinux/
268     [ -f $(get_profile boot.lss) ] && install -m0644 $(get_profile boot.lss) ${CDISOROOT}/netboot/pxelinux/
269     [ -f $(get_profile boot.msg) ] && install -m0644 $(get_profile boot.msg) ${CDISOROOT}/netboot/pxelinux/
270     [ -f $(get_profile debug.msg) ] && install -m0644 $(get_profile debug.msg) ${CDISOROOT}/netboot/pxelinux/
271     [ -f $(get_profile help.msg) ] && install -m0644 $(get_profile help.msg) ${CDISOROOT}/netboot/pxelinux/
272     [ -f $(get_profile index.msg) ] && install -m0644 $(get_profile index.msg) ${CDISOROOT}/netboot/pxelinux/
273     # bootloader lpxelinux
274     install -d ${CDISOROOT}/netboot/lpxelinux/pxelinux.cfg
275     [ -f $(get_profile netboot/lpxelinux.0) ] && install -m0644 $(get_profile netboot/lpxelinux.0) ${CDISOROOT}/netboot/lpxelinux/
276     [ -f $(get_profile netboot/ldlinux.c32) ] && install -m0644 $(get_profile netboot/ldlinux.c32) ${CDISOROOT}/netboot/lpxelinux/
277     [ -f $(get_profile netboot/pxelinux.cfg/lpxelinux-default) ] && install -m0644 $(get_profile netboot/pxelinux.cfg/lpxelinux-default) ${CDISOROOT}/netboot/lpxelinux/pxelinux.cfg
278     [ -f $(get_profile netboot/pxelinux.cfg/boot.cat) ] && install -m0644 $(get_profile netboot/pxelinux.cfg/boot.cat) ${CDISOROOT}/netboot/lpxelinux/
279     [ -f $(get_profile boot.lss) ] && install -m0644 $(get_profile boot.lss) ${CDISOROOT}/netboot/lpxelinux/
280     [ -f $(get_profile boot.msg) ] && install -m0644 $(get_profile boot.msg) ${CDISOROOT}/netboot/lpxelinux/
281     [ -f $(get_profile debug.msg) ] && install -m0644 $(get_profile debug.msg) ${CDISOROOT}/netboot/lpxelinux/
282     [ -f $(get_profile help.msg) ] && install -m0644 $(get_profile help.msg) ${CDISOROOT}/netboot/lpxelinux/
283     [ -f $(get_profile index.msg) ] && install -m0644 $(get_profile index.msg) ${CDISOROOT}/netboot/lpxelinux/
284    
285   # final cleanup   # final cleanup
286   if [[ -d ${LIVECDROOT}/network-temp ]]   if [[ -z ${SKIP_REMOVE_INSTALLROOT} ]]
287     then
288     if [[ -d ${LIVECDROOT}/network-squasfs-temp ]]
289     then
290     rm -r ${LIVECDROOT}/network-squasfs-temp || die
291     fi
292     if [[ -d ${LIVECDROOT}/netboot-chroot ]]
293     then
294     rm -r ${LIVECDROOT}/netboot-chroot
295     fi
296     fi
297    }
298    
299    ##
300    # create the server tarball
301    ##
302    create_server_tarball()
303    {
304     install -d ${LIVECDROOT}/server-chroot
305     install -d ${CDISOROOT}/server
306    
307     mage-bootstrap \
308     --root ${LIVECDROOT}/server-chroot \
309     --profile ${MAGE_PROFILE} \
310     --magerc ${MAGERC} \
311     --toolchain ${TOOLCHAIN} \
312     --update-tarball \
313     --basesystem serversystem || die "bootstrapping target system failed!"
314    
315    
316     # enable getty1
317     install -d ${LIVECDROOT}/server-chroot/etc/systemd/system/getty.target.wants
318     ln -snf /usr/lib/systemd/system/getty@.service ${LIVECDROOT}/server-chroot/etc/systemd/system/getty.target.wants/getty@tty1.service
319    
320     # be more verbose
321     sed -i 's:^\(export GRUB_CMDLINE_LINUX_DEFAULT=\).*:\1"rd.info":' ${LIVECDROOT}/server-chroot/etc/conf.d/grub
322    
323     # remove phpmyadmin configuration directory
324     if [ -d ${LIVECDROOT}/server-chroot/usr/share/phpmyadmin/config ]
325   then   then
326   rm -r ${LIVECDROOT}/network-temp || die   rm -r ${LIVECDROOT}/server-chroot/usr/share/phpmyadmin/config
327   fi   fi
328    
329     # os config
330     prepare_custom_baseconfig "${LIVECDROOT}/server-chroot" "alx-svr-${CDOSARCH}" "magellan-linux.de"
331    
332     # fix certificate issues with mcored (common name of cert issuer) and >php-5.4
333     echo "127.0.0.1 mcored" >> ${LIVECDROOT}/server-chroot/etc/hosts
334    
335     # create tarball
336     prepare_custom_installertarball "${LIVECDROOT}/server-chroot" "alx-svr-${CDOSARCH}" "${CDISOROOT}/server"
337  }  }
338    
339  # set an empty root password  # set an empty root password
# Line 185  chroot ${CDCHROOTDIR} passwd -d root Line 343  chroot ${CDCHROOTDIR} passwd -d root
343  install -d ${CDCHROOTDIR}/var/lib/plymouth || die  install -d ${CDCHROOTDIR}/var/lib/plymouth || die
344  install -m 0644 $(get_profile boot-duration.livecd) ${CDCHROOTDIR}/var/lib/plymouth/boot-duration || die  install -m 0644 $(get_profile boot-duration.livecd) ${CDCHROOTDIR}/var/lib/plymouth/boot-duration || die
345    
 # install mnt-cdrom mount service, should be provided by alxinstall-ng  
 #install -m 0644 $(get_profile mnt-cdrom.mount) ${CDCHROOTDIR}/usr/lib/systemd/system/mnt-cdrom.mount || die  
 #ln -snf ../mnt-cdrom.mount ${CDCHROOTDIR}/usr/lib/systemd/system/local-fs.target.wants/mnt-cdrom.mount || die  
   
 # disable splash X11 vt change and set splash to be always verbose  
 #if [[ -f ${CDCHROOTDIR}/etc/splash/splash.conf ]]  
 #then  
 # sed -i -e 's:^\(SPLASH_X11_TTY=.*\):#\1:' \  
 # -e 's:^\(SPLASH_MODE=\).*:\1\"verbose\":' \  
 # ${CDCHROOTDIR}/etc/splash/splash.conf  
 #fi  
   
346  # setup de keymap and locales  # setup de keymap and locales
347  if [ -f ${CDCHROOTDIR}/etc/vconsole.conf ]  if [ -f ${CDCHROOTDIR}/etc/vconsole.conf ]
348  then  then
# Line 216  fi Line 362  fi
362  # stop here if the user don't want to create the install tarball  # stop here if the user don't want to create the install tarball
363  [[ -n ${SKIP_CREATE_INSTALL_TARBALL} ]] || create_install_tarball  [[ -n ${SKIP_CREATE_INSTALL_TARBALL} ]] || create_install_tarball
364    
365    # stop here if the user don't want to create the netboot image
366    [[ -n ${SKIP_CREATE_NETBOOT_TARBALL} ]] || create_netboot_image
367    
368    # stop here if the user don't want to create the server tarball
369    [[ -n ${SKIP_CREATE_SERVER_TARBALL} ]] || create_server_tarball
370    
371  # install usb-install script  # install usb-install script
372  [ ! -d ${CDISOROOT}/usb-install ] && mkdir ${CDISOROOT}/usb-install  [ ! -d ${CDISOROOT}/usb-install ] && mkdir ${CDISOROOT}/usb-install
373  [ -f $(get_profile usb-install/usb-install.cmd) ] && cp $(get_profile usb-install)/usb-install.cmd ${CDISOROOT}/usb-install  [ -f $(get_profile usb-install/usb-install.cmd) ] && cp $(get_profile usb-install)/usb-install.cmd ${CDISOROOT}/usb-install
374  [ -f $(get_profile usb-install/syslinux.exe) ] && cp $(get_profile usb-install)/syslinux.exe ${CDISOROOT}/usb-install  [ -f $(get_profile usb-install/syslinux.exe) ] && cp $(get_profile usb-install)/syslinux.exe ${CDISOROOT}/usb-install
375  [ -f $(get_profile usb-install/syslinux.cfg) ] && cp $(get_profile usb-install)/syslinux.cfg ${CDISOROOT}/usb-install  [ -f $(get_profile usb-install/syslinux.cfg) ] && cp $(get_profile usb-install)/syslinux.cfg ${CDISOROOT}/usb-install
376    
377    # add installer-server script
378    cat > ${CDCHROOTDIR}/usr/bin/installer-server << EOF
379    #!/bin/bash
380    /usr/bin/installer --imageroot /run/initramfs/live/server
381    EOF
382    chmod 0755 ${CDCHROOTDIR}/usr/bin/installer-server

Legend:
Removed from v.2664  
changed lines
  Added in v.3071