Last active
February 3, 2021 05:32
-
-
Save Craigson/ec45b153a3e938f0d5bf415ebb5d02cd to your computer and use it in GitHub Desktop.
Digital Ocean module's main.tf file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
resource "digitalocean_droplet" "syntropy_ipfs" { | |
count = 5 | |
image = "ubuntu-20-04-x64" | |
name = "ipfs${count.index + 1}" | |
region = "nyc1" | |
size = "s-1vcpu-1gb" | |
private_networking = true | |
ssh_keys = [ | |
data.digitalocean_ssh_key.syntropy.id | |
] | |
connection { | |
host = self.ipv4_address | |
user = "root" | |
type = "ssh" | |
private_key = file(var.pvt_key) | |
timeout = "2m" | |
} | |
lifecycle { | |
create_before_destroy = true | |
} | |
tags = [element(var.droplet_host_number, count.index)] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment