Initial hydrogen work

This commit is contained in:
Nemo 2018-02-19 01:21:04 +05:30
parent 08caa8086b
commit 6829c09331
3 changed files with 32 additions and 0 deletions

18
digitalocean/hydrogen.tf Normal file
View File

@ -0,0 +1,18 @@
resource "digitalocean_droplet" "hydrogen" {
image = "coreos-stable"
name = "hydrogen.bb8.fun"
region = "blr1"
size = "1gb"
ipv6 = true
private_networking = true
tags = [
"bangalore",
"proxy",
"hydrogen",
"vpn",
"monitoring"
]
user_data = "${ignition_config.hydrogen.rendered}"
}

10
digitalocean/ignition.tf Normal file
View File

@ -0,0 +1,10 @@
data "ignition_config" "hydrogen" {
systemd = [
"${data.ignition_systemd_unit.hydrogen.id}",
]
}
data "ignition_systemd_unit" "hydrogen-docker" {
name = "docker.service"
content = "[Service]\nType=oneshot\nExecStart=/usr/bin/echo Hello World\n\n[Install]\nWantedBy=multi-user.target"
}

4
digitalocean/ssh.tf Normal file
View File

@ -0,0 +1,4 @@
resource digitalocean_ssh_key "default" {
name = "Hydrogen Key"
public_key = "${file("/home/nemo/.ssh/hydrogen.pub")}"
}