AWS Lightsail Instance

This page shows how to write Terraform and CloudFormation for Lightsail Instance and write them securely.

aws_lightsail_instance (Terraform)

The Instance in Lightsail can be configured in Terraform with the resource name aws_lightsail_instance. The following sections describe 4 examples of how to use the resource and its parameters.

Example Usage from GitHub

github-iconbentinata/tf
resource "aws_lightsail_instance" "blog_beramaljariyah" {
  name              = "blog.beramaljariyah.org"
  availability_zone = "ap-southeast-1a"
  blueprint_id      = "ubuntu_18_04"
  bundle_id         = "micro_2_0"
  key_pair_name     = "evermos"
github-icongilyas/infracost
resource "aws_lightsail_instance" "linux1" {
  name              = "linux1"
  availability_zone = "us-east-1a"
  blueprint_id      = "centos_7_1901_01"
  bundle_id         = "xlarge_2_0"
}
github-iconinfracost/infracost
resource "aws_lightsail_instance" "linux1" {
  name              = "linux1"
  availability_zone = "us-east-1a"
  blueprint_id      = "centos_7_1901_01"
  bundle_id         = "xlarge_2_0"
}
github-iconjpsedo/Deploy-Infrastructure
resource "aws_lightsail_instance" "Autozona-Master" {
  name              = "Autozona-Master"
  availability_zone = "us-east-1a"
  blueprint_id      = "ubuntu_18_04"
  bundle_id         = "micro_2_0"
  key_pair_name     = "Autozona"

Parameters

Explanation in Terraform Registry

Provides a Lightsail Instance. Amazon Lightsail is a service to provide easy virtual private servers with custom software already setup. See What is Amazon Lightsail? for more information.

Note: Lightsail is currently only supported in a limited number of AWS Regions, please see "Regions and Availability Zones in Amazon Lightsail" for more details

AWS::Lightsail::Instance (CloudFormation)

The Instance in Lightsail can be configured in CloudFormation with the resource name AWS::Lightsail::Instance. The following sections describe how to use the resource and its parameters.

Parameters

Explanation in CloudFormation Registry

The AWS::Lightsail::Instance resource specifies an Amazon Lightsail instance.

Frequently asked questions

What is AWS Lightsail Instance?

AWS Lightsail Instance is a resource for Lightsail of Amazon Web Service. Settings can be wrote in Terraform and CloudFormation.

Where can I find the example code for the AWS Lightsail Instance?

For Terraform, the bentinata/tf, gilyas/infracost and infracost/infracost source code examples are useful. See the Terraform Example section for further details.