LocationPackageOptions Struct
Options for InitPackage.rpm/InitPackage.msi.
| Source | aws-ec2/lib/cfn-init-elements.ts |
|---|
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_ec2 as ec2 } from 'aws-cdk-lib';
declare const initServiceRestartHandle: ec2.InitServiceRestartHandle;
const locationPackageOptions: ec2.LocationPackageOptions = {
key: 'key',
serviceRestartHandles: [initServiceRestartHandle],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_ec2 as ec2
# init_service_restart_handle: ec2.InitServiceRestartHandle
location_package_options = ec2.LocationPackageOptions(
key="key",
service_restart_handles=[init_service_restart_handle]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ec2.*;
InitServiceRestartHandle initServiceRestartHandle;
LocationPackageOptions locationPackageOptions = LocationPackageOptions.builder()
.key("key")
.serviceRestartHandles(List.of(initServiceRestartHandle))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.EC2;
InitServiceRestartHandle initServiceRestartHandle;
var locationPackageOptions = new LocationPackageOptions {
Key = "key",
ServiceRestartHandles = new [] { initServiceRestartHandle }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
var initServiceRestartHandle InitServiceRestartHandle
locationPackageOptions := &LocationPackageOptions{
Key: jsii.String("key"),
ServiceRestartHandles: []InitServiceRestartHandle{
initServiceRestartHandle,
},
}
Properties
Identifier key for this package.
Default: Automatically generated
You can use this to order package installs.
serviceRestartHandlesoptionalInitServiceRestartHandle[]service_restart_handlesoptionaltyping.List[InitServiceRestartHandle]serviceRestartHandlesoptionalList<InitServiceRestartHandle>ServiceRestartHandlesoptionalInitServiceRestartHandle[]ServiceRestartHandlesoptional*[]InitServiceRestartHandle #Restart the given service after this command has run.
Default: Do not restart any service