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

Overridable commands i.e., shell-script provider #1090

Open
atrakic opened this issue Nov 4, 2022 · 8 comments
Open

Overridable commands i.e., shell-script provider #1090

atrakic opened this issue Nov 4, 2022 · 8 comments
Assignees
Milestone

Comments

@atrakic
Copy link

atrakic commented Nov 4, 2022

Please allow shell-scripts in provider list

@ghost ghost added needs-triage For new issues customer-reported identify a customer issue question labels Nov 4, 2022
@rajeshkamal5050
Copy link
Contributor

@atrakic can you add some more details on,

  • Use-case for the same and how were you envisioning it to be used.
  • Which azd commands/operations you would want that provider to act-on.

@rajeshkamal5050 rajeshkamal5050 added this to the Backlog milestone Nov 4, 2022
@atrakic
Copy link
Author

atrakic commented Nov 4, 2022

@atrakic can you add some more details on,

  • Use-case for the same and how were you envisioning it to be used.
  • Which azd commands/operations you would want that provider to act-on.

I have this example repo that follows azd template file structure: https://github.com/atrakic/azure-webapp-deploy.
Instead of using bicep/tf providers, I would like acd to create infra, build and deploy image. Please advise. Thx

@jongio
Copy link
Member

jongio commented Nov 8, 2022

Can you give an example of what would be in the script? az cli commands?

@atrakic
Copy link
Author

atrakic commented Nov 10, 2022

@jongio Within the repo I have already mentioned, I have already script with az commands for creating a web app with linux container: https://github.com/atrakic/azure-webapp-deploy/blob/main/infra/setup.sh.
Does this answers your question?

@jongio
Copy link
Member

jongio commented Nov 10, 2022

IC, We could potentially support this with #810 ext @wbreza is that right?

I'm curious though why you prefer to do that over bicep or terraform. With your approach you have no tear down support and it gets cumbersome to maintain. Highly recommend going iac route.

I also noticed that you have .go in your /src folder. azd doesn't yet support go apps either. @rajeshkamal5050 FYI

@atrakic
Copy link
Author

atrakic commented Nov 11, 2022

@jongio

IMHO, I find az cli as cleanest, lightest, easy to follow route to create infra resources without installing extra libs, sdks, etc, so Im really interested in having this feature buildt in acd.

Also, as per tear down: you have a point there, but this can be solved by exporting command instructions (after infra deployment) in tmp file which can be used for later destroy phase - aka terraform local state.
What do you think about this?

I was not aware of go apps are not supported, thx for letting me know. Any plans for the future?

@rajeshkamal5050
Copy link
Contributor

May be another extensibility use-case for script-based provisioning. How to leverage existing scripts (invokes Az CLI commands, direct REST API's etc.) for provisioning i.e., not using IaC(Bicep, Terraform). The pre and post hooks assume the provisioning is done via our IaC(Bicep/Terraform).

@wbreza
Copy link
Contributor

wbreza commented Nov 11, 2022

I have also thought about this. Having script support for IaC providers would also support transitional scenarios where a team may have existing legacy script based deployment system with plans to migrate to bicep/terraform.

I could see this going one of 2 ways.

  • New script based IaC provider where the dev would need to provide the up and down scripts
  • Azd extensibility route where you dev overrides the whole provision / infra create command with a custom script

I believe the latter would be more extensible scenario and solve additional use cases.

@ghost ghost removed the needs-triage For new issues label Jan 23, 2023
@rajeshkamal5050 rajeshkamal5050 modified the milestones: Backlog, On Deck Mar 13, 2024
@rajeshkamal5050 rajeshkamal5050 changed the title Support for shell-script provider [Extensibility] Overridable commands i.e., shell-script provider Mar 22, 2024
@rajeshkamal5050 rajeshkamal5050 modified the milestones: On Deck, Dilithium Mar 22, 2024
@microsoft-github-policy-service microsoft-github-policy-service bot added the needs-team-attention Issues out of a milestone label Mar 22, 2024
@rajeshkamal5050 rajeshkamal5050 changed the title [Extensibility] Overridable commands i.e., shell-script provider Overridable commands i.e., shell-script provider Mar 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants