I’m trying to create a package to deploy website and database.
manifest.xml:
<sitemanifest>
<iisApp path="webApp" />
<dbDacFx path="database.dacpac" />
</sitemanifest>
parameters.xml:
<parameters>
<parameter name="appPath" defaultValue="dev.local" tags="iisapp">
<parameterEntry kind="ProviderPath" scope="iisApp" match="webApp" />
</parameter>
<parameter name="dbServer" defaultValue="localhost" tags="dbServer,sql" />
<parameter name="connectionString" defaultValue="Server={dbServer};Initial Catalog=MyDatabase;Integrated Security=True;" tags="hidden,sql,sqlconnectionstring">
<parameterEntry kind="ProviderPath" scope="dbDacFx" match="database.dacpac" />
<parameterEntry kind="XmlFile" scope="webApp\\Web.config" match="//connectionStrings/add[@name='DB']/@connectionString" />
</parameter>
</parameters>
And I get the following error:
There is no stream data associated with 'database.dacpac'.
Is it possible to use dbDacFx provider in a manifest?
It looks like it is not possible to use dbDacFx provider directly in a manifest, but there is a workaround to create a package using msdeploy.
new manifest.xml (should contain the full path):
issue command: