Working with Terraform

Figure 1065. What's it all about? Slide presentation

Quote:

“Terraform is an infrastructure as code tool that lets you build, change, and version cloud and on-prem resources safely and efficiently.”


Figure 1066. Terraform resources Slide presentation

Figure 1067. Creating databases Slide presentation
Declarative schema Physical result
CREATE SCHEMA ...
  CREATE TABLE ...

  CREATE VIEW ...

...
  • Database implementation using files or raw devices.

  • Creating Index / search trees.


Figure 1068. Creating cloud resources Slide presentation
Declarative schema Physical result
resource "hcloud_server" "wwwSrv" {
  name         = "hello"
  image        =  "debian-13"
  server_type  =  "cx23"
}
Creating IPs, networks, servers, message queues, ...

Figure 1069. Getting started: The Hetzner API token Slide presentation
  • Access you cloud project by the Hetzner GUI interface.

  • Go to Security --> API Tokens --> Generate API token

  • Provide a name and hit “Generate API token”.

  • Copy the generated token's value and store it in a secure location e.g. a password manager.

    Caution

    The Hetzner GUI blocks subsequent read access after creation.

    In case of loss: Delete the existing and generate a new one.