-
Notifications
You must be signed in to change notification settings - Fork 210
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
[Feature] Allow overriding of built in app host templates #4678
base: main
Are you sure you want to change the base?
Conversation
@microsoft-github-policy-service agree |
The other angle of attack here is work that will happen on the Aspire side, which involves moving the responsibility of generation of the shared infrastructure into the Aspire app host itself (similar how in Aspire 9 they delivered the ability to use My concern about allowing arbitrary template replacement here is just one of supportability (since there's now an API between The OverlayFS stuff is cool - and it's neat to see how building on the io.FS abstraction allowed you a nice way to plug in here. If we do land this (i.e. we are comfortable with the extension point) I think we should at least consider reworking the code so we don't panic in |
#4503 is the issue we had that tracks the fact that we want to move this responsibility into the app host (and hence there would need to be a way to have |
Thanks for opening this and starting the discussion, @FullStackChef - I kicked off the PR builds so you should get privates generated with these changes if that's helpful for you. Jotted some quick thoughts in the issue based on my understand on where Aspire is moving. |
Thanks @ellismg - Honestly I see this as a temporary stop gap until the Apphost takes responsibility for the shared infrastructure. Ultimately - the change has allowed me to build a local version of AZD that we can chuck in our repos for now so if it's not suitable for release I'm not going to be upset, I am aware from conversations in the Aspire discord channel that there are other people that are struggling with some of the restrictions of the built-in templates (and it was going to delay our adoption of the benefits of azd + aspire) |
break line to account for linting requirements
/azp run azure-dev - cli |
Azure Pipelines successfully started running 1 pipeline(s). |
Azure Dev CLI Install InstructionsInstall scriptsMacOS/Linux
bash:
pwsh:
WindowsPowerShell install
MSI install
Standalone Binary
MSI
Documentationlearn.microsoft.com documentationtitle: Azure Developer CLI reference
|
FWIW, @FullStackChef, I had our bots create privates with your fix incase that's helpful for you as well :-), even though it sounds like from your message you have all the machinery on your end to produce privates. |
It's actually incredibly helpful thank you @ellismg - my "build" was to build the exe locally and c/p 😬 this is much more useful |
@ellismg I've also addressed your feedback around the panic in init - I've adjusted this so it instead gracefully falls back to the embedded fs |
The private binaries are eventually removed after some time. Let us know if that happen and we can re-generate new ones. |
Describe the feature or problem you’d like to solve
When using AZD with Aspire the bicep templates make assumptions about the infrastructure and specifically the naming conventions / existence of resources
AZD uses embedded file system that contains templates for creating base bicep files for use with app host - these are good for a large number of cases however create issues when attempting to migrate existing projects to use Aspire & AZD as well as situations where organisations have pre-defined naming conventions
Proposed solution
Introduce an overlay file system for app host based generation that allows developers to override one or more of the existing files by creating a mirrored directory that contains the templates they want to override
How will it benefit CLI and its users?
For most users there will be no difference in the operation of the cli - however where users may be prevented from using the cli due to limitations of these templates, it will allow customisation of these templates without having to synth infra and then make changes which causes issues when there are changes
Additional context
Add any other context like screenshots or mockups are helpful, if applicable.