Microsoft.DevHub workflows 2022-04-01-preview

Bicep resource definition

The workflows resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DevHub/workflows resource, add the following Bicep to your template.

resource symbolicname 'Microsoft.DevHub/workflows@2022-04-01-preview' = {
  location: 'string'
  name: 'string'
  properties: {
    githubWorkflowProfile: {
      acr: {
        acrRegistryName: 'string'
        acrRepositoryName: 'string'
        acrResourceGroup: 'string'
        acrSubscriptionId: 'string'
      }
      aksResourceId: 'string'
      branchName: 'string'
      deploymentProperties: {
        helmChartPath: 'string'
        helmValues: 'string'
        kubeManifestLocations: [
          'string'
        ]
        manifestType: 'string'
        overrides: {
          {customized property}: 'string'
        }
      }
      dockerBuildContext: 'string'
      dockerfile: 'string'
      lastWorkflowRun: {}
      namespace: 'string'
      oidcCredentials: {
        azureClientId: 'string'
        azureTenantId: 'string'
      }
      repositoryName: 'string'
      repositoryOwner: 'string'
    }
  }
  tags: {
    {customized property}: 'string'
  }
}

Property Values

Microsoft.DevHub/workflows

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 1
Max length = 63
Pattern = ^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$ (required)
properties Properties of a workflow. WorkflowProperties
tags Resource tags Dictionary of tag names and values. See Tags in templates

ACR

Name Description Value
acrRegistryName ACR registry string
acrRepositoryName ACR repository string
acrResourceGroup ACR resource group string
acrSubscriptionId ACR subscription id string

DeploymentProperties

Name Description Value
helmChartPath Helm chart directory path in repository. string
helmValues Helm Values.yaml file location in repository. string
kubeManifestLocations string[]
manifestType Determines the type of manifests within the repository. 'helm'
'kube'
overrides Manifest override values. DeploymentPropertiesOverrides

DeploymentPropertiesOverrides

Name Description Value

GitHubWorkflowProfile

Name Description Value
acr Information on the azure container registry ACR
aksResourceId The Azure Kubernetes Cluster Resource the application will be deployed to. string
branchName Repository Branch Name string
deploymentProperties DeploymentProperties
dockerBuildContext Path to Dockerfile Build Context within the repository. string
dockerfile Path to the Dockerfile within the repository. string
lastWorkflowRun WorkflowRun
namespace Kubernetes namespace the application is deployed to. string
oidcCredentials The fields needed for OIDC with GitHub. GitHubWorkflowProfileOidcCredentials
repositoryName Repository Name string
repositoryOwner Repository Owner string

GitHubWorkflowProfileOidcCredentials

Name Description Value
azureClientId Azure Application Client ID string
azureTenantId Azure Directory (tenant) ID string

TrackedResourceTags

Name Description Value

WorkflowProperties

Name Description Value
githubWorkflowProfile Profile of a github workflow. GitHubWorkflowProfile

WorkflowRun

Name Description Value

ARM template resource definition

The workflows resource type can be deployed with operations that target:

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DevHub/workflows resource, add the following JSON to your template.

{
  "type": "Microsoft.DevHub/workflows",
  "apiVersion": "2022-04-01-preview",
  "name": "string",
  "location": "string",
  "properties": {
    "githubWorkflowProfile": {
      "acr": {
        "acrRegistryName": "string",
        "acrRepositoryName": "string",
        "acrResourceGroup": "string",
        "acrSubscriptionId": "string"
      },
      "aksResourceId": "string",
      "branchName": "string",
      "deploymentProperties": {
        "helmChartPath": "string",
        "helmValues": "string",
        "kubeManifestLocations": [ "string" ],
        "manifestType": "string",
        "overrides": {
          "{customized property}": "string"
        }
      },
      "dockerBuildContext": "string",
      "dockerfile": "string",
      "lastWorkflowRun": {
      },
      "namespace": "string",
      "oidcCredentials": {
        "azureClientId": "string",
        "azureTenantId": "string"
      },
      "repositoryName": "string",
      "repositoryOwner": "string"
    }
  },
  "tags": {
    "{customized property}": "string"
  }
}

Property Values

Microsoft.DevHub/workflows

Name Description Value
apiVersion The api version '2022-04-01-preview'
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 1
Max length = 63
Pattern = ^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$ (required)
properties Properties of a workflow. WorkflowProperties
tags Resource tags Dictionary of tag names and values. See Tags in templates
type The resource type 'Microsoft.DevHub/workflows'

ACR

Name Description Value
acrRegistryName ACR registry string
acrRepositoryName ACR repository string
acrResourceGroup ACR resource group string
acrSubscriptionId ACR subscription id string

