Click here to Skip to main content
15,910,661 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Looking for a lightweight and simple way to self-host a website within a process such that a user from another machine can log in, update configuration save and view statuses. I'm really trying not to re-invent the wheel here - everything I've found so far is either web service or is over complex. I want something that appears to your browser just like a router configuration page.

The requirement is simple:
1) should run in the application (I'm not bothered about administration rights being required etc)
2) must provide a username and login page to protect the content.
3) should host a configuration page and a status page. The configuration page should write back to the program settings. Or serialize a configuration class, not really bothered.
4) would be nice if the settings page used reflection to generate the view working a bit like a propertygrid
5) some form of templating with perhaps an image like the code project would be nice

I know I could start with an asp website approach and host IIS service etc, I was looking for something much lighter weight. I looked at Cassini which seems to have snuffed it, Nancy - this looked good but the documentation for the Super Simple View thingy simply killed it for me with no examples that actually work. What I'm after is almost like an embeddedable host.

There has to be something somewhere that is almost good to go - I must just be searching for the wrong thing. I would have thought such a configuration web page would be useful for so many applications.

My usual application is image processing in windows forms, I have worked with ASP.Net websites briefly, but for this application, there is a such a fragmented and bewildering array of frameworks that I really don't know where to start.
Posted
Updated 23-Dec-13 22:58pm
v2
Comments
Nelek 24-Dec-13 4:25am    
What have you tried?[^], what is the question?
DrJaymz 24-Dec-13 4:50am    
I looked at Cassini, Nancy, Neokernel, Implementing it myself using HTTP requests stuff built in to the framework.
Looking for a lightweight and simple way to self-host a website within a process such that a user from another machine can log in, update configuration save and view statuses.

As I said, I really wanted to avoid reinventing the wheel and thought some such thing must already exist, but I must be googling the wrong thing as I haven't found anything suitable.

1 solution

Is this any help?
Simple HTTP Server in C#[^] - not used it myself, but it could do what you want.
 
Share this answer
 
Comments
DrJaymz 2-Jan-14 3:41am    
I didn't find that solution any use really. However, it did refer to another article. http://www.codeproject.com/Articles/25050/Embedded-NET-HTTP-Server

This was better, almost what I wanted, however, it was only really a piece of middleware that needed a lot of work to get even the demo working. The functions were inconsistent and contained some bugs that I'm not sure I could get around including some race conditions. So I asked if the author would provide an example in context. He agreed this would be useful.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900