CmdID / aws / aws lightsail
aws lightsail delete-instance
Deletes an Amazon Lightsail instance. AWS CLI reference
1 example 2 options Its page in the AWS CLI reference
Examples
To delete an instance
The following delete-instance example deletes the specified instance.
aws lightsail delete-instance --instance-name WordPress-1Identify--instance-nameThe name of the instance to delete.Its output, shortened
{
"operations": [
{
"id": "a1b2c3d4-5678-90ab-cdef-EXAMPLE11111",
"resourceName": "Disk-1",
"resourceType": "Disk",
"createdAt": 1569874357.469,
"location": {
"availabilityZone": "us-west-2a",
"regionName": "us-west-2"
},
"isTerminal": false,
"operationDetails": "WordPress-1",
"operationType": "DetachDisk",
"status": "Started",
"statusChangedAt": 1569874357.469
},
{
"id": "a1b2c3d4-5678-90ab-cdef-EXAMPLE22222",
"resourceName": "WordPress-1",
"resourceType": "Instance",
"createdAt": 1569874357.465,
"location": {
"availabilityZone": "us-west-2a",
"regionName": "us-west-2"
},
"isTerminal": false,
"operationDetails": "Disk-1",
"operationType": "DetachDisk",
"status": "Started",
… 18 more linesFor more information, see Delete Lightsail instances in the Amazon Lightsail User Guide.
Options
--force-delete-add-onsA Boolean value to indicate whether to delete all add-ons for the instance.--instance-nameThe name of the instance to delete.