Solution Import Task doesn't accept a calculated value for UseDeploymentSettingsFile switch:
UseDeploymentSettingsFile: '$(UseDeploymentSettings)'
DeploymentSettingsFile: '$(DeploymentSettingsFilePath)'
I can see in logs, that the settings file is not used in the arguments of pac-call
if I set it to true (hardcoded), it's working.
Anybody else experiencing that?
What would be the right way to use a calculated value there? Tried with/without quotes, eq-comparison, etc..
Thanks @Asllan_Makaj 🙂 That's what I came up with (temporarily), too. Didn't post it here, because I don't consider this a "solution" to my problem. That's a nasty code-duplicating workaround.
I have a second input-parameter in the task I would want to control dynamically with a variable/parameter ... managed vs unmanaged .. I would need 4 of these blocks then?! mpfff.
Hi @smadep , I think I have the solution of your problem. I tried in my environment and it worked.
- task: PowerPlatformImportSolution@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: 'Second-connection'
Environment: '$(urlTest)'
SolutionInputFile: 'Testing.zip'
UseDeploymentSettingsFile: true
DeploymentSettingsFile: '$(DeploymentSettingsFilePath)'
AsyncOperation: true
MaxAsyncWaitTime: '60'
condition: eq(variables['UseDeploymentSettings'],'true')
- task: PowerPlatformImportSolution@2
inputs:
authenticationType: 'PowerPlatformSPN'
PowerPlatformSPN: 'Second-connection'
Environment: '$(urlTest)'
SolutionInputFile: 'Testing.zip'
AsyncOperation: true
MaxAsyncWaitTime: '60'
condition: ne(variables['UseDeploymentSettings'],'true')
WarrenBelz
89
Most Valuable Professional
Michael E. Gernaey
72
Super User 2025 Season 1
mmbr1606
71
Super User 2025 Season 1