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

Add an optional parameter to bicep build to specify the config file to use #5013

Open
shenglol opened this issue Oct 27, 2021 · 8 comments
Open
Labels
enhancement New feature or request Needs: Attention 👋 Needs: Upvote This issue requires more votes to be considered revisit

Comments

@shenglol
Copy link
Contributor

Is your feature request related to a problem? Please describe.
Currently, users cannot choose which bicep file to use when running bicep build.

Describe the solution you'd like
Add a parameter to specify a bicep config file path.

bicep build ./main.bicep --config ./bicepconfig.prod.json
@shenglol shenglol added the enhancement New feature or request label Oct 27, 2021
@ghost ghost added the Needs: Triage 🔍 label Oct 27, 2021
@alex-frankel
Copy link
Collaborator

Related to #5010

@majastrz
Copy link
Member

We discussed it during triage today.

One question to answer to whether the --config param should override the config files for the specified module and any referenced modules or if it should apply to just to the specified one.

There may also be some overlap between (future) Bicep param files and the bicep config files. We should probably work through the design on the Bicep param files before we add more complexity to config.

@majastrz majastrz added discussion This is a discussion issue and not a change proposal. and removed Needs: Triage 🔍 labels Oct 27, 2021
@majastrz majastrz added this to the Committed Backlog milestone Oct 27, 2021
@majastrz majastrz added Needs: Author Feedback Awaiting feedback from the author of the issue Needs: Upvote This issue requires more votes to be considered labels Oct 27, 2021
@anthony-c-martin
Copy link
Member

anthony-c-martin commented Oct 27, 2021

There may also be some overlap between (future) Bicep param files and the bicep config files. We should probably work through the design on the Bicep param files before we add more complexity to config.

+1. Supporting multiple config files for different environments feels like a similar scenario to supporting multiple parameter files. I wouldn't want to force a proliferation of both files for each environment, if we have the ability to support both within a redesigned parameter file format (#399).

There's also the question of what the editor experience looks like as we won't be able to automatically pick up a config file - do we force you to link to both a parameters file (#512) and config file for validation?

I don't know whether this necessarily needs to block this implementation if it permits some useful scenarios for the time being, but does feel like something we need an answer for in the long-term.

@J0F3
Copy link

J0F3 commented Nov 10, 2022

The use case I would have in mind for that is more in the case of the linter config instead of a config file per environment. So, for example, I want to use a specific linter config in CI. Sso that when there are no template/project specific linter rules configured my default (specified with --config) is used.

However, it would be then again problematic as long as something like #5022 is not implemented. Because currently where the content of multiple config file is not merged together in some way I have only the choose to define nothing or all. But I cannot overwrite specific rules and fallback for all other rule to a default "global" config (e.g specified by --config or saved in the user home directory or similar, etc.).

I think @michael-crawford had also some very good points described here in: #8132 (comment)

@brwilkinson
Copy link
Collaborator

Some requests have come through in discussions for deploying from Different ACR instances between TEST and PROD.

So this feature would cover that scenario.

@ghost
Copy link

ghost commented May 22, 2023

Hi shenglol, this issue has been marked as stale because it was labeled as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. Thanks for contributing to bicep! 😄 🦾

@shenglol
Copy link
Contributor Author

Will need to revive the discussion at some point.

@blueboxes
Copy link

The split of dev and prod is something I also have a challenge with. This feature would really help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Needs: Attention 👋 Needs: Upvote This issue requires more votes to be considered revisit
Projects
Status: Todo
Development

No branches or pull requests

8 participants