You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Key Vault (RBAC-enabled) for pipeline variables/secrets
47
-
- (Optional) Certificate profile (`.../certificateProfiles`) can be created either:
48
-
- by Terraform (if you set `identity_validation_id` and re-apply), or
49
-
- by the Azure DevOps pipeline automatically (after you set a Key Vault secret; no Terraform re-run)
50
-
- (Optional, Terraform-deployed) Microsoft Entra app registration + service principal for an Azure DevOps **Workload Identity Federation** service connection
- AzureRM service connection (Workload Identity Federation)
56
-
- Pipeline authorizations for the service connection + variable group
57
-
- (Optional) RBAC assignment(s) for the Azure DevOps service principal
58
-
-`Artifact Signing Certificate Profile Signer` at the certificate profile scope (required for signing)
59
-
-`Contributor` at the resource group scope (only required if you want the pipeline to create the certificate profile)
46
+
- Key Vault (RBAC-enabled) for pipeline variables/secrets (created by default)
47
+
- Certificate profile (`.../certificateProfiles`)
48
+
- Preferred: created by the Azure DevOps pipeline after you set the Key Vault secret `artifactSigningIdentityValidationId` (no second `terraform apply`)
49
+
- Optional: created by Terraform if you set `identity_validation_id` and re-apply
From [What is Artifact Signing?](https://learn.microsoft.com/en-us/azure/artifact-signing/overview)
64
57
65
58
> [!NOTE]
66
59
> -**Identity validation** itself is **portal-only** (service requirement). Terraform can’t complete that workflow.
67
-
> - After you complete it, you can avoid a second `terraform apply` by setting the Key Vault secret `artifactSigningIdentityValidationId` and letting the pipeline create the certificate profile.
68
-
> - If Terraform creates the Azure DevOps service connection (`ado_enabled = true`), it can also read the generated WIF **Issuer** and **Subject** and create the Entra **federated credential** automatically (no copy/paste).
60
+
> - After you complete it, set Key Vault secret `artifactSigningIdentityValidationId` and the pipeline will create the certificate profile automatically.
61
+
> - If Terraform creates the Azure DevOps service connection (`ado_enabled = true`), it can read the generated WIF **Issuer/Subject** and create the Entra federated credential automatically.
69
62
70
63
## Deploy with Terraform
71
64
@@ -84,18 +77,14 @@ terraform apply -auto-approve
84
77
85
78
3) In Azure portal, open the Artifact Signing account and complete **Identity validation** (portal-only).
86
79
87
-
4) Copy the **Identity validation Id** from the portal and set it in Key Vault (no Terraform re-run required):
80
+
4) Copy the **Identity validation Id** from the portal and set it in Key Vault:
az keyvault secret set --vault-name $kvName --name artifactSigningIdentityValidationId --value "00000000-0000-0000-0000-000000000000"
94
85
```
95
86
96
-
5) Run the Azure DevOps pipeline. The `AzureCLI@2` step will:
97
-
- create the certificate profile if it doesn't exist yet
98
-
- ensure the `Artifact Signing Certificate Profile Signer` role assignment exists
87
+
5) Run the Azure DevOps pipeline. The `AzureCLI@2` step will create the certificate profile if it doesn’t exist yet, then sign the binaries.
99
88
100
89
Optional: If you prefer Terraform to manage the certificate profile instead, set `identity_validation_id` in `terraform-infrastructure/terraform.tfvars` and run `terraform apply` again.
101
90
@@ -131,22 +120,28 @@ Notes:
131
120
## Pipeline
132
121
133
122
-[azure-pipelines.yml](azure-pipelines.yml) builds `SigningDemo.exe`, installs the required signing components via NuGet extraction, then signs using the official SignTool + `/dlib` flow.
0 commit comments