Skip to content

Commit 88e18a7

Browse files
authored
Remove hard-coded platform attribute allowing Windows image to be built with powershell component
Fixed a bug where windows-based images cannot be built with windows component (powershell script). This is caused by the platform property in componentProps being hard-coded to Linux instead of checking previously defined value.
1 parent 0e26c9e commit 88e18a7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ export class ImagePipeline extends Construct {
234234
props.components.forEach((component) => {
235235
let newComponent = new imagebuilder.CfnComponent(this, component.name, {
236236
name: component.name,
237-
platform: 'Linux',
237+
platform: props.platform ? props.platform : 'Linux',
238238
version: component.version,
239239
data: readFileSync(component.document).toString(),
240240
});

0 commit comments

Comments
 (0)