Olivier De Meulder
Olivier De Meulder

Reputation: 2501

Publish .NET Website with nuget package via FTP

I have a website hosted on a dedicated windows server. The application is pretty big (hundreds of pages) and has been around for over 10 years. Historically, I have always used FTP to publish the website. Effectively only moving the pages that I want moved to production.

I am a bit confused with the NUGET packages. As you install them files get copied / installed in your application. How do I safely install a NUGET package and make sure I move all the necessary files to production?

Will a NUGET install ever make changes to files such as web.config?

Upvotes: 0

Views: 754

Answers (1)

drneel
drneel

Reputation: 2907

To answer your first question: The simplest way to handle this is to right click on your web project and click publish. This will give you all of your publish options. Depending on your visual studio version you may see slightly different UIs.

One of the options that is available is FTP; just enter all of the information and it will build the project and deploy it along with all of its dependencies for you.

Here is a MSDN One-Click Publish Article that walks you through the process.

To answer your second question: Yes, some Nuget packages make changes to the web.config. For example, some of the logging packages (NLog, Log4Net) made changes to the web.config the last time I used them.

Upvotes: 1

Related Questions