Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New-AzSubscriptionDeploymentStack Inline Parameters #122

Closed
data-tangles opened this issue Aug 19, 2023 · 4 comments
Closed

New-AzSubscriptionDeploymentStack Inline Parameters #122

data-tangles opened this issue Aug 19, 2023 · 4 comments
Assignees
Labels
planned feature A feature that is planned for a future release.

Comments

@data-tangles
Copy link

Is your feature request related to a problem? Please describe.
Currently with New-AzSubscriptionDeploymentStack you can't (seemingly) provide inline parameters to bypass a Parameters file. If I try with the following code:

New-AzSubscriptionDeploymentStack -Name $(deploymentStackName) -Location $(Location) -TemplateFile ".\main.bicep" -deploymentLocation $(deploymentLocation) -tags $(tags) -vNetAddressSpace $(vNetAddressSpace) -vNetName $(vNetName) -nsgName $(nsgName) -rg_name $(rg_name)

I just get the below errors:

deploymentStackName: The term 'deploymentStackName' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. deploymentLocation: The term 'deploymentLocation' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. tags: The term 'tags' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. vNetAddressSpace: The term 'vNetAddressSpace' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. vNetName: The term 'vNetName' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. nsgName: The term 'nsgName' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. rg_name: The term 'rg_name' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

Describe the solution you'd like
I use Azure DevOps pipelines for deployment. I have a repo with public facing Bicep modules. I want the modules themselves to be public, but I want to pass the parameters using variable groups which is why I need the parameters to be specified inline.

For example, I have the following code which works for the standard New-AzSubscriptionDeployment cmdlet :

New-AzSubscriptionDeployment -Location $(Location) -TemplateFile ".\main.bicep" -WhatIf -deploymentLocation $(deploymentLocation) -tags $(tags) -vNetAddressSpace $(vNetAddressSpace) -vNetName $(vNetName) -nsgName $(nsgName) -rg_name $(rg_name)

Describe alternatives you've considered
I've considered placing the parameters files inside a private repo and specifying this in the CLI but I want to avoid separate repo's if possible

Additional context
Add any other context or screenshots about the feature request here.

@dantedallag dantedallag self-assigned this Aug 21, 2023
@dantedallag
Copy link
Contributor

This (Dynamic parameters) is a feature we are aware is missing in stacks and is planned for the future. We can use this issue to track progress.

@dantedallag dantedallag added the planned feature A feature that is planned for a future release. label Aug 22, 2023
@quality-leftovers
Copy link
Collaborator

Wanted to switch our dev environment deployment to stacks and stumbled over this issue. In the end we decided to pass on deployment stacks for now because we didn't want to change our existing setup too much for a public preview feature.

@dantedallag
Copy link
Contributor

@quality-leftovers This feature is actually implemented in the newest version of stacks if you would like to try.

@data-tangles also wanted to notify you that this feature is available if you would like to verify.

@quality-leftovers
Copy link
Collaborator

Just as feedback: I upgraded Pwsh Module Az 11.4.0 to 11.5.0 and it worked. Thanks for the heads up 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
planned feature A feature that is planned for a future release.
Projects
None yet
Development

No branches or pull requests

4 participants