DeploymentProperties

Name Description Value
helmChartPath Helm chart directory path in repository. string
helmValues Helm Values.yaml file location in repository. string
kubeManifestLocations string[]
manifestType Determines the type of manifests within the repository. 'helm'
'kube'
overrides Manifest override values. DeploymentPropertiesOverrides

DeploymentPropertiesOverrides

Name Description Value

GitHubWorkflowProfile

Name Description Value
acr Information on the azure container registry ACR
aksResourceId The Azure Kubernetes Cluster Resource the application will be deployed to. string
branchName Repository Branch Name string
deploymentProperties DeploymentProperties
dockerBuildContext Path to Dockerfile Build Context within the repository. string
dockerfile Path to the Dockerfile within the repository. string
lastWorkflowRun WorkflowRun
namespace Kubernetes namespace the application is deployed to. string
oidcCredentials The fields needed for OIDC with GitHub. GitHubWorkflowProfileOidcCredentials
repositoryName Repository Name string
repositoryOwner Repository Owner string

GitHubWorkflowProfileOidcCredentials

Name Description Value
azureClientId Azure Application Client ID string
azureTenantId Azure Directory (tenant) ID string

TrackedResourceTags

Name Description Value

WorkflowProperties

Name Description Value
githubWorkflowProfile Profile of a github workflow. GitHubWorkflowProfile

WorkflowRun

Name Description Value

Usage Examples

Terraform (AzAPI provider) resource definition

The workflows resource type can be deployed with operations that target:

  • Resource groups

For a list of changed properties in each API version, see change log.

Resource format

To create a Microsoft.DevHub/workflows resource, add the following Terraform to your template.

resource "azapi_resource" "symbolicname" {
  type = "Microsoft.DevHub/workflows@2022-04-01-preview"
  name = "string"
  parent_id = "string"
  location = "string"
  tags = {
    {customized property} = "string"
  }
  body = {
    properties = {
      githubWorkflowProfile = {
        acr = {
          acrRegistryName = "string"
          acrRepositoryName = "string"
          acrResourceGroup = "string"
          acrSubscriptionId = "string"
        }
        aksResourceId = "string"
        branchName = "string"
        deploymentProperties = {
          helmChartPath = "string"
          helmValues = "string"
          kubeManifestLocations = [
            "string"
          ]
          manifestType = "string"
          overrides = {
            {customized property} = "string"
          }
        }
        dockerBuildContext = "string"
        dockerfile = "string"
        lastWorkflowRun = {
        }
        namespace = "string"
        oidcCredentials = {
          azureClientId = "string"
          azureTenantId = "string"
        }
        repositoryName = "string"
        repositoryOwner = "string"
      }
    }
  }
}

Property Values

Microsoft.DevHub/workflows

Name Description Value
location The geo-location where the resource lives string (required)
name The resource name string

Constraints:
Min length = 1
Max length = 63
Pattern = ^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$ (required)
properties Properties of a workflow. WorkflowProperties
tags Resource tags Dictionary of tag names and values.
type The resource type "Microsoft.DevHub/workflows@2022-04-01-preview"

ACR

Name Description Value
acrRegistryName ACR registry string
acrRepositoryName ACR repository string
acrResourceGroup ACR resource group string
acrSubscriptionId ACR subscription id string

DeploymentProperties

Name Description Value
helmChartPath Helm chart directory path in repository. string
helmValues Helm Values.yaml file location in repository. string
kubeManifestLocations string[]
manifestType Determines the type of manifests within the repository. 'helm'
'kube'
overrides Manifest override values. DeploymentPropertiesOverrides

DeploymentPropertiesOverrides

Name Description Value

GitHubWorkflowProfile

Name Description Value
acr Information on the azure container registry ACR
aksResourceId The Azure Kubernetes Cluster Resource the application will be deployed to. string
branchName Repository Branch Name string
deploymentProperties DeploymentProperties
dockerBuildContext Path to Dockerfile Build Context within the repository. string
dockerfile Path to the Dockerfile within the repository. string
lastWorkflowRun WorkflowRun
namespace Kubernetes namespace the application is deployed to. string
oidcCredentials The fields needed for OIDC with GitHub. GitHubWorkflowProfileOidcCredentials
repositoryName Repository Name string
repositoryOwner Repository Owner string

GitHubWorkflowProfileOidcCredentials

Name Description Value
azureClientId Azure Application Client ID string
azureTenantId Azure Directory (tenant) ID string

TrackedResourceTags

Name Description Value

WorkflowProperties

Name Description Value
githubWorkflowProfile Profile of a github workflow. GitHubWorkflowProfile

WorkflowRun

Name Description Value