-
Notifications
You must be signed in to change notification settings - Fork 178
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
Rearrange Bicep Modules #548
Conversation
This pull request is protected by Check Enforcer. What is Check Enforcer?Check Enforcer helps ensure all pull requests are covered by at least one check-run (typically an Azure Pipeline). When all check-runs associated with this pull request pass then Check Enforcer itself will pass. Why am I getting this message?You are getting this message because Check Enforcer did not detect any check-runs being associated with this pull request within five minutes. This may indicate that your pull request is not covered by any pipelines and so Check Enforcer is correctly blocking the pull request being merged. What should I do now?If the check-enforcer check-run is not passing and all other check-runs associated with this PR are passing (excluding license-cla) then you could try telling Check Enforcer to evaluate your pull request again. You can do this by adding a comment to this pull request as follows: |
9e12996
to
c1fa359
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking really good so far. Excited for the day where we don't need to ask devs to author their own infra vs just pulling in different modules on demand from a module registry based on some azure.yaml configuration or similar.
Added some comments to consider for now or at a later stage.
templates/common/infra/bicep/core/host/container-registry.bicep
Outdated
Show resolved
Hide resolved
templates/common/infra/bicep/core/host/appserviceplan-functions.bicep
Outdated
Show resolved
Hide resolved
templates/common/infra/bicep/core/host/appserviceplan-sites.bicep
Outdated
Show resolved
Hide resolved
templates/common/infra/bicep/core/storage/storage-account.bicep
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems much better than what we have today, so please don't consider this feedback blocking.
I think it is worthwhile to try to remove all the uses of dependsOn
in favor of threading outputs from one resource/module as inputs to another resource/module. In practice, I think this means we just take a "name" parameter for external resources a module depends and using that in our existing
calls instead of "knowing" what the name of the resource is.
I also feel strongly that we should be using camelCase outputs (just like our parameters) for all of these modules we are building, and only using SCREAMING_CASE
in main.bicep
and other "entrypoints", since these are the outputs that are written into .env and we want SCREAMING_CASE there.
Is your longer term plan to try to move these modules into a registry and just depend on them that way, or do you think we'll be shipping the source for these modules as part of the sample repositories?
Repoman Generation ResultsRepoman pushed changes to remotes for the following projects: Project: todo-csharp-cosmos-sqlRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-csharp-cosmos-sql -b pr/548 View Changes | Compare Changes Project: todo-csharp-sqlRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-csharp-sql -b pr/548 View Changes | Compare Changes Project: todo-nodejs-mongo-acaRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-nodejs-mongo-aca -b pr/548 View Changes | Compare Changes Project: todo-nodejs-mongo-swa-funcRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-nodejs-mongo-swa-func -b pr/548 View Changes | Compare Changes Project: todo-nodejs-mongoRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-nodejs-mongo -b pr/548 View Changes | Compare Changes Project: todo-python-mongo-acaRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-python-mongo-aca -b pr/548 View Changes | Compare Changes Project: todo-python-mongo-swa-funcRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-python-mongo-swa-func -b pr/548 View Changes | Compare Changes Project: todo-python-mongoRemote: azure-samples-stagingBranch: pr/548You can initialize this project with: azd init -t Azure-Samples/todo-python-mongo -b pr/548 View Changes | Compare Changes |
Azure Dev CLI Install InstructionsInstall scriptsMacOS/Linux
bash:
pwsh:
Windows
Standalone Binary
Container
|
Fixes #543
Right now all bicep is in resource.bicep. That file is getting long and we aren't sharing common bicep files amongst the templates.
Let's break into modules and structure better for reuse.