Skip to content

Unable to expand the Parameters in .bicepparam files #3137

Answered by BernieWhite
AhmedValiShaik asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for the question @AhmedValiShaik. Yes, for PSRule to expand the Bicep files it must be able to resolve all parameters, similar to when you deploy to Azure.

If the parameters are optional

Your example in (2) is good. However, you may not want these parameters to be optional.

If the parameters are required

Yes, you can use AZURE_PARAMETER_DEFAULTS to set the default value for any required parameters that are not set. This option is good for scenarios that would normally be automatically set by the pipeline or CLI.

Another option is to create a file specifically for testing that is not deployed. It is mainly used for testing modules in isolation. For example, if you wanted to test sto…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@AhmedValiShaik
Comment options

Answer selected by AhmedValiShaik
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants