mirror of
https://github.com/status-im/infra-nimbus.git
synced 2025-01-12 06:44:11 +00:00
add initial main.tf and variables.tf
Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
parent
7a2213d74b
commit
6979027273
40
main.tf
Normal file
40
main.tf
Normal file
@ -0,0 +1,40 @@
|
||||
/* DERIVED --------------------------------------*/
|
||||
provider "digitalocean" {
|
||||
token = "${var.digitalocean_token}"
|
||||
version = "<= 0.1.3"
|
||||
}
|
||||
provider "cloudflare" {
|
||||
email = "${var.cloudflare_email}"
|
||||
token = "${var.cloudflare_token}"
|
||||
org_id = "${var.cloudflare_org_id}"
|
||||
}
|
||||
provider "google" {
|
||||
credentials = "${file("google-cloud.json")}"
|
||||
project = "russia-servers"
|
||||
region = "us-central1"
|
||||
}
|
||||
provider "alicloud" {
|
||||
access_key = "${var.alicloud_access_key}"
|
||||
secret_key = "${var.alicloud_secret_key}"
|
||||
region = "${var.alicloud_region}"
|
||||
}
|
||||
|
||||
/* DATA -----------------------------------------*/
|
||||
|
||||
terraform {
|
||||
backend "consul" {
|
||||
address = "https://consul.statusim.net:8400"
|
||||
lock = true
|
||||
/* KV store has a limit of 512KB */
|
||||
gzip = true
|
||||
/* WARNING This needs to be changed for every repo. */
|
||||
path = "terraform/nimbus/"
|
||||
ca_file = "ansible/files/consul-ca.crt"
|
||||
cert_file = "ansible/files/consul-client.crt"
|
||||
key_file = "ansible/files/consul-client.key"
|
||||
}
|
||||
}
|
||||
|
||||
/* RESOURCES ------------------------------------*/
|
||||
|
||||
/* TODO */
|
42
variables.tf
Normal file
42
variables.tf
Normal file
@ -0,0 +1,42 @@
|
||||
/* REQUIRED -------------------------------------*/
|
||||
|
||||
variable cloudflare_token {
|
||||
description = "Token for interacting with Cloudflare API."
|
||||
}
|
||||
|
||||
variable digitalocean_token {
|
||||
description = "Token for interacting with DigitalOcean API."
|
||||
}
|
||||
|
||||
variable cloudflare_email {
|
||||
description = "Email address of Cloudflare account."
|
||||
}
|
||||
|
||||
variable cloudflare_org_id {
|
||||
description = "ID of the CloudFlare organization."
|
||||
}
|
||||
|
||||
variable alicloud_access_key {
|
||||
description = "Alibaba Cloud API access key."
|
||||
}
|
||||
|
||||
variable alicloud_secret_key {
|
||||
description = "Alibaba Cloud API secret key."
|
||||
}
|
||||
|
||||
variable alicloud_region {
|
||||
description = "Alibaba Cloud hosting region."
|
||||
default = "cn-hongkong"
|
||||
}
|
||||
|
||||
/* GENERAL --------------------------------------*/
|
||||
|
||||
variable public_domain {
|
||||
description = "Domain under which the public sites go."
|
||||
default = "status.im"
|
||||
}
|
||||
|
||||
variable domain {
|
||||
description = "DNS Domain to update"
|
||||
default = "statusim.net"
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user