2015-04-18 03:00:17 +08:00
Installing ASP.NET 5 On Windows
===============================
2015-05-21 13:56:17 +08:00
2015-11-12 14:15:20 +08:00
By `Rick Anderson`_ , `Steve Smith`_ , `Daniel Roth`_
2015-11-14 15:45:28 +08:00
This page shows you how to install ASP.NET 5 on Windows. To run ASP.NET 5 apps on IIS, see :doc: `/publishing/iis` .
2015-11-12 14:15:20 +08:00
2015-11-14 15:45:28 +08:00
.. contents :: In this article:
:local:
:depth: 1
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
Install ASP.NET 5 with Visual Studio
------------------------------------
2015-04-18 03:00:17 +08:00
2015-10-20 06:00:32 +08:00
The easiest way to get started building applications with ASP.NET 5 is to install the latest version of Visual Studio 2015 (including the free Community edition).
2015-09-15 00:03:10 +08:00
2015-11-19 04:50:31 +08:00
1. Install `Visual Studio 2015 <https://go.microsoft.com/fwlink/?LinkId=532606> `__
2015-04-18 03:00:17 +08:00
2015-10-28 14:59:30 +08:00
Be sure to specify that you want to include the Microsoft Web Developer Tools.
2015-04-18 03:00:17 +08:00
2015-10-28 14:59:30 +08:00
.. image :: installing-on-windows/_static/web-dev-tools.png
2015-10-20 06:00:32 +08:00
2015-11-19 04:50:31 +08:00
2. Install `ASP.NET 5 <https://go.microsoft.com/fwlink/?LinkId=627627> `_ .
2015-11-14 15:45:28 +08:00
This will install the latest ASP.NET 5 runtime and tooling.
3. Enable the ASP.NET 5 command-line tools. Open a command-prompt and run::
2015-09-26 03:22:10 +08:00
2015-10-28 15:20:18 +08:00
dnvm upgrade
2015-09-26 03:22:10 +08:00
2015-11-14 15:45:28 +08:00
This will make the default :doc: `/dnx/index` active on the path.
4. On Windows 7 and Windows Server 2008 R2 you will also need to install the `Visual C++ Redistributable for Visual Studio 2012 Update 4 <https://www.microsoft.com/en-us/download/confirmation.aspx?id=30679> `__ .
You are all set up and ready to write :doc: `your first ASP.NET 5 application </tutorials/your-first-aspnet-application>` !
2015-09-26 03:22:10 +08:00
2015-11-14 15:45:28 +08:00
Install ASP.NET 5 from the command-line
---------------------------------------
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
You can also install ASP.NET 5 from the command-line. There are a few steps involved, since we'll need to install and configure the environment in which ASP.NET runs, the :doc: `/dnx/index` . To install DNX, we need one more tool, the .NET Version Manager (DNVM).
2015-04-18 03:00:17 +08:00
Install the .NET Version Manager (DNVM)
2015-04-28 14:03:00 +08:00
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2015-04-18 03:00:17 +08:00
2015-09-19 05:21:11 +08:00
Use .NET Version Manager to install different versions of the .NET Execution Environment (DNX).
2015-04-30 20:56:03 +08:00
2015-09-19 05:21:11 +08:00
To install DNVM open a command prompt and run the following::
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "&{$Branch='dev';iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/aspnet/Home/dev/dnvminstall.ps1'))}"
2015-04-18 03:00:17 +08:00
2015-09-19 05:21:11 +08:00
Once this step is complete you should be able to run `` dnvm `` and see some help text.
2015-04-18 03:00:17 +08:00
Install the .NET Execution Environment (DNX)
2015-04-28 14:03:00 +08:00
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2015-04-18 03:00:17 +08:00
2015-09-19 05:21:11 +08:00
The .NET Execution Environment (DNX) is used to build and run .NET projects. Use DNVM to install DNX for the full .NET Framework or for .NET Core (see :doc: `choosing-the-right-dotnet` ).
2015-11-14 15:45:28 +08:00
**To install DNX for .NET Core:**
1. Use DNVM to install DNX for .NET Core::
dnvm upgrade -r coreclr
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
**To install DNX for the full .NET Framework:**
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
1. Use DNVM to install DNX for the full .NET Framework::
2015-04-18 03:00:17 +08:00
2015-11-14 15:45:28 +08:00
dnvm upgrade -r clr
2015-04-18 03:00:17 +08:00
2015-09-19 05:21:11 +08:00
By default DNVM will install DNX for the full .NET Framework if no runtime is specified.
2015-04-18 03:00:17 +08:00
Related Resources
2015-11-14 15:45:28 +08:00
-----------------
2015-04-18 03:00:17 +08:00
2015-09-15 00:03:10 +08:00
- :doc: `/tutorials/your-first-aspnet-application`
2015-09-19 05:21:11 +08:00
- :doc: `/fundamentals/index`
2015-04-18 03:00:17 +08:00
2015-10-20 06:00:32 +08:00