adding <kbd> to ESC key for formatting

This commit is contained in:
Ric Harvey 2024-04-16 19:34:27 +01:00
parent a0cbc9967c
commit b9360061a9
Signed by: ric
GPG key ID: 7FDEB4C0C7D5CB61

View file

@ -60,7 +60,7 @@ Right we now have our basic stack to work with. Everything else we do will be to
Right this is great and all but what if we want to make it easy to change things, such as the ami_id we are deploying or the size of the instance we are running so we have more CPU and RAM. This is where variables make it easy, and as an added advantage we can create variable files for different environments with different values in them to override the defaults. Right this is great and all but what if we want to make it easy to change things, such as the ami_id we are deploying or the size of the instance we are running so we have more CPU and RAM. This is where variables make it easy, and as an added advantage we can create variable files for different environments with different values in them to override the defaults.
> [!Note] > [!Note]
> For this next bit you can use your favourite command line editor to alter the files in CloudShell, vim and nano are installed by deafult, I use vim so if you copy the examples you'll need to press ```i``` after opening the files to go into insert mode and when you want to save and exit the file press ```ESC``` and type ```:wq``` to exit. > For this next bit you can use your favourite command line editor to alter the files in CloudShell, vim and nano are installed by deafult, I use vim so if you copy the examples you'll need to press ```i``` after opening the files to go into insert mode and when you want to save and exit the file press <kbd>ESC</kbd> and type ```:wq``` to exit.
Right lets add new variables for both the **ami_id** and **instance_size**, start by opening variables.tf in the code directory from CloudShell: Right lets add new variables for both the **ami_id** and **instance_size**, start by opening variables.tf in the code directory from CloudShell:
@ -84,7 +84,7 @@ variable "ami_id" {
} }
``` ```
Save that file and exit press ```ESC``` and type ```:wq``` to exit (last tiem I'll remind you). Now you've set up terraform/tofu to understand the ```intsance_size``` and ```ami_id``` are variables and we've also given them default values. If you didn't use a dfault in this file when you run apply you'd get prompted to enter the details. Save that file and exit press <kbd>ESC</kbd> and type ```:wq``` to exit (last tiem I'll remind you). Now you've set up terraform/tofu to understand the ```intsance_size``` and ```ami_id``` are variables and we've also given them default values. If you didn't use a dfault in this file when you run apply you'd get prompted to enter the details.
Right now terraform/tofu knows about the variables lets use them. Open up ```main.tf``` ready for editing: Right now terraform/tofu knows about the variables lets use them. Open up ```main.tf``` ready for editing: