diff options
| author | EuAndreh <eu@euandre.org> | 2019-05-28 23:18:16 -0300 |
|---|---|---|
| committer | EuAndreh <eu@euandre.org> | 2019-05-28 23:18:16 -0300 |
| commit | c0c0aa98d88c2a62792ed7b4f9b150774b66d07e (patch) | |
| tree | 9e5181e7363d94cb8fd8c12cbeb15464c3a68db7 /vps.tf | |
| parent | Split $VPS_COMMIT_SHA variable declaration for exporting (diff) | |
| download | toph-c0c0aa98d88c2a62792ed7b4f9b150774b66d07e.tar.gz toph-c0c0aa98d88c2a62792ed7b4f9b150774b66d07e.tar.xz | |
Use Floating IP on Droplet
Diffstat (limited to 'vps.tf')
| -rw-r--r-- | vps.tf | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1,5 +1,6 @@ variable "do_token" {} variable "ssh_fingerprint" {} +variable "floating_ip" {} provider "digitalocean" { token = "${var.do_token}" @@ -30,3 +31,8 @@ resource "digitalocean_droplet" "vps" { script = "./deploy.sh" } } + +resource "digitalocean_floating_ip_assignment" "vps" { + ip_address = "${var.floating_ip}" + droplet_id = "${digitalocean_droplet.vps.id}" +}
\ No newline at end of file |
