-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlocals.tf
More file actions
66 lines (66 loc) · 2.5 KB
/
locals.tf
File metadata and controls
66 lines (66 loc) · 2.5 KB
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
locals {
# workspace_id = jsondecode(data.http.airbyte_workspaces.response_body).workspaces[0].workspaceId
workspace_id = var.WORKSPACE_ID
namespace_formats = jsondecode(file(var.source_table_names_file))
connections = {
staging = local.connections_stage
dev = local.connections_dev
prod = local.connections_prod
}
s3 = {
"customers_data" = {
configuration = {
aws_access_key_id = var.AWS_ACCESS_KEY_ID
aws_secret_access_key = var.AWS_SECRET_ACCESS_KEY
bucket = "cne-ai-airbyte-source"
region = "us-east-1"
streams = [
{
name = "customers_data"
days_to_sync_if_history_is_full = 3
schemaless = false
globs = ["customers_data.csv"]
validation_policy = "Emit Record"
input_schema = file("${path.root}/schemas/customers_data_schema.json")
format = {
"csv_format" = {
header_definition = {
from_csv = {}
}
delimiter = ","
double_quote = true
encoding = "utf8"
quote_char = "\""
skip_rows_after_header = 0
skip_rows_before_header = 0
false_values = ["0", "False", "FALSE", "false"]
null_values = [
" ", "#N/A", "#N/A N/A", "#NA", "-1.#IND", "-1#.QNAN", "-NaN", "1.#IND", "1#.QNAN", "N/A", "NA",
"NULL", "NaN", "n/a", "nan", "null", "-nan"
]
true_values = ["1", "True", "TRUE", "true"]
strings_can_be_null = false
}
}
},
]
}
workspace_id = local.workspace_id
},
}
big_query = {
configuration = {
big_query_client_buffer_size_mb = 15
credentials_json = var.SERVICE_ACCOUNT_INFO
dataset_id = "cne_ai_dataplatform_demo"
dataset_location = "europe-central2"
disable_type_dedupe = false
loading_method = {
standard_inserts = {}
}
project_id = var.BIGQUERY_PROJECT_ID
}
name = "BigQuery (${upper(trimprefix(terraform.workspace, "cne-airbyte-template-"))})"
workspace_id = local.workspace_id,
}
}