Guest Lee Stott Posted August 31, 2022 Posted August 31, 2022 As a developer, you need to make decisions when it comes to building, deploying, and securing your application. Frequent questions you might ask are: Which cloud services should I use with my code? Which libraries do I need to use? How should I set up my local development environment? How do I provision the necessary infrastructure for my application? How do I know that what I’m doing incorporates security best practices? The Azure Developer CLI helps you answer these questions. It provides you with a clear path for building your application in the cloud. Azure Developer CLI (azd) —a new, open-source tool that accelerates the time it takes to get started on Azure. The Azure Developer CLI provides developer-friendly commands that map to key stages in your workflow: code, build, deploy, monitor, repeat. The new Azure Developer CLI builds upon the experience and foundations of the Azure CLI. You can use both tools together, as needed, to support your Azure workflow. For a quick intro to the Azure Developer CLI, be sure to check out our Developer Hub! With the Azure Developer CLI, a typical developer workflow looks like this: azd init: Create an application and initialize an environment using a sample template in your preferred language. azd provision: Provision the necessary resources for your application on Azure. azd deploy: Deploy your application to Azure. azd monitor: Monitor your application’s behavior and performance and validate deployments. azd pipeline config: Create and manage CI/CD (continuous integration and continuous delivery). Better yet, you can also use azd up to create, provision, and deploy a new application in one step! For a list of supported commands, see the Developer CLI reference docs. Application templates for Python, JavaScript/TypeScript, and C# The Azure Developer CLI uses idiomatic application templates that extend beyond “Hello World!” to include the scaffolding for monitoring and CI/CD for your application. Each template includes application code, an /infra directory containing all the infra-as-code files (written in Bicep) needed to provision the Azure resources, and an azure.yaml file that describes your application. These templates are extensible and customizable to your specific use case. There are an initial set of template applications written in Python, JavaScript/TypeScript, and C# and for hosts such as Azure App Service, Azure Container Apps, and Azure Static Web Apps + Function Apps. Get started with the Azure Developer CLI Whether you’re working in the terminal, your editor or IDE (like Visual Studio Code or Visual Studio), or your GitHub Actions pipeline, Azure Developer CLI commands remain consistent regardless of the context. Installation Instructions Once you’ve installed the prerequisites, install the standalone Azure Developer CLI via the following command in your preferred terminal. Windows powershell -ex AllSigned -c "Invoke-RestMethod 'https://aka.ms/install-azd.ps1' | Invoke-Expression" macOS/Linux curl -fsSL https://aka.ms/install-azd.sh | bash Editor and IDE Support Visual Studio Code As of today, you can also access preview Azure Developer CLI functionality from within both Visual Studio Code and Visual Studio. You can try out our Visual Studio Code extension by installing it from the Visual Studio Code Marketplace. From the VS Code extension, you can use all the Azure Developer CLI commands. Visual Studio In Visual Studio 2022 17.3 Preview 2 or later, you can enable the CLI by flipping the Integration with azd, the Azure Developer CLI preview feature flag (Tools > Options > Environment > Preview Features > Integration with azd, the Azure Developer CLI). Enabling this flag will enable Visual Studio to detect the presence of a solution that was created with the Azure Developer CLI in the terminal. Feedback + Contributions Contributing to the CLI The Developer CLI is an open-source, MIT-licensed product! Our team is excited to collaborate with all of you and intends for the Azure Developer CLI to be community-driven. We welcome contributions to the core Developer CLI codebase and in the form of templates. Our team encourages you to file issues, open pull requests, contribute to discussions and more via our GitHub repository. Authoring Templates If you author your own templates, you can add the azd-templates tag to your repository on GitHub. That way, other developers can find, fork, and build upon your template for their own use case. You can also open an issue on our GitHub repository if there’s a use case and template that you would like to see created. Continue reading... Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.