Code package naming convention
The first step to use the API is to bundle your web application into a code package. Use the following conventions when you name a code package (a package containing Web App binaries, configuration and so on).
<app name>.<package type>.app.<version>.nupkg
- App name. Optional.
- Package types. Values are:
- cms (primary Web App)
- Version. You can specify in different ways such as using a "date format" or a version number.
Example code package names
(In this example, customer is the app name.)
Code package content
The package should contain the Web App-related files, and normally exists at the path D:\Home\Site on the actual Azure Web App.
Only folders and files related to the code are allowed (that is, wwwroot, applicationHost.xdt), and a metadata file (optional) that should follow the package name.
Sample folder structure
myapp.cms.app.1.0.0.nupkg wwwroot applicationSettings.json applicationSettings.Integration.json applicationSettings.Preproduction.json applicationSettings.Production.json myapp.dll ...... myapp.cms.app.nuspec (optional)
Environment configurations need to be a part of the code package.
You can download a CMS sample site (Alloy) package example here: alloy.cms.app.1.2.1.nupkg
Creating a code package
You can create a package by deploying to a folder and zipping this folder, as shown in the following example.
dotnet publish ~/projects/myapp/myapp.csproj
You can zip this folder (SitePackageContent in the example) as cms.app.1.0.0.nupkg to make it a deployment package that you can use in DXP.
Last updated: Sep 28, 2021