Automation and setup for sites I own.
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- provider "linode" {
- token = var.linode_token
- }
-
- resource "linode_instance" "functionalidiot_net" {
- image = "linode/alpine3.11"
- label = "functionalidiot.net"
- group = "terraform"
- region = "us-central"
- type = "g6-nanode-1"
- authorized_keys = [var.ssh_pub_key]
- root_pass = var.root_password
- }
-
- output "ipv4" {
- value = "${linode_instance.functionalidiot_net.ip_address}"
- }
-
- resource "null_resource" "post-setup" {
- depends_on = [ linode_instance.functionalidiot_net ]
- connection {
- host = linode_instance.functionalidiot_net.ip_address
- user = "root"
- password = var.root_password
- private_key = file("~/.ssh/id_rsa")
- }
- provisioner "remote-exec" {
- inline = [<<FIN
- uname -a
- FIN
- ]
- }
- }
|