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

POC: Adds azd hooks run <name> command #2385

Closed
wants to merge 5 commits into from
Closed

Conversation

wbreza
Copy link
Contributor

@wbreza wbreza commented Jun 9, 2023

POC that Adds azd hooks run <name> command to help develop, test and run hooks for an azd project & services.

Resolves #1642

Features

  • An easy way for developers to test and troubleshoot their azd hook scripts without the overhead of waiting for azd commands to run
  • Developers can develop a suite of hooks/scripts to support their day to day inner-loop development
  • Call into other hook scripts from azd hook lifecycle events

Example

Dev wants to validate their deployment to run a series of UX smoke test across their services

  • Dev creates a vaildate hook in each service that they want to test. These tests could run playwright or some other UX test framework
  • Dev adds a postdeploy hook that calls azd hooks run validate
    • This ensures that the validate hook would run for each service after deployment completes
  • Dev also has a custom hook/script in their toolbox where they could run azd hooks run validate at any time.

Docs and Parameters

image

Output

image

@ghost ghost assigned wbreza Jun 9, 2023
@wbreza wbreza changed the title Cmd hooks run Adds azd hooks run <name> command Jun 9, 2023
@ellismg
Copy link
Member

ellismg commented Jun 9, 2023

/cc @Austinauth from the UX side (I think this is basically following most of the conventions you have laid out for us, but the explanation about what the command is doing having context specific information and color in it is a little new (it also looks like some of the intermediate text is a different color than it should be)

and @savannahostrowski from the product side.

I'm a little nervous about having an azd hooks top level command, since I know we don't want to overload folks with a bunch of top level commands. I'm not sure where else we might want to put this, but maybe something like azd run hook would be better, since I could envision more stuff coming under a top level run command than a hook command.

I also wonder if in practice --platform is going to cary it's weight. It feels like trying to run a hook on a different platform than it was designed for is something you're not going to do much of in practice and unlike the other cases (especially given the fact that azd will never let you run a hook for the wrong platform "in production")

Very happy to see we are investing in making these hooks a little easier to write and maintain! Thanks for kicking this off, @wbreza!

@wbreza
Copy link
Contributor Author

wbreza commented Jun 9, 2023

/cc @Austinauth from the UX side (I think this is basically following most of the conventions you have laid out for us, but the explanation about what the command is doing having context specific information and color in it is a little new (it also looks like some of the intermediate text is a different color than it should be)

Outside the color to show the significance of hook name and environment it is using our standard header

and @savannahostrowski from the product side.

I'm a little nervous about having an azd hooks top level command, since I know we don't want to overload folks with a bunch of top level commands. I'm not sure where else we might want to put this, but maybe something like azd run hook would be better, since I could envision more stuff coming under a top level run command than a hook command.

I'm open to this but hesitant that users would expect something else to make it under run before hooks. Like run the app or something.

I also wonder if in practice --platform is going to cary it's weight. It feels like trying to run a hook on a different platform than it was designed for is something you're not going to do much of in practice and unlike the other cases (especially given the fact that azd will never let you run a hook for the wrong platform "in production")

We see many template authors creating templates and specifying both windows and posix versions of command hooks. Windows hooks typically using pwsh shell and posix using sh shell.

Since you can run new powershell and bash across all platforms this allows devs to easily test out their scripts without having to update their azure.yaml configuration assuming you're not using any real OS/platform scripting.

Very happy to see we are investing in making these hooks a little easier to write and maintain! Thanks for kicking this off, @wbreza!

😊

@vhvb1989
Copy link
Member

Adding my 5-cents here...

I don't think (and I am against) that azd should expose a command to run the hooks. Here's why I think like that:
A hook can be either in-line or an external-file.
For external-file, there's not any benefit from using azd to run the file. Injecting azd-env-vars can be part of the external script, where the script can take control of what to pull from the azd-env after calling azd env get-values.
For in-line scripts, the benefit is that I don't need to manually extract the script out of azure.yaml to run it, b/c azd can just run it. But I would rather like azd to just export the in-line hook into a file and then I can run it. Similary, I would prefer azd to have a way to import a file into one in-line hook.

@Austinauth
Copy link

Thanks for the tag, I'm not seeing any glaring issues. In the future I think we'll want to be more consistent with the items we highlight in blue vs the ones we do not. That's on me. Agree with @ellismg's observation the text hooks for environment in the sub-header appear as white when it should be gray (if following convention).

@savannahostrowski
Copy link
Contributor

I've been thinking about this over the past couple days...and I think I'm in the same camp as @vhvb1989 right now in terms of "developers have the tools/means to do this today". I'm not sure that we have enough of a signal to warrant exposing a new command for this quite yet.

@jongio
Copy link
Member

jongio commented Jun 12, 2023

There have been many instances of the need for being able to "just run the hook and have the azd env context" when working on the open ai and build related demos. Today we have to manually load the azd context into the script because we don't support running the hooks.

Here are the related issues I filed while working with those customers:

#1700
#1697
#1701

This is especially helpful for folks that just want to run the hook for ML purposes. Right now, we have to tell them to go a completely different route, which is something like "open a terminal, load the azd env values, pass right parameters to the hook, run the hook".

With this feature, we'd be able to tell them to run "azd hooks run postprovision".

@savannahostrowski
Copy link
Contributor

I think those are viable scenarios but these are all self-filed issues. I'd love to hear more from the community, partner teams etc. before exposing this as a new command. If these were coming from teams you've been chatting with, can you tag them for further input/point them in my direction?

@vhvb1989
Copy link
Member

With this feature, we'd be able to tell them to run "azd hooks run postprovision".

This brings a good and powerful feature for the customers and use-cases you have mentioned @jongio , but at the same time it opens the door to more questions and future issues, like:

  • What if I run the postprovision hook before calling provision at least once before? (calling the hook without ever calling the hook-trigger)
  • What should I do when running the hook from azd run hook behaves differently than then the hook runs as part of the azd-flow (the hook depends on azd trigger to generate an output, or something)

I can see a next request in the future to make azd to create mocked-operations to be used by the hooks, so I can run/tests the hooks with fake azd-execution...

Anyway, I think azd should not be the one used to evolve the story arounds hooks... I think there should be a different tool for that matter, like a hooks-studio or something :)

@wbreza
Copy link
Contributor Author

wbreza commented Jun 13, 2023

I see this feature very similar to npm scripts with run-script command

There are well known scripts/hooks that run during lifecycle events of an NPM based application but it is also extensible to allow the user to run arbitrary user defined scripts/hooks that help them with their day to day development.

It would be an oversight to not think about the development of an overall solution and how they got to their final deployable product. Having a nice set of hooks/scripts that the user wants to use should not be ignored.

@weikanglim
Copy link
Contributor

weikanglim commented Jun 13, 2023

I see this feature very similar to npm scripts with run-script command

There's a slight difference here that npm scripts are largely stateless. azd postprovision hooks are largely stateful and expected to observe the provisioning outputs. Without provisioning outputs, running the script by itself isn't as meaningful.

@wbreza
Copy link
Contributor Author

wbreza commented Jun 13, 2023

There's a slight difference here that npm scripts are largely stateless. azd postprovision hooks are largely stateful and expected to observe the provisioning outputs. Without provisioning outputs, running the script by itself isn't as meaningful.

In many cases hook scripts would be stateless. The env state usage is optional and only there if you need it.

@lechnerc77
Copy link
Contributor

As @jongio brought that to my attention here my 5 cent: This functionality makes total sense to me especially for development and testing of the hooks (I would use them especially for hooks after infrastructure setup- that saves precious time).
I think (but that's more a gut feeling) that this might be useful for CI/CD scenarios to create different more fine-grained stages/steps.

@wbreza
Copy link
Contributor Author

wbreza commented Jun 20, 2023

Waiting for more customer feedback before exploring this feature.

@wbreza wbreza closed this Jun 20, 2023
@jongio
Copy link
Member

jongio commented Jun 20, 2023

Reopening. Please see above comments from Christian.

I also created a video that demonstrates why this feature is helpful. https://www.youtube.com/watch?v=8TBlgIvyL-0&ab_channel=JonGallant

@jongio jongio reopened this Jun 20, 2023
@azure-sdk
Copy link
Collaborator

Azure Dev CLI Install Instructions

Install scripts

MacOS/Linux

May elevate using sudo on some platforms and configurations

bash:

curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/uninstall-azd.sh | bash;
curl -fsSL https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/install-azd.sh | bash -s -- --base-url https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385 --version '' --verbose --skip-verify

pwsh:

Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/uninstall-azd.ps1' -OutFile uninstall-azd.ps1; ./uninstall-azd.ps1
Invoke-RestMethod 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/install-azd.ps1' -OutFile install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385' -Version '' -SkipVerify -Verbose

Windows

PowerShell install

powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/uninstall-azd.ps1' > uninstall-azd.ps1; ./uninstall-azd.ps1;"
powershell -c "Set-ExecutionPolicy Bypass Process; irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/install-azd.ps1' > install-azd.ps1; ./install-azd.ps1 -BaseUrl 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385' -Version '' -SkipVerify -Verbose;"

MSI install

powershell -c "irm 'https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/pr/2385/azd-windows-amd64.msi' -OutFile azd-windows-amd64.msi; msiexec /i azd-windows-amd64.msi /qn"

Standalone Binary

MSI

Container

docker run -it azdevcliextacr.azurecr.io/azure-dev:pr-2385

Documentation

learn.microsoft.com documentation

title: Azure Developer CLI reference
description: This article explains the syntax and parameters for the various Azure Developer CLI commands.
author: alexwolfmsft
ms.author: alexwolf
ms.date: 06/20/2023
ms.service: azure-dev-cli
ms.topic: conceptual
ms.custom: devx-track-azdevcli

Azure Developer CLI reference

This article explains the syntax and parameters for the various Azure Developer CLI commands.

azd

The Azure Developer CLI (azd) is an open-source tool that helps onboard and manage your application on Azure

Options

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
  -h, --help         Gets help for azd.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

  • azd auth: Authenticate with Azure.
  • azd config: Manage azd configurations (ex: default Azure subscription, location).
  • azd deploy: Deploy the application's code to Azure.
  • azd down: Delete Azure resources for an application.
  • azd env: Manage environments.
  • azd hooks: Develop, test and run hooks for an application. (Beta)
  • azd init: Initialize a new application.
  • azd monitor: Monitor a deployed application. (Beta)
  • azd package: Packages the application's code to be deployed to Azure. (Beta)
  • azd pipeline: Manage and configure your deployment pipelines. (Beta)
  • azd provision: Provision the Azure resources for an application.
  • azd restore: Restores the application's dependencies. (Beta)
  • azd template: Find and view template details. (Beta)
  • azd up: Provision Azure resources, and deploy your project with a single command.
  • azd version: Print the version number of Azure Developer CLI.

azd auth

Authenticate with Azure.

Options

  -h, --help   Gets help for auth.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd auth login

Log in to Azure.

Synopsis

Log in to Azure.

When run without any arguments, log in interactively using a browser. To log in using a device code, pass
--use-device-code.

To log in as a service principal, pass --client-id and --tenant-id as well as one of: --client-secret,
--client-certificate, or --federated-credential-provider.

azd auth login [flags]

Options

      --check-status                           Checks the log-in status instead of logging in.
      --client-certificate string              The path to the client certificate for the service principal to authenticate with.
      --client-id string                       The client id for the service principal to authenticate with.
      --client-secret string                   The client secret for the service principal to authenticate with. Set to the empty string to read the value from the console.
      --federated-credential-provider string   The provider to use to acquire a federated token to authenticate with.
  -h, --help                                   Gets help for login.
      --redirect-port int                      Choose the port to be used as part of the redirect URI during interactive login.
      --tenant-id string                       The tenant id or domain name to authenticate with.
      --use-device-code[=true]                 When true, log in by using a device code instead of a browser.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd auth logout

Log out of Azure.

Synopsis

Log out of Azure

azd auth logout [flags]

Options

  -h, --help   Gets help for logout.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config

Manage azd configurations (ex: default Azure subscription, location).

Synopsis

Manage the Azure Developer CLI user configuration, which includes your default Azure subscription and location.

Available since azure-dev-cli_0.4.0-beta.1.

The easiest way to configure azd for the first time is to run azd init. The subscription and location you select will be stored in the config.json file located in the config directory. To configure azd anytime afterwards, you'll use azd config set.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.

Options

  -h, --help   Gets help for config.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config get

Gets a configuration.

Synopsis

Gets a configuration in the configuration path.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.

azd config get <path> [flags]

Options

  -h, --help   Gets help for get.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config list

Lists all configuration values.

Synopsis

Lists all configuration values in the configuration path.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.

azd config list [flags]

Options

  -h, --help   Gets help for list.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config list-alpha

Display the list of available features in alpha stage.

azd config list-alpha [flags]

Options

  -h, --help   Gets help for list-alpha.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config reset

Resets configuration to default.

Synopsis

Resets all configuration in the configuration path.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable to the default.

azd config reset [flags]

Options

  -h, --help   Gets help for reset.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config set

Sets a configuration.

Synopsis

Sets a configuration in the configuration path.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.

azd config set <path> <value> [flags]

Examples

azd config set defaults.subscription <yourSubscriptionID>
azd config set defaults.location eastus

Options

  -h, --help   Gets help for set.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd config unset

Unsets a configuration.

Synopsis

Removes a configuration in the configuration path.

The default value of the config directory is:

  • $HOME/.azd on Linux and macOS
  • %USERPROFILE%\.azd on Windows

The configuration directory can be overridden by specifying a path in the AZD_CONFIG_DIR environment variable.

azd config unset <path> [flags]

Examples

azd config unset defaults.location

Options

  -h, --help   Gets help for unset.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd deploy

Deploy the application's code to Azure.

azd deploy <service> [flags]

Options

      --all                   Deploys all services that are listed in azure.yaml
  -e, --environment string    The name of the environment to use.
      --from-package string   Deploys the application from an existing package.
  -h, --help                  Gets help for deploy.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd down

Delete Azure resources for an application.

azd down [flags]

Options

  -e, --environment string   The name of the environment to use.
      --force                Does not require confirmation before it deletes resources.
  -h, --help                 Gets help for down.
      --purge                Does not require confirmation before it permanently deletes resources that are soft-deleted by default (for example, key vaults).

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env

Manage environments.

Options

  -h, --help   Gets help for env.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env get-values

Get all environment values.

azd env get-values [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for get-values.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env list

List environments.

azd env list [flags]

Options

  -h, --help   Gets help for list.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env new

Create a new environment.

azd env new <environment> [flags]

Options

  -h, --help                  Gets help for new.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env refresh

Refresh environment settings by using information from a previous infrastructure provision.

azd env refresh <environment> [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for refresh.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env select

Set the default environment.

azd env select <environment> [flags]

Options

  -h, --help   Gets help for select.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd env set

Manage your environment settings.

azd env set <key> <value> [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for set.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd hooks

Develop, test and run hooks for an application. (Beta)

Options

  -h, --help   Gets help for hooks.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd hooks run

Runs the specified hook for the project and services

azd hooks run <name> [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for run.
      --interactive          Forces all hooks to run in interactive mode for testing
      --platform string      Forces hooks to run for the specified platform.
      --service string       Only runs hooks for the specified service.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd init

Initialize a new application.

azd init [flags]

Options

  -b, --branch string         The template branch to initialize from.
  -e, --environment string    The name of the environment to use.
  -h, --help                  Gets help for init.
  -l, --location string       Azure location for the new environment
      --subscription string   Name or ID of an Azure subscription to use for the new environment
  -t, --template string       The template to use when you initialize the project. You can use Full URI, <owner>/<repository>, or <repository> if it's part of the azure-samples organization.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd monitor

Monitor a deployed application. (Beta)

azd monitor [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for monitor.
      --live                 Open a browser to Application Insights Live Metrics. Live Metrics is currently not supported for Python apps.
      --logs                 Open a browser to Application Insights Logs.
      --overview             Open a browser to Application Insights Overview Dashboard.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd package

Packages the application's code to be deployed to Azure. (Beta)

azd package <service> [flags]

Options

      --all                  Deploys all services that are listed in azure.yaml
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for package.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline

Manage and configure your deployment pipelines. (Beta)

Options

  -h, --help   Gets help for pipeline.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd pipeline config

Configure your deployment pipeline to connect securely to Azure. (Beta)

azd pipeline config [flags]

Options

      --auth-type string             The authentication type used between the pipeline provider and Azure for deployment (Only valid for GitHub provider). Valid values: federated, client-credentials.
  -e, --environment string           The name of the environment to use.
  -h, --help                         Gets help for config.
      --principal-name string        The name of the service principal to use to grant access to Azure resources as part of the pipeline.
      --principal-role stringArray   The roles to assign to the service principal. By default the service principal will be granted the Contributor and User Access Administrator roles. (default [Contributor,User Access Administrator])
      --provider string              The pipeline provider to use (github for Github Actions and azdo for Azure Pipelines).
      --remote-name string           The name of the git remote to configure the pipeline to run on. (default "origin")

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd provision

Provision the Azure resources for an application.

azd provision [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for provision.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd restore

Restores the application's dependencies. (Beta)

azd restore <service> [flags]

Options

      --all                  Restores all services that are listed in azure.yaml
  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for restore.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template

Find and view template details. (Beta)

Options

  -h, --help   Gets help for template.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template list

Show list of sample azd templates. (Beta)

azd template list [flags]

Options

  -h, --help   Gets help for list.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd template show

Show details for a given template. (Beta)

azd template show <template> [flags]

Options

  -h, --help   Gets help for show.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd up

Provision Azure resources, and deploy your project with a single command.

azd up [flags]

Options

  -e, --environment string   The name of the environment to use.
  -h, --help                 Gets help for up.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

azd version

Print the version number of Azure Developer CLI.

azd version [flags]

Options

  -h, --help   Gets help for version.

Options inherited from parent commands

  -C, --cwd string   Sets the current working directory.
      --debug        Enables debugging and diagnostics logging.
      --no-prompt    Accepts the default value instead of prompting, or it fails if there is no default.

See also

@wbreza wbreza marked this pull request as draft June 20, 2023 22:26
@wbreza wbreza changed the title Adds azd hooks run <name> command POC: Adds azd hooks run <name> command Jun 20, 2023
@microsoft-github-policy-service microsoft-github-policy-service bot added the no-recent-activity identity issues with no activity label Aug 25, 2023
@microsoft-github-policy-service
Copy link
Contributor

Hi @wbreza. Thank you for your interest in helping to improve the Azure Developer CLI experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment. Otherwise, we'll close this out in 7 days.

1 similar comment
@microsoft-github-policy-service
Copy link
Contributor

Hi @wbreza. Thank you for your interest in helping to improve the Azure Developer CLI experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment. Otherwise, we'll close this out in 7 days.

@microsoft-github-policy-service
Copy link
Contributor

Hi @wbreza. Thank you for your contribution. Since there hasn't been recent engagement, we're going to close this out. Feel free to respond with a comment containing "/reopen" if you'd like to continue working on these changes. Please be sure to use the command to reopen or remove the "no-recent-activity" label; otherwise, this is likely to be closed again with the next cleanup pass.

@ellismg ellismg removed the no-recent-activity identity issues with no activity label Sep 13, 2023
@wbreza
Copy link
Contributor Author

wbreza commented Sep 26, 2023

/reopen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve hook script debugging/troubleshooting
9 participants