-
Notifications
You must be signed in to change notification settings - Fork 1
/
server.tf
executable file
·39 lines (32 loc) · 1.18 KB
/
server.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
module "server" {
source = "git::https://github.com/obytes/terraform-aws-codeless-lambda.git//modules/lambda"
prefix = "${local.prefix}-server"
common_tags = local.common_tags
description = "SUMU Demo Server"
runtime = "python3.8"
handler = "src.main.handler"
timeout = 120
memory_size = 1024
policy_json = data.aws_iam_policy_document.custom_policy_doc.json
envs = {
CONNECTIONS_TABLE = var.connections_table.name
NOTIFICATIONS_TOPIC_ARN = var.notifications_topic.arn
NOTIFICATIONS_QUEUE_URL = var.notifications_queue.url
}
}
module "server_ci" {
source = "git::https://github.com/obytes/terraform-aws-lambda-ci.git//modules/ci"
prefix = "${local.prefix}-server-ci"
common_tags = local.common_tags
# Lambda
lambda = module.server.lambda
app_src_path = "app/server"
packages_descriptor_path = "app/server/requirements/lambda.txt"
# Github
s3_artifacts = var.s3_artifacts
github = var.github
pre_release = var.pre_release
github_repository = var.github_repository
# Notifications
ci_notifications_slack_channels = var.ci_notifications_slack_channels
}