Web Deploy does not deploy index.cshtml

I have an ASP.NET website with a file index.cshtml

at the root. It is not tied to or tied to any controller, but only to a separate Razor file. Whenever I deploy this project to the Azure Website, it doesn't deploy this file.

However, it deploys portal.cshtml

to the same folder (root).

Is it because it expects files to be index.cshtml

ignored if not in a folder Views

? How can I deploy it?

+3


source to share


2 answers


The problem was that the build action was set to None

. I installed it in Content

and it worked. Credit goes to haim770's comment.



+6


source


The action of the assembly, probably set to None . Set it to Content .



+1


source







All Articles