Note that there are some explanatory texts on larger screens.

plurals
  1. POmsdeploy: Replace provider attribute values during deployment?
    text
    copied!<p>I have a msdeploy question about how to replace attribute values for providers in source manifests during deployment.</p> <h2>Background:</h2> <p>I use msdeploy to create deployment packages during release builds. I want the packages to be suited for deployment to test/staging/production and need to be able to change configuration values deployment-time. One of the things that needs to be done during deployment is creating message queues (msmq), something that msdeploy doesn't support out-of-the-box (technically you could use a script and have msdeploy invoke it, but that's no fun). I've created a custom provider for msdeploy that enables me to create these message queues during deployment (msmq). Which queues to create and a few settings about them gets specified in a sourceManifest.xml file that looks something like this:</p> <pre><code>&lt;sitemanifest&gt; &lt;msmq path=".\private$\some.application/SomeService.svc" isTransactional="True" shouldGrantNetworkServicePeekWrite="True" userNameToGrantFullAccess="testdomain\username" /&gt; &lt;!-- more (non-relevant) stuff here --&gt; &lt;/sitemanifest&gt; </code></pre> <p>The content in the source manifest gets embedded into the package itself.</p> <h2>Question:</h2> <p><strong>How can I replace attribute values for providers?</strong></p> <p>Specifically, I need to replace the userNameToGrantFullAccess attribute value. The user that needs full access varies between environments. I have a really hacky work-around that I'm kinda embarrassed about, so I'm hoping there's a neat way to do this. I've tried using msdeploy's <strong>-declareParam/-setParam</strong> and also the -replace command but can't seem to figure out something that works. I was hoping that the <strong>DeploymentObjectAttribute</strong> parameter kind could lead to something.</p> <p>Thanks!</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload