/[gli]/branches/overhaul/src/GLIArchitectureTemplate.py
Gentoo

Diff of /branches/overhaul/src/GLIArchitectureTemplate.py

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

Revision 265 Revision 266
1""" 1"""
2Gentoo Linux Installer 2Gentoo Linux Installer
3 3
4$Id: GLIArchitectureTemplate.py,v 1.35 2005/01/15 06:30:54 codeman Exp $ 4$Id: GLIArchitectureTemplate.py,v 1.36 2005/01/19 03:13:52 agaffney Exp $
5Copyright 2004 Gentoo Technologies Inc. 5Copyright 2004 Gentoo Technologies Inc.
6 6
7 7
8The ArchitectureTemplate is largely meant to be an abstract class and an 8The ArchitectureTemplate is largely meant to be an abstract class and an
9interface (yes, it is both at the same time!). The purpose of this is to create 9interface (yes, it is both at the same time!). The purpose of this is to create
37 # Of course, steps will be different depending on the install_profile 37 # Of course, steps will be different depending on the install_profile
38 38
39 self._architecture_name = "generic" 39 self._architecture_name = "generic"
40 #self._install_steps = [ (self.partition, "Partition"), TEMPORARY thing only. 40 #self._install_steps = [ (self.partition, "Partition"), TEMPORARY thing only.
41 self._install_steps = [ 41 self._install_steps = [
42 (self.partition, "Partition"),
42 (self.mount_local_partitions, "Mount local partitions"), 43 (self.mount_local_partitions, "Mount local partitions"),
43 (self.mount_network_shares, "Mount network (NFS) shares"), 44 (self.mount_network_shares, "Mount network (NFS) shares"),
44 (self.unpack_stage_tarball, "Unpack stage tarball"), 45 (self.unpack_stage_tarball, "Unpack stage tarball"),
45 (self.configure_make_conf, "Configure /etc/make.conf"), 46 (self.configure_make_conf, "Configure /etc/make.conf"),
46 (self.install_portage_tree, "Portage tree voodoo"), 47 (self.install_portage_tree, "Portage tree voodoo"),
221 <agaffney> make sure /etc/init.d/portmap is started 222 <agaffney> make sure /etc/init.d/portmap is started
222 <agaffney> then mount each one: mount -t nfs -o <mountopts> <host>:<export> <mountpoint> 223 <agaffney> then mount each one: mount -t nfs -o <mountopts> <host>:<export> <mountpoint>
223 """ 224 """
224 nfsmounts = self._install_profile.get_network_mounts() 225 nfsmounts = self._install_profile.get_network_mounts()
225 for netmount in nfsmounts: 226 for netmount in nfsmounts:
226 if nfsmounts[netmount]['type'] == "NFS" or nfsmounts[netmount]['type'] == "nfs": 227 if netmount['type'] == "NFS" or netmount['type'] == "nfs":
227 mountopts = nfsmounts[netmount]['mountopts'] 228 mountopts = netmount['mountopts']
228 if mountopts: 229 if mountopts:
229 mountopts = "-o "+mountopts 230 mountopts = "-o "+mountopts
230 host = nfsmounts[netmount]['host'] 231 host = netmount['host']
231 export = nfsmounts[netmount]['export'] 232 export = netmount['export']
232 mountpoint = nfsmounts[netmount]['mountpoint'] 233 mountpoint = netmount['mountpoint']
233 if not GLIUtility.is_file(self._chroot_dir+mountpoint): 234 if not GLIUtility.is_file(self._chroot_dir+mountpoint):
234 exitstatus = GLIUtility.spawn("mkdir -p " + self._chroot_dir + mountpoint) 235 exitstatus = GLIUtility.spawn("mkdir -p " + self._chroot_dir + mountpoint)
235 if exitstatus != 0: 236 if exitstatus != 0:
236 raise GLIException("MkdirError", 'fatal','mount_network_shares', "Making the mount point failed!") 237 raise GLIException("MkdirError", 'fatal','mount_network_shares', "Making the mount point failed!")
237 ret = GLIUtility.spawn("mount -t nfs "+mountopts+" "+host+":"+export+" "+self._chroot_dir+mountpoint) 238 ret = GLIUtility.spawn("mount -t nfs "+mountopts+" "+host+":"+export+" "+self._chroot_dir+mountpoint)

Legend:
Removed from v.265  
changed lines
  Added in v.266

  ViewVC Help
Powered by ViewVC 1.1.20