hudson.plugins.pxe
Class UbuntuBootConfiguration

java.lang.Object
  extended by hudson.model.AbstractModelObject
      extended by hudson.plugins.pxe.BootConfiguration
          extended by hudson.plugins.pxe.IsoBasedBootConfiguration
              extended by hudson.plugins.pxe.LinuxBootConfiguration
                  extended by hudson.plugins.pxe.UbuntuBootConfiguration
All Implemented Interfaces:
hudson.model.Describable<BootConfiguration>, hudson.model.ModelObject, hudson.search.SearchableModelObject, hudson.search.SearchItem

public class UbuntuBootConfiguration
extends LinuxBootConfiguration

Ubuntu boot configuration.

Author:
Kohsuke Kawaguchi

Nested Class Summary
static class UbuntuBootConfiguration.DescriptorImpl
           
 
Nested classes/interfaces inherited from class hudson.plugins.pxe.IsoBasedBootConfiguration
IsoBasedBootConfiguration.FileEntryData, IsoBasedBootConfiguration.IsoBasedBootConfigurationDescriptor
 
Field Summary
 java.lang.String additionalPackages
           
 java.lang.String customMirror
           
 java.lang.String lateCommand
           
 java.lang.String password
           
 java.lang.String userContent
          User-defined preseed content.
 java.lang.String userName
           
 
Fields inherited from class hudson.plugins.pxe.IsoBasedBootConfiguration
iso
 
Constructor Summary
UbuntuBootConfiguration(java.io.File iso, java.lang.String userName, java.lang.String password, java.lang.String additionalPackages, java.lang.String lateCommand, java.lang.String customMirror, java.lang.String userContent)
           
 
Method Summary
 void doLateCommand(org.kohsuke.stapler.StaplerResponse rsp)
           
 void doPreseed(org.kohsuke.stapler.StaplerResponse rsp)
          Serves the preseed file
protected  java.lang.String getIdSeed()
          Returns the string that becomes the seed of the BootConfiguration.getId().
 java.lang.String getMirrorDirectory()
           
 java.lang.String getMirrorHostName()
          Ubuntu repository mirror, meaning the ISO image.
protected  org.kohsuke.loopy.FileEntry getTftpIsoMountDir(org.kohsuke.loopy.iso9660.ISO9660FileSystem fs)
          Directory inside the ISO file that gets "mounted" to TFTP.
 
Methods inherited from class hudson.plugins.pxe.LinuxBootConfiguration
createResolver, getPxeLinuxConfigFragment, serveMacroExpandedResource, tftp
 
Methods inherited from class hudson.plugins.pxe.IsoBasedBootConfiguration
doImage, doIndex, getDescriptor, getDisplayName, getRelease
 
Methods inherited from class hudson.plugins.pxe.BootConfiguration
all, getAbsoluteUrl, getId, getResourceAsStream, getSearchUrl, getUrl, shutdown
 
Methods inherited from class hudson.model.AbstractModelObject
getSearch, getSearchIndex, getSearchName, makeSearchIndex, requirePOST, sendError, sendError, sendError, sendError, sendError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

additionalPackages

public final java.lang.String additionalPackages

userName

public final java.lang.String userName

password

public final java.lang.String password

lateCommand

public final java.lang.String lateCommand

customMirror

public final java.lang.String customMirror

userContent

public final java.lang.String userContent
User-defined preseed content. Useful to override default settings

Constructor Detail

UbuntuBootConfiguration

@DataBoundConstructor
public UbuntuBootConfiguration(java.io.File iso,
                                                    java.lang.String userName,
                                                    java.lang.String password,
                                                    java.lang.String additionalPackages,
                                                    java.lang.String lateCommand,
                                                    java.lang.String customMirror,
                                                    java.lang.String userContent)
Method Detail

getIdSeed

protected java.lang.String getIdSeed()
Description copied from class: BootConfiguration
Returns the string that becomes the seed of the BootConfiguration.getId(). The ID is in turn used for HTTP URLs and TFTP file names, so this method should return something stable and not entirely illegible. But avoid unsafe characters like spaces, '/', etc. A good example would be "OpenSolaris2008.11" or "Ubuntu8.10".

Several BootConfigurations can return the same ID seed, and BootConfiguration.getId() handles those situations correctly.

Specified by:
getIdSeed in class BootConfiguration

getTftpIsoMountDir

protected org.kohsuke.loopy.FileEntry getTftpIsoMountDir(org.kohsuke.loopy.iso9660.ISO9660FileSystem fs)
                                                  throws java.io.IOException
Description copied from class: LinuxBootConfiguration
Directory inside the ISO file that gets "mounted" to TFTP. Used normally to serve kernel and initrd.

Specified by:
getTftpIsoMountDir in class LinuxBootConfiguration
Returns:
null if no directory from ISO is mount to tftp.
Throws:
java.io.IOException

doPreseed

public void doPreseed(org.kohsuke.stapler.StaplerResponse rsp)
               throws java.io.IOException
Serves the preseed file

Throws:
java.io.IOException

getMirrorHostName

public java.lang.String getMirrorHostName()
                                   throws java.io.IOException
Ubuntu repository mirror, meaning the ISO image.

Throws:
java.io.IOException

getMirrorDirectory

public java.lang.String getMirrorDirectory()
                                    throws java.io.IOException
Throws:
java.io.IOException

doLateCommand

public void doLateCommand(org.kohsuke.stapler.StaplerResponse rsp)
                   throws java.io.IOException
Throws:
java.io.IOException


Copyright © 2010. All Rights Reserved.