private boolean distributedBuildEnabled;
public void prepare()
{
ConfigurationService configuration = getContinuum().getConfiguration();
File workingDirectoryFile = configuration.getWorkingDirectory();
if ( workingDirectoryFile != null )
{
workingDirectory = workingDirectoryFile.getAbsolutePath();
}
File buildOutputDirectoryFile = configuration.getBuildOutputDirectory();
if ( buildOutputDirectoryFile != null )
{
buildOutputDirectory = buildOutputDirectoryFile.getAbsolutePath();
}
File deploymentRepositoryDirectoryFile = configuration.getDeploymentRepositoryDirectory();
if ( deploymentRepositoryDirectoryFile != null )
{
deploymentRepositoryDirectory = deploymentRepositoryDirectoryFile.getAbsolutePath();
}
baseUrl = configuration.getUrl();
if ( StringUtils.isEmpty( baseUrl ) )
{
HttpServletRequest request = ServletActionContext.getRequest();
baseUrl = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() +
request.getContextPath();
logger.info( "baseUrl='" + baseUrl + "'" );
}
File releaseOutputDirectoryFile = configuration.getReleaseOutputDirectory();
if ( releaseOutputDirectoryFile != null )
{
releaseOutputDirectory = releaseOutputDirectoryFile.getAbsolutePath();
}
numberOfAllowedBuildsinParallel = configuration.getNumberOfBuildsInParallel();
if ( numberOfAllowedBuildsinParallel == 0 )
{
numberOfAllowedBuildsinParallel = 1;
}
String requireRelease = ServletActionContext.getRequest().getParameter( "requireReleaseOutput" );
setRequireReleaseOutput( Boolean.valueOf( requireRelease ) );
distributedBuildEnabled = configuration.isDistributedBuildEnabled();
}