fix terraform main 2

This commit is contained in:
jakubknczny 2021-12-01 12:32:46 +01:00
parent 0e2636767b
commit fa6efa1eb4

10
main.tf
View File

@ -15,23 +15,23 @@ provider "hcloud" {
token = var.token
}
resource "hcloud_sv" "ubuntu" {
resource "hcloud_server" "ubuntu_server" {
name = "jk-test1"
image = "ubuntu-20.04"
server_type = "cpx11"
network {
network_id = hc_network.network.id
network_id = hcloud_network.network.id
}
user_data = file("cloud-init-sv")
user_data = file("cloud-init-server")
depends_on = [
hc_sv.mysql
hcloud_server.ubuntu_mysql
]
}
resource "hcloud_sv" "mysql" {
resource "hcloud_server" "ubuntu_mysql" {
name = "jk-test2"
image = "ubuntu-20.04"
server_type = "cpx11"