8

How can I access all the files that are deployed from Visual Studio into Azure? I am creating a bot using bot framework which I then publish. But, when I go to review the code online I can't see all the files via the App Service Editor/Kudu/etc. The can't locate the files navigating the site directory.

Does anyone know?

2 Answers2

7

You can enter the site's "Kudu" dashboard, using the url format

http://<yoursitename>.scm.azurewebsites.net

This will give you a web-based dashboard, including a debug console (web-based) where you can explore your various directories

or

In Visual Studio, in the window "Server Explorer" you click and connect on "Azure".

=> App Service=> Your site name => Files

Here you see all your files and you can edit them directly in Visual Studio.

Sajeetharan
  • 216,225
  • 63
  • 350
  • 396
  • 1
    the issue isn't accessing where the files would be located. It's that not all files are visible despite the app still working. I need to know if there is a way to get all the files to show after deploying. I'll edit my question to reflect that. Thanks. – botsbotsbotsbots Jun 29 '18 at 18:06
2

Web Applications do not generally have the source code included when published. Web Site projects, on the other hand do. More information can be found here: https://msdn.microsoft.com/en-us/library/dd547590(v=vs.110).aspx#Anchor_1

If you want to include the source code during the publish process, this can be done with a Post Deploy Script:

In the .csproj:

  <Import Project="PostDeployScripts\IncludeSources.targets" Condition="Exists('PostDeployScripts\IncludeSources.targets')" />

IncludeSources.targets:

<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <CoreCompileDependsOn>$(CoreCompileDependsOn);IncludeSource</CoreCompileDependsOn>
  </PropertyGroup>  
  <Target Name="IncludeSource">
    <ItemGroup>
      <Content Include="**\*.cs" />
      <Content Include="**\*.csproj" />
      <Content Include="PostDeployScripts\*.*" />
    </ItemGroup>
  </Target>
</Project>
Eric Dahlvang
  • 8,252
  • 4
  • 29
  • 50