Hi
CCNet does not support what you are trying to do:
<property name="buildinfo"
value="${env.CCNETPROJECT}_${env.CCNETNUMERICLABEL}" />
you can use the pre-processor to achieve some control over the config file,
http://confluence.public.thoughtworks.org/display/CCNET/Configuration+Preprocessor
but you can not use something like ${env.CCNETNUMERICLABEL}"
inside ccnet.config.
these values are calculated when the project is running, and can not be
passed to a task or so from the config.
they are automatically passed to the exec task for instance.
with kind regards
Ruben Willems
On Mon, Apr 6, 2009 at 6:14 PM, mac taylor <[email protected]> wrote:
> Morning,
>
> I am getting the following error when trying to start the cc.net server.
> It is complaining about the built-in environment variables that I am
> referencing. Pardon the long e-mail since i am including the error and the
> ccnet.config contents also. Thanks in advance.
>
>
> MT
>
>
>
> *error:*
>
> 2009-04-06 09:01:50,859 [CCNet Server:DEBUG] The trace level is currently
> set to debug. This will cause CCNet to log at the most verbose level, which
> is useful for setting up or debugging the server. Once your server is
> running smoothly, we recommend changing this setting in C:\Program
> Files\CruiseControl.NET\server\ccnet.exe.config to a lower level.
> *2009-04-06 09:01:50,875 [CCNet Server:INFO] Reading configuration file
> "C:\Program Files\CruiseControl.NET\server\ccnet.config"
> 2009-04-06 09:01:50,984 [CCNet Server:ERROR] Exception: Duplicate node
> detected: <property name="buildinfo"
> value="${env.CCNETPROJECT}_${env.CCNETNUMERICLABEL}" />
> ----------
> ThoughtWorks.CruiseControl.Core.Config.ConfigurationException: Duplicate
> node detected: <property name="buildinfo"
> value="${env.CCNETPROJECT}_${env.CCNETNUMERICLABEL}" />
> *
>
>
>
>
>
>
> *ccnet.config contents:*
>
> <cruisecontrol>
> <!-- This is your CruiseControl.NET Server Configuration file. Add your
> projects below! -->
>
> <project name="LIB_HRMB-CI" queue="liberty_harambee" queuePriority="10">
> <webURL>
> http://NASJ1LHHNTTF1/ccnet/server/NASJ1LHHNTTF1/project/LIB_HRMB-CI/ViewProjectReport.aspx
> </webURL>
>
> <workingDirectory>D:\Integration\LIB_HRMB-CI\WorkingDirectory</workingDirectory>
>
> <artifactDirectory>D:\Integration\LIB_HRMB-CI\Artifacts</artifactDirectory>
> <modificationDelaySeconds>10</modificationDelaySeconds>
> <property environment="env" toupper="true"/>
> <property name="buildinfo"
> value="${env.CCNETPROJECT}_${env.CCNETNUMERICLABEL}" />
> <property name="buildlogdir"
> value="C:\TEMP\logs\BuildLogs\ccnet\${buildinfo}" />
>
> <triggers>
> <intervalTrigger seconds="600" name="CI" initialSeconds="30" />
> </triggers>
> <!--<triggers/>-->
>
> <sourcecontrol type="clearCase">
>
> <viewPath>D:\snapviews\taylormx_liberty_harambee_main_snap\firmware</viewPath>
> <branch>liberty_harambee_main</branch>
> <autoGetSource>true</autoGetSource>
> <useLabel>false</useLabel>
> <useBaseline>false</useBaseline>
> <viewName>taylormx_liberty_harambee_main_snap</viewName>
> <executable>cleartool.exe</executable>
> <timeout>50000</timeout>
> </sourcecontrol>
>
> <!--
> <sourcecontrol type="filesystem">
>
> <repositoryRoot>D:\snapviews\taylormx_liberty_harambee_main_snap\firmware</repositoryRoot>
> <autoGetSource>false</autoGetSource>
> <ignoreMissingRoot>false</ignoreMissingRoot>
> </sourcecontrol>
> -->
> <tasks>
>
> <exec>
> <!-- <executable>c:\WINDOWS\system32\cscript.exe</executable> -->
> <executable>cmd /c
> D:\snapviews\taylormx_liberty_harambee_main_snap\cm\firmware_utils\lbty_hrmb_build.bat</executable>
>
> <baseDirectory>D:\snapviews\taylormx_liberty_harambee_main_snap\cm\firmware_utils\</baseDirectory>
> <!-- <buildArgs>//Nologo
> D:\snapviews\taylormx_liberty_harambee_main_snap\cm\firmware_utils\build_fw.vbs
> -target cms</buildArgs> -->
> <buildArgs>placeholder</buildArgs>
> <buildTimeoutSeconds>3000</buildTimeoutSeconds>
> <successExitCodes>0,1,3,5</successExitCodes>
> <environment>
> <variable name="BUILD_TYPE" value="CI"/>
> </environment>
> </exec>
> </tasks>
>
> <publishers>
> <merge>
> <files>
>
> <file>D:\Snapviews\taylormx_liberty_harambee_main_snap\firmware\build_staging\logs\nunit_debug_results.xml</file>
>
> <file>D:\Snapviews\taylormx_liberty_harambee_main_snap\firmware\build_staging\logs\nunit_release_results.xml</file>
> <file>${buildlogdir}\build_fw_ccnet_${buildinfo}.log</file>
>
> <file>${buildlogdir}\build_fw_ccnet_${buildinfo}.err</file>
> </files>
> </merge>
> <xmllogger />
> <statistics />
> <modificationHistory onlyLogWhenChangesFound="true" />
> </publishers>
>
> </project>
>
> <project name="TEST" queue="liberty_harambee" queuePriority="20">
> <webURL>
> http://NASJ1LHHNTTF1/ccnet/server/NASJ1LHHNTTF1/project/TEST/ViewProjectReport.aspx
> </webURL>
>
> <workingDirectory>D:\Integration\TEST\WorkingDirectory</workingDirectory>
> <artifactDirectory>D:\Integration\TEST\Artifacts</artifactDirectory>
> <modificationDelaySeconds>10</modificationDelaySeconds>
> <property environment="env" toupper="true"/>
> <property name="buildinfo"
> value="${env.CCNETPROJECT}_${env.CCNETNUMERICLABEL}"
> unless="${property::exists('buildinfo')}"/>
> <property name="buildlogdir"
> value="C:\TEMP\logs\BuildLogs\ccnet\${buildinfo}"
> unless="${property::exists('buildlogdir')}"/>
>
>
> <triggers/>
>
> <sourcecontrol type="clearCase">
>
> <viewPath>D:\snapviews\taylormx_liberty_harambee_main_snap\firmware</viewPath>
> <branch>liberty_harambee_main</branch>
> <autoGetSource>false</autoGetSource>
> <useLabel>false</useLabel>
> <useBaseline>false</useBaseline>
> <viewName>taylormx_liberty_harambee_main_snap</viewName>
> <executable>cleartool.exe</executable>
> <timeout>50000</timeout>
> </sourcecontrol>
>
> <!--
> <sourcecontrol type="filesystem">
>
> <repositoryRoot>D:\snapviews\taylormx_liberty_harambee_main_snap\firmware</repositoryRoot>
> <autoGetSource>false</autoGetSource>
> <ignoreMissingRoot>false</ignoreMissingRoot>
> </sourcecontrol>
> -->
> <tasks>
>
> <exec>
> <executable>c:\WINDOWS\system32\cscript.exe</executable>
>
> <baseDirectory>D:\snapviews\taylormx_liberty_harambee_main_snap\cm\firmware_utils\</baseDirectory>
> <buildArgs>c:\build_test.vbs</buildArgs>
> <buildTimeoutSeconds>3000</buildTimeoutSeconds>
> <successExitCodes>0,3,5</successExitCodes>
> <!-- <environment>
> <variable name="BUILD_TYPE" value="CI"/>
> <variable name="BUILD_LABEL" value="${CCNetNumericLabel}"/>
> </environment>
> -->
> </exec>
> </tasks>
>
> <publishers>
> <merge>
> <files>
>
> <file>D:\Snapviews\taylormx_liberty_harambee_main_snap\firmware\build_staging\logs\nunit_debug_results.xml</file>
>
> <file>D:\Snapviews\taylormx_liberty_harambee_main_snap\firmware\build_staging\logs\nunit_release_results.xml</file>
> <file>${buildlogdir}/build_fw_ccnet_${buildinfo}.log</file>
> <file>${buildlogdir}/build_fw_ccnet_${buildinfo}.err</file>
> </files>
> </merge>
> <xmllogger />
> <statistics />
> <modificationHistory onlyLogWhenChangesFound="true" />
> </publishers>
>
> </project>
>
> </cruisecontrol>
>
>
>
>
>