Skip to content

Commit

Permalink
Add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
JenGoldstrich committed Aug 23, 2024
1 parent 85725c8 commit 916cb5a
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 7 deletions.
6 changes: 5 additions & 1 deletion .web-docs/components/builder/arm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -765,6 +765,8 @@ post-processor "manifest" {
strip_path = true
custom_data = {
source_image_name = "${build.SourceImageName}"
tenant_id = "${build.TenantID}"
subscription_id = "${build.SubscriptionID}"
}
}
```
Expand All @@ -777,7 +779,9 @@ post-processor "manifest" {
"output": "manifest.json",
"strip_path": true,
"custom_data": {
"source_image_name": "{{ build `SourceImageName` }}"
"source_image_name": "{{ build `SourceImageName` }}",
"tenant_id": "{{ build `TenantID` }}",
"subscription_id": "{{ build `SubscriptionID` }}"
}
}
]
Expand Down
11 changes: 6 additions & 5 deletions builder/azure/arm/builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -390,10 +390,6 @@ func (b *Builder) Run(ctx context.Context, ui packersdk.Ui, hook packersdk.Hook)
)
}
steps = append(steps,
&StepSetGeneratedData{
GeneratedData: generatedData,
Config: &b.config,
},
NewStepValidateTemplate(azureClient, ui, &b.config, deploymentName, getVirtualMachineDeploymentFunction),
NewStepDeployTemplate(azureClient, ui, &b.config, deploymentName, getVirtualMachineDeploymentFunction, VirtualMachineTemplate),
NewStepGetIPAddress(azureClient, ui, endpointConnectType),
Expand Down Expand Up @@ -440,7 +436,12 @@ func (b *Builder) Run(ctx context.Context, ui packersdk.Ui, hook packersdk.Hook)
NewStepCaptureImage(azureClient, ui),
NewStepPublishToSharedImageGallery(azureClient, ui, &b.config),
)

steps = append([]multistep.Step{
&StepSetGeneratedData{
GeneratedData: generatedData,
Config: &b.config,
},
}, steps...)
steps = append(steps, captureSteps...)

if b.config.PackerDebug {
Expand Down
6 changes: 5 additions & 1 deletion docs/builders/arm.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,8 @@ post-processor "manifest" {
strip_path = true
custom_data = {
source_image_name = "${build.SourceImageName}"
tenant_id = "${build.TenantID}"
subscription_id = "${build.SubscriptionID}"
}
}
```
Expand All @@ -190,7 +192,9 @@ post-processor "manifest" {
"output": "manifest.json",
"strip_path": true,
"custom_data": {
"source_image_name": "{{ build `SourceImageName` }}"
"source_image_name": "{{ build `SourceImageName` }}",
"tenant_id": "{{ build `TenantID` }}",
"subscription_id": "{{ build `SubscriptionID` }}"
}
}
]
Expand Down

0 comments on commit 916cb5a

Please sign in to comment.