-
Notifications
You must be signed in to change notification settings - Fork 3
Configuring
Applications will often require different configuration depending on where they are being deployed.
!!Configuring.md should be how to configuraiton application (which includes variables, scripts, etc.)!! appsettings / connection strings / scripts
As an example, consider an application configuration file for your application that is deployed with the application:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<appSettings>
<add key="debuglevel" value="WARN" />
<add key="databaseinstance" value="development" />
</appSettings>
</configuration>You can configure the application settings values at deployment time by passing them in when installing the package (or invoking a remote deployment):
Powerdeploy provides multiple ways...
appsettings...
Install-DeploymentPackage `
-PackageArchive SamplePackage_1.2.3.zip `
-Environment Integration `
-Variable @{ 'debuglevel' = 'ERROR'; 'databaseinstance' = 'integration' }When Powerdeploy installs the package, it will automatically replace the values in the application configuration file with the values supplied on the command line.
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<appSettings>
<add key="debuglevel" value="ERROR" />
<add key="databaseinstance" value="integration" />
</appSettings>
</configuration>Configuration variables provide a way to vary the configuration at deployment time in many ways.