Skip to content

Commit b037d3b

Browse files
committed
work
1 parent ef17215 commit b037d3b

File tree

1 file changed

+14
-7
lines changed

1 file changed

+14
-7
lines changed

aspnetcore/host-and-deploy/visual-studio-publish-profiles.md

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,12 @@ By [Sayed Ibrahim Hashimi](https://github.com/sayedihashimi) and [Rick Anderson]
1616

1717
This document focuses on using Visual Studio 2022 or later to create and use [publish profiles](/visualstudio/deployment/publish-overview). The publish profiles created with Visual Studio can be used with MSBuild and Visual Studio. For instructions on publishing to Azure, see <xref:tutorials/publish-to-azure-webapp-using-vs>.
1818

19-
See [Overview of Visual Studio Publish](/visualstudio/deployment/publish-overview), which contains the most current information on publishing with Visual Studio.
19+
For the most current and detailed information on:
20+
21+
* Publishing with Visual studio, see [Overview of Visual Studio Publish](/visualstudio/deployment/publish-overview)
22+
* MSBuild, see [MSBuild](/visualstudio/msbuild/msbuild-introduction)
23+
* Publishing with MSBuild, see [Microsoft.NET.Sdk.Publish](https://github.com/dotnet/sdk/tree/main/src/WebSdk#microsoftnetsdkpublish)
24+
* MSBuild, see [MSBuild](/visualstudio/msbuild/msbuild-introduction)
2025

2126
The `dotnet new mvc` command produces a project file containing the following root-level [\<Project> element](/visualstudio/msbuild/project-element-msbuild):
2227

@@ -104,7 +109,7 @@ dotnet publish -c Release -o C:\MyWebs\test
104109

105110
The `dotnet publish` command calls MSBuild, which invokes the `Publish` target. Any parameters passed to `dotnet publish` are passed to MSBuild. The `-c` and `-o` parameters map to MSBuild's `Configuration` and `OutputPath` properties, respectively.
106111

107-
MSBuild properties can be passed using either of the following formats:
112+
[Project properties](/visualstudio/msbuild/msbuild-command-line-reference) can be passed using either of the following formats:
108113

109114
* `-p:<NAME>=<VALUE>`
110115
* `/p:<NAME>=<VALUE>`
@@ -128,11 +133,10 @@ Create a publish profile in Visual Studio by choosing one of the following paths
128133
* Right-click the project in **Solution Explorer** and select **Publish**.
129134
* Select **Publish {PROJECT NAME}** from the **Build** menu.
130135

131-
The **Publish** tab of the app capabilities page is displayed. If the project lacks a publish profile, the **Pick a publish target** page is displayed. You're asked to select one of the following publish targets:
136+
The **Publish** tab of the app capabilities page is displayed. Several publish targets are available, including:
132137

133-
* Azure App Service
134-
* Azure App Service on Linux
135-
* Azure Virtual Machines
138+
* Azure
139+
* Docker Container Registry
136140
* Folder
137141
* IIS, FTP, Web Deploy (for any web server)
138142
* Import Profile
@@ -148,7 +152,10 @@ Visual Studio's publish tool produces a `Properties/PublishProfiles/{PROFILE NAM
148152
* Contains publish configuration settings and is consumed by the publishing process.
149153
* Can be modified to customize the build and publish process.
150154

151-
When publishing to an Azure target, the *.pubxml* file contains the Azure subscription identifier. With that target type, adding this file to source control is discouraged. When publishing to a non-Azure target, it's safe to check in the *.pubxml* file.
155+
When publishing to an Azure target, the *.pubxml* file:
156+
157+
* Contains the Azure subscription identifier.
158+
* Should not be checked into source control because the subscription identifier is sensitive information.
152159

153160
Sensitive information, for example, the publish password, is encrypted on a per user/machine level. The `Properties/PublishProfiles/{PROFILE NAME}.pubxml.user` file contains the information needed by MSBuild to retrieve the user name and password.
154161

0 commit comments

Comments
 (0)