Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTTP 500 response connecting CCTray to CC.NET server via dashboard via RawXmlMessage.aspx

I'm using CC.NET 1.6 server and its corresponding CCTray connecting happily via remoting but need to change to use the dashboard connection via HTTP so that I can start farming the URL out to developers.

Putting my dashboard URL into CCTray:

http://localhost/CruiseControl/server/local/ViewServerReport.aspx

Results in CCTray returning

Failed to connect to server: The remote server returned an error: (500) Internal Server Error.

If I check my IIS logs, I can see the request was turned into a POST to this location and the log confirms the 500 response.

/CruiseControl/server/local/ViewServerReport.aspx/server/localhost/RawXmlMessage.aspx

If I navigate to that URL via GET - I get some Xml with error "Unable to process error: Root element is missing". This could be an artifact of me doing a GET instead of a POST of course.

Note: Yes I am using localhost in the URL as it is all contained on the one machine at the moment, if I can get this to work then I will of course change to use better hostname.

like image 479
fiat Avatar asked Mar 07 '12 00:03

fiat


1 Answers

Worked this out after upgrading to cc.net 1.8

1) Check dashboard.config for server name

Use fiddler to watch the request go through and observe the dashboard server name

http://localhost/CruiseControl/server/yourdomain.com/ViewServerReport.aspx

In the above case it is yourdomain.com

Open your dashboard.config and make sure there is an entry with the same name

<server name="yourdomain.com" url="tcp://localhost:21234/CruiseManager.rem" allowForceBuild="true" allowStartStopBuild="true" backwardsCompatible="false" />

2) Check IIS request validation

Check your application pool for Cruise Control's IIS. If it is .NET 4.0 then you need this in your web.config

<httpRuntime requestValidationMode = "2.0" />

That config is sitting in cc.net 1.8 web.config but needs uncommenting

3) Try again, you should be good - if not observe responses in fiddler

like image 95
fiat Avatar answered Oct 23 '22 08:10

fiat