forked from ungleich-public/cdist
		
	Merge branch 'preos' into 4.0-pre-not-stable
This commit is contained in:
		
				commit
				
					
						97b2335323
					
				
			
		
					 1 changed files with 7 additions and 0 deletions
				
			
		| 
						 | 
					@ -162,6 +162,10 @@ cp -L "$src" "$real_dst"
 | 
				
			||||||
                fd.write(val)
 | 
					                fd.write(val)
 | 
				
			||||||
            os.chmod(filename, stat.S_IRUSR |  stat.S_IXUSR)
 | 
					            os.chmod(filename, stat.S_IRUSR |  stat.S_IXUSR)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def remove_archives(self, base_dir):
 | 
				
			||||||
 | 
					        cmd = [ "chroot", self.target_dir, "/usr/bin/apt-get", "clean" ]
 | 
				
			||||||
 | 
					        subprocess.check_call(cmd)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def create_kernel(self):
 | 
					    def create_kernel(self):
 | 
				
			||||||
        dst = os.path.join(self.out_dir, "kernel")
 | 
					        dst = os.path.join(self.out_dir, "kernel")
 | 
				
			||||||
        srcglob = glob.glob("%s/boot/vmlinuz-*" % self.target_dir)
 | 
					        srcglob = glob.glob("%s/boot/vmlinuz-*" % self.target_dir)
 | 
				
			||||||
| 
						 | 
					@ -270,6 +274,9 @@ cp -L "$src" "$real_dst"
 | 
				
			||||||
        if args.config:
 | 
					        if args.config:
 | 
				
			||||||
            self.config()
 | 
					            self.config()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        # Cleanup archives before creating any image
 | 
				
			||||||
 | 
					        self.remove_archives()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        # Output pxe files
 | 
					        # Output pxe files
 | 
				
			||||||
        if args.pxe_boot_dir:
 | 
					        if args.pxe_boot_dir:
 | 
				
			||||||
            self.create_pxe(args.pxe_boot_dir)
 | 
					            self.create_pxe(args.pxe_boot_dir)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue