forked from renovatebot/renovate
/
1.tf
174 lines (141 loc) · 3.71 KB
/
1.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
module "foo" {
source = "github.com/hashicorp/example?ref=v1.0.0"
}
module "bar" {
source = "github.com/hashicorp/example?ref=next"
}
module "repo-with-dot" {
source = "github.com/hashicorp/example.2.3?ref=v1.0.0"
}
module "repo-with-dot-and-git-suffix" {
source = "github.com/hashicorp/example.2.3.git?ref=v1.0.0"
}
module "consul" {
source = "hashicorp/consul/aws"
version = "0.1.0"
}
module "container_definition" {
source = "github.com/tieto-cem/terraform-aws-ecs-task-definition//modules/container-definition?ref=v0.1.0"
name = "hello"
image = "tutum/hello-world"
mem_soft_limit = 256
port_mappings = [{
containerPort = 80
hostPort = 80
}]
}
module "task_definition" {
source = "github.com/tieto-cem/terraform-aws-ecs-task-definition?ref=v0.1.0"
name = "mytask"
container_definitions = [
"${module.container_definition.json}"]
}
module "consul" {
source = "git@github.com:hashicorp/example.git?ref=v2.0.0"
}
module "web_server_sg" {
source = "terraform-aws-modules/security-group/aws//modules/http-80"
name = "web-server"
description = "Security group for web-server with HTTP ports open within VPC"
vpc_id = "vpc-12345678"
ingress_cidr_blocks = ["10.10.0.0/16"]
}
module "vote_service_sg" {
source = "terraform-aws-modules/security-group/aws"
version = "<= 2.4.0"
name = "user-service"
description = "Security group for user-service with custom ports open within VPC, and PostgreSQL publicly open"
vpc_id = "vpc-12345678"
ingress_cidr_blocks = ["10.10.0.0/16"]
ingress_rules = ["https-443-tcp"]
ingress_with_cidr_blocks = [
{
from_port = 8080
to_port = 8090
protocol = "tcp"
description = "User-service ports"
cidr_blocks = "10.10.0.0/16"
},
{
rule = "postgresql-tcp"
cidr_blocks = "0.0.0.0/0"
},
]
}
module "consul" {
source = "app.terraform.io/example-corp/k8s-cluster/azurerm"
version = "~> 1.1.0"
}
module "consul2" {
source = "app.terraform.io/example-corp/k8s-cluster/azurerm"
version = "~> 1.1"
}
module "consul3" {
source = "app.terraform.io/example-corp/k8s-cluster/azurerm"
version = "~~ 1.1"
}
module "consul3" {
source = "hashicorp/consul/aws"
version = ">= 1.0.0, <= 2.0.0"
}
module "relative" {
source = "../../modules/fe"
}
module "nosauce" {
foo = "bar"
}
# test exact without operator, equal with `=`
provider "azurerm" {
version = "1.36.1"
}
provider "gitlab" {
alias = "main"
version = "=2.4"
}
provider "gitlab" {
token = "${var.gitlab_token}"
version = "=1.3"
}
provider "helm" {
kubernetes {
host = "https://104.196.242.174"
username = "ClusterMaster"
password = "MindTheGap"
client_certificate = file("~/.kube/client-cert.pem")
client_key = file("~/.kube/client-key.pem")
cluster_ca_certificate = file("~/.kube/cluster-ca-cert.pem")
}
}
provider "newrelic" {
version = "V1.9"
api_key = "${var.newrelic_api_key}"
}
module "foobar" {
source = "https://bitbucket.com/hashicorp/example?ref=v1.0.0"
}
module "gittags" {
source = "git::https://bitbucket.com/hashicorp/example?ref=v1.0.0"
}
module "gittags_badversion" {
source = "git::https://bitbucket.com/hashicorp/example?ref=next"
}
module "gittags_subdir" {
source = "git::https://bitbucket.com/hashicorp/example//subdir/test?ref=v1.0.1"
}
module "gittags_http" {
source = "git::http://bitbucket.com/hashicorp/example?ref=v1.0.2"
}
module "gittags_ssh" {
source = "git::ssh://git@bitbucket.com/hashicorp/example?ref=v1.0.3"
}
terraform {
required_providers {
aws = ">= 2.7.0"
}
}
terraform {
required_providers {
aws = ">= 2.5.0"
azurerm = ">= 2.0.0"
}
}