Looking for a lite way IIS server for demostrating website - asp.net

I need to show customer an ASP.NET MVC3 website, but they don't have IIS or Visual Studio installed. only .NET Framework 4 is installed.
So my question is: Is there any tiny little IIS server (like IIS Express), but don't require installation, that can run the compiled site just on local machine?
PS: I don't need advanced features. But HttpHanlders and HttpModules should be working fine.

I back Shan's suggestion to host your website on a server somewhere and access it over the Internet. I don't see why it wouldn't work for Intranet applications either unless you have dependencies on some services like SMB shares or network printers.
The Cassini ASP.NET webserver is portable and doesn't require installation, but it doesn't run the same as IIS and there are things that will break (because it invokes ASP.NET for every request unlike IIS, so if you've blocked unauthenticated visitors then they wouldn't be able to download site images and stylesheets, for example, until they've logged in).

Related

How to run asp.net WebForms published site locally from visual studio code

How to open a published webform site from within visual studio code. opening and running the default.aspx in browser locally
The site is published by Visual Studio 2019 ( not Visual Studio Code ) to local folder, I want to open and run that published site from another computer having Visual Studio Code only.
Well, to run, show and display a web site, you need to have a web server installed, and then up and running on that computer.
You then need to configure the web server, and what folder or where the web site is published to. However, for reasons of security, often the folders that the web site can see (or use) is VERY restricted. I mean, do you want the whole world messing around in folders on that computer? (not!!!!).
You then need to open up the fire walls, and set rules to allow external use of that given computer.
Now, it turns out, that Visual Studio is able to "debug + launch" your web site during development. This works be having installed a light weight (stripped down) version of a Web server.
So, VS uses what is called IIS Express. It does have VERY high degree of compatibility with IIS
So full version = IIS (Internet Information Services)
Light version = IIS (Internet Information Services Express).
So then, the REAL question is can you setup + use IIS Express (that is ALREADY installed on your computer as a result of installing VS)?
The answer is yes, but it is REALLY but REALLY painfull.
And the reason why? Well, to run + launch IIS express for JUST you the developer, then things like security, rights policies, file access, is http and https etc. setup? Well that is a HUGE FAT BOOK of reading and a HUGE FAT BOOK of massive amounts of configuring required to setup + run a whole web server.
I mean, you do have web.config. But the sheer mass of options available is quite a challenge to setup.
And IIS express does NOT have the main setup and configuring screens included.
So, for hitting f5 to run from Visual Studio? great!!!
But, you need screens like this:
And from above, we have a LOT of stuff:
So, the problem is that IIS Express does NOT include the above management screens.
So, this means that YOU HAVE to edit web config and other config files that are required to run + setup IIS.
Now, to be fair, you could just run with the SAME defaults that VS uses when you hit F5 to run. But the configuring of the web site can be a hassile. (for example, did and do you know WHERE to set the IP address of the web site?
When you run local, then VS uses "localhost". But for anyone else on the network, they now have to use that computers IP address, and then YOU must setup the web server to accept requests to that IP address. And you don't even have to use + give the web server the same IP address as the computer hosting IIS.
So, you CAN use IIS Express, but it going to be panful beyond ANY thing but using IIS Express for debugging your web site on the SAME computer running VS. Remember when running IIS on the SAME developer computer, then you are the "owner" or what we call 'super user' of your OWN computer. But, I can't just start opening files and using YOUR computer right now, can I? (see the difference!!! - allowing OHTERS to use your computer is a really big deal.
But, yes, you can get IIS Express to work. it just that IIS Express is MISSING all the above management screens. (and that above screen shot shows that each one of those icons when chosen is a "big maze" of options.
To get this to work can be done.
I don't have a good reference, and you have to google it, and then with a pot of coffee, read away, since without the configing menus and systems above, you find this to be difficult.
Here is one such article on how to do this:
https://blogs.blackmarble.co.uk/rfennell/2011/03/22/how-to-expose-iis-express-to-external-network-connections-and-use-a-non-self-signed-certificate/#:~:text=%20How%20to%20expose%20IIS%20Express%20to%20external,You%20now%20need%20to%20just%20start...%20More%20

Page is not accessible when I close Webmatrix

I have a server (devserv) with Webmatrix installed. Under settings, I modified the URL so it's now http://devserv:8888.
That allows me to access the 2 sites that I'm working on.
However, that works only I have Webmatrix open. When I close it, the sites are not accessible.
They are not accessible locally either, btw, but I'm giving you the full picture just in case.
The error that I get is that the web.config cannot be read to do insufficient rights.
However, all domain users have the right to read and execute on the folder that contains the sites and I checked the rights go down the tree.
So the question is what am I doing wrong, and why when Webmatrix is open, then there is no problem.
This is a Windows 2008 R2 server Standard and IIS is 7.5.7600.16385
WebMatrix only starts up the IIS Express server for a given site while you are editing it (with WebMatrix open). When you close WebMatrix, we shut down the IIS Express process. IIS Express is really only meant to be used during development time - if you want the site to continue to be available, I'd suggest installing full IIS on it, and using WebMatrix publishing to push your files to the server with Web Deploy.
Hopefully this helps!

IIS6 isn't supported by powershell and upgrades cost money. Alternatives?

As part of our .NET deployment process we'd like to make a new website on IIS. The idea is to be able to run another set of smoke tests before making a site live - plus being able to immediately roll back to a previous version should something go wrong. We hope to have this all hooked up to Jenkins.
While IIS7 has a comprehensive suite of tools that allows us to throw together and configure a new website via PowerShell, IIS6 shares no such luxury.
While upgrading to IIS7 would obviously solve our issues, our servers currently run on Windows 2003.
Is there a way to do what we want in IIS6? Are we going about the issue the wrong way?
IIS6 configuration is stored in 2 xml files, MetaBase.xml and MSSchema.xml located in %SystemRoot%\System32\Inetsrv.
Check these links about available scripts for managing IIS sites, application pools etc:
Internet Information Services (IIS) 6.0 Resource Kit Tools
Managing IIS Configurations Using Scripts (IIS 6.0)
Administering Servers from the Command Line in IIS 6.0 (IIS 6.0)
How to manage Web sites and Web virtual directories by using command-line scripts in IIS 6.0
Regarding configuration of sites like default page, .NET version etc I couldn't find any script for that on Technet. But if it is in configuration xml, I think you can create some command line tool for that.

ASP.NET MVC intranet site deployment

Howcome I deploy my intranet ASP.NET MVC project?
What I've got so far:
project itself;
several client machines connected in a workgroup and server;
IIS Express 7.5, SQL Server 2008 R2 Express installed on a server.
It should be mentioned that though it's odd and unusual but server is just a machine without (even) server OS installed. Please note that it's not mine idea and is the environment I've got at the moment
I've read the instruction http://msdn.microsoft.com/en-us/library/gg703322(VS.98).aspx but it describes situation when you have Web Developer installed on the same machine.
Please help!
And Thanks!
This is the 100% manual approach, you might be able to access the remote web server via VS if authorization/permissions is lined up properly (much simpler, basically you just hit deploy):
Install IIS
Install .NET Framework 4
Install MVC
Register ASP.NET with IIS (just to be safe run it again)
Create Website via IIS Management Console (use a new directory for the website)
Put your files inside the new directory
Make sure permissions are setup properly
That's it

How to run a leightweight ASP.NET MVC application that would be accessible only locally (not on IIS)?

We have a desktop client application and recent customer requests indicate that they would like to have some dynamic HTML content served and displayed by the application.
We are considering hosting a simple ASP.NET application in a local process, accessible only from the local machine (similar to the ASP.NET development web server used when debugging from Visual Studio).
How can we run an ASP.NET application locally without IIS? IIS is not an option because most client machines will not have it installed.
Is there a leightweight ASP.NET web server that could run locally similar to the development web server that VS is using?
I have found some information about "Cassini". Is this suitable for production use? Can it handle ASP.NET MVC? Are there any alternatives we should consider?
I have not used it myself, but you can try the mono XPS server.
It is a stand alone webserver.
The easiest way to start XSP is to run it from within the root directory of your application. It will serve requests on port 8080. Place additional assemblies in the bin directory.
Cassini is in fact also a good option - it is the development web server that comes with visual studio (so widely distributed, used and tested) and is also used by the open source ScrewTurnWiki. See wikipedia.
In regards to your "only locally" requirement - a web server will serve any request made to the right port. In order to limit accessibility, you should use a firewall that will block any external requests.
You might consider using WCF to host a service on the local machine that can serve the data without having to host a full blown web server.
If you do this, WCF allows you to expose the service with multiple endpoints and make it available through HTTP, TCP, or Namepipes. Namepipes would restrict traffic to only the local machine.
I have also tried IIS Express. It works great with ASP.NET MVC. Right now it is available only with Web Matrix, but installing web matrix is easy.
Coming back to this question three years later, ServiceStack.NET with self-hosted option seems like a good choice. While it is not ASP.NET MVC directly, it provides a good API and features are on par with ASP.NET MVC/WebAPI (or in some ways better).

Resources