Deploying ASP.NET MVC 5 Application to Win Server 2008 - c#

I would like to test my ASP.NET MVC application on my tablets and phones on my home local network.
How would I access the website from such devices?
Is it possible to deploy the application to some folder on my Win Server VM and then access the folder by typing that URL in mobile web browsers such as Safari?
Has anyone done this?

I will offer up 2 possible solutions here.
Learn how to deploy your app to a web server. Here is a microsoft article explaining how to do this at home, in a relatively quick way, and learning skills you may need in the future.
This is the best way if you need to learn more about deploying. it should get easier each time you do it:
http://www.asp.net/mvc/tutorials/deployment/visual-studio-web-deployment/deploying-to-iis
Leech off your development instance, which requires traffic to come in on localhost/127.0.0.1 which will require a traffic-redirector / port-forwarder on your host instance(your developement web server on your host instance has a 'code name', its called Cassini!, its good to know this name when researching about it...) Look at this link, and remember that your IP Address and Port number is most likely not the same as the one in the solution:
Debugging ASP.NET MVC3 application hosted on Local IIS Webserver
...dont forget about your windows firewall, too...

Related

How to setup a development environment for UCMA Lync bot?

I have to create a Lync 2010 bot. The initial idea that I pitched for the development purposes was to create the application on my own laptop and add the application as a trusted application endpoint to the production lync server. In that way I can develop and test the bot on my machine.
But, this idea was not highly encouraged by Microsoft themselves and they recommended to create a development lab environment to develop the application. I have done my fair share of research and have come to conclusion of adding 2 VMs -
1) 1st VM will serve as the AD server. My question is, what all things/roles should be added to this server like DHCP, DNS, IIS etc.?
2) 2nd will be Lync Server. Here I will create the connection with the AD server. Again, how will the connection be done? What extra roles should this server fulfill?
3) My laptop will act as the application server and I will add my laptop and the application as an application endpoint to the Lync server. Can I create all the three things on a single VM and not worry about multiple VMs?
4) Do I need an exchange server? If yes then why?
Any help is appreciated. Thanks.

How to run my asp.net web application on another computer along with my SQL database

Even though there are many variations of my question, none that I found address my exact issue. I have created an asp.net web application in C# using Visual Studio. I done this on my home desktop and this week I have to show my professor my application working on the lab computers at my University.
What is the best way to do this, bearing in mind I need my app along with my SQL database (that I created using Visual Studio also).
Thank you in advance for any help or advice!
The best way you can do this is set-up your website via IIS. With this, you can host your project via LAN set-up. To know more on how you can set-up your site via IIS, you can check: https://msdn.microsoft.com/en-us/library/ms178477.aspx
If you want online, you can host it via AppHarbor which you can host your project for free, and you can now access your website via internet, not just LAN.

Can we deploy ASP.Net Web Applications on a Client Computer like a Software?

I have tried looking for a way in which we can deploy a web application on a clients computer like a software and of methods in which we can update that web application. I have given the whole scenario below.. Any suggestions / recommendations in best architecture to use are also welcome!
If you have 1000 Users for Your Application They all need a working local(IIS server) to run your app on browser ,as was well as a Sql server to store local data while user in offline, i think this is too expensive,...i don't have idea about any other alternative
deploy website on local iis
MSDN

Asp.net Website is only accessible on our company internet connection and not from other network

I am not sure if I am posting this in the correct section?
I have released my asp.net website yesterday on our server, everything went well, I can access the website and even on my phone (connected to company WIFI). When I disconnected from the WIFI on my phone and went back to my standard network, it takes forever to load and eventually just says:
Internet could not load the web page because [website] took to long to respond. The website may be down or you may be experiencing issues with your Internet connection
This was quite strange, I then re-enabled my WIFI on my phone, and viola, I have full access to the website and all features are working. The same issue is happening when I tried to access the site from my home computer.
I am using MVC 3. SSL is enabled on the application.
I had a basic Asp.Net web application which just showed the look and feel to please the clients. That I released the same as this and I could access it anywhere from external or internal networks, so it is really strange. Am I missing a step?
The weirdest part for me is that it works at my company, but I cannot access it from out side. The IIS on the server's binding setting for this application is also set to HTTPS on port 443.
Please let me know if you require more information as I will try my best to provide it.
Thanks in advance!
So the issue was as Punit Ganshani MVP asked. The firewall at our server house only allowed http and once https was added to the list the site worked instantly.
Thanks for the suggestion. This was my first asp.net project so i just assumed that I messed something up in the code or the project itself.

Creating a Web Server container to emulate an IIS server

Okay, I'm a very green developer (co-op student) so I'll try my best to make sense. Currently I have a web application (call it "Updater") that is an aspx and runs through IIS. My boss has asked my to look into creating a program (exe or command line) that can run the app through created encapsulated web server that can act like IIS. This is so that I can run the exe during an installer procedure on a client's machine so that the updater can configure the client's program.
So Far I've looked into sources upon sources on how to create a self hosted web server to handle a web app and I've managed to do the following:
-Create a command line server hosted at a given port #######.
-Use a StreamReader to read an html file
-Use HttpResponseMessage to set the Content to this html page.
Obviously this is very rudimentary, but I couldn't understand how to switch the app over to the server I created rather than the IIS.
Any help ont he matter would be appreciated, like I said I'm still quite new.
You can use OWIN to self host from within a console application.
Look for 'Self-Host OWIN in a Console Application' in the following link:
http://www.asp.net/aspnet/overview/owin-and-katana/getting-started-with-owin-and-katana
You need to start you self host server with the address your app is trying to contact. If your IIS is running with the default settings it should be http://localhost:80. Before you start the self host server you need to shut down your IIS website that is running on port 80. Two applications can not listen on the same port at the same time.
What you ask is a redistributable web server for ASP.NET. So, you might find interesting the UltiDev Web Server, formerly known as Cassini web server.
From their website:
UltiDev Web Server Pro (UWS) is an advanced, redistributable web server for Windows that can be use as a regular web server to host web sites and ASP.NET applications, or packaged with your ASP.NET web application and installed on your customers' systems along with your web app or site.

Categories