1

I've been working on an ASP.NET MVC3 website under VS2010 and I'm wondering how can I deploy it locally on my Windows 7 pc on IIS7.

1
  • Install IIS and make sure you install .NET 4 in your IIS. You can easily deploy it in your IIS through the project properties. Commented Jun 19, 2012 at 13:39

2 Answers 2

1

You can do it in the same way you do for an ASP.NET web application. There is no significance difference.

Right click on your project and select "Publish" option from the context menu. You can specify what way you want to publish (FTP, File System etc..) Lets select FileSystem and select a folder and Clicking on the publish button will drop the required files to that folder.

You can create a Site/Virtual directory under your IIS and specify the file location as the same folder where we published.

enter image description here

Sign up to request clarification or add additional context in comments.

3 Comments

Well thanks guys for your help , I'll try that and see what's gonne happen , even that I guess I tried already something like that but I'll follow your steps gentelmen ;)
Sorry for dissapointing you @Shyju but I got the following error "Can not read configuration file due to insufficient permissions"
@WLegend - See, you need to create the virtual directory having the permissions to Network Service given to it. Basically, whats happening is that there is an issue with permissions with your Virtual directory, the IIS is not able to read it due to that. So, we need to fix dat up ...
1

Dude its pretty simple .

Step 1 : Publish it.
Step 2 : Add this as a website
Step 3 : Go and change the current asp.net version as 4.0 of the app pool
Step 4 : Rejoice ! Its done !

Well if not then there is an issue regarding some error is coming then it is due to the .net 4.0 is not registered in iis . So try this :

  %windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -ir for 32 bit windows 
  

and

  %windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_regiis.exe -ir for 64 bit windows 
 

3 Comments

I think I need to grant a kind of permission to access the folder , since it can't access Web.config file
@bhuvin is your second answer really correct? Is it really for 32bit or 64bit? because in your first answer its also 32bit. :)
@bot - Sorry for the typo mistake. Yes its correct, It works for me. Thanks for pointing it out .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.