-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvariables.tf
164 lines (136 loc) · 5.3 KB
/
variables.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
variable "namespace" {
type = string
default = "global"
description = "Namespace, which could be your organization name, e.g. 'cp' or 'cloudposse'"
}
variable "stage" {
type = string
default = "default"
description = "Stage, e.g. 'prod', 'staging', 'dev', or 'test'"
}
variable "name" {
type = string
default = "codebuild"
description = "Solution name, e.g. 'app' or 'jenkins'"
}
variable "environment_variables" {
type = object({
name = string
value = string
})
default = {
"name" = "NO_ADDITIONAL_BUILD_VARS"
"value" = "TRUE"
}
description = "A list of maps, that contain both the key 'name' and the key 'value' to be used as additional environment variables for the build."
}
variable "enabled" {
type = string
default = "true"
description = "A boolean to enable/disable resource creation"
}
variable "cache_enabled" {
type = string
default = "true"
description = "If cache_enabled is true, create an S3 bucket for storing codebuild cache inside"
}
variable "cache_expiration_days" {
type = string
default = "7"
description = "How many days should the build cache be kept"
}
variable "cache_bucket_suffix_enabled" {
type = string
default = "true"
description = "The cache bucket generates a random 13 character string to generate a unique bucket name. If set to false it uses terraform-null-label's id value"
}
variable "badge_enabled" {
type = string
default = "false"
description = "Generates a publicly-accessible URL for the projects build badge. Available as badge_url attribute when enabled."
}
variable "build_image" {
type = string
default = "aws/codebuild/docker:1.12.1"
description = "Docker image for build environment, e.g. 'aws/codebuild/docker:1.12.1' or 'aws/codebuild/eb-nodejs-6.10.0-amazonlinux-64:4.0.0'. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref.html"
}
variable "build_compute_type" {
type = string
default = "BUILD_GENERAL1_SMALL"
description = "Instance type of the build instance"
}
variable "build_timeout" {
type = string
default = "60"
description = "How long in minutes, from 5 to 480 (8 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed."
}
variable "buildspec" {
type = string
default = ""
description = "Optional buildspec declaration to use for building the project"
}
variable "delimiter" {
type = string
default = "-"
description = "Delimiter to be used between `name`, `namespace`, `stage`, etc."
}
variable "attributes" {
type = list(string)
default = []
description = "Additional attributes (e.g. `policy` or `role`)"
}
variable "tags" {
type = map(string)
default = {}
description = "Additional tags (e.g. `map('BusinessUnit', 'XYZ')`"
}
variable "privileged_mode" {
type = string
default = "false"
description = "(Optional) If set to true, enables running the Docker daemon inside a Docker container on the CodeBuild instance. Used when building Docker images"
}
variable "github_token" {
type = string
default = ""
description = "(Optional) GitHub auth token environment variable (`GITHUB_TOKEN`)"
}
variable "aws_region" {
type = string
default = ""
description = "(Optional) AWS Region, e.g. us-east-1. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html"
}
variable "aws_account_id" {
type = string
default = ""
description = "(Optional) AWS Account ID. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html"
}
variable "image_repo_name" {
type = string
default = "UNSET"
description = "(Optional) ECR repository name to store the Docker image built by this module. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html"
}
variable "image_tag" {
type = string
default = "latest"
description = "(Optional) Docker image tag in the ECR repository, e.g. 'latest'. Used as CodeBuild ENV variable when building Docker images. For more info: http://docs.aws.amazon.com/codebuild/latest/userguide/sample-docker.html"
}
variable "source_type" {
type = string
default = "CODEPIPELINE"
description = "The type of repository that contains the source code to be built. Valid values for this parameter are: CODECOMMIT, CODEPIPELINE, GITHUB, GITHUB_ENTERPRISE, BITBUCKET or S3."
}
variable "source_location" {
type = string
default = ""
description = "The location of the source code from git or s3."
}
variable "artifact_type" {
type = string
default = "CODEPIPELINE"
description = "The build output artifact's type. Valid values for this parameter are: CODEPIPELINE, NO_ARTIFACTS or S3."
}
variable "report_build_status" {
type = string
default = "false"
description = "Set to true to report the status of a build's start and finish to your source provider. This option is only valid when the source_type is BITBUCKET or GITHUB."
}