Skip to content

Commit

Permalink
Add ability to disable server side cookies (closes #36)
Browse files Browse the repository at this point in the history
  • Loading branch information
TimmyCarbone authored and jbeemster committed Sep 20, 2023
1 parent acc8ed0 commit e559930
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ module "collector_kinesis" {
| <a name="input_cloudwatch_logs_enabled"></a> [cloudwatch\_logs\_enabled](#input\_cloudwatch\_logs\_enabled) | Whether application logs should be reported to CloudWatch | `bool` | `true` | no |
| <a name="input_cloudwatch_logs_retention_days"></a> [cloudwatch\_logs\_retention\_days](#input\_cloudwatch\_logs\_retention\_days) | The length of time in days to retain logs for | `number` | `7` | no |
| <a name="input_cookie_domain"></a> [cookie\_domain](#input\_cookie\_domain) | Optional first party cookie domain for the collector to set cookies on (e.g. acme.com) | `string` | `""` | no |
| <a name="input_cookie_enabled"></a> [cookie\_enabled](#input\_cookie\_enabled) | Whether server side cookies are enabled or not | `bool` | `true` | no |
| <a name="input_custom_paths"></a> [custom\_paths](#input\_custom\_paths) | Optional custom paths that the collector will respond to, typical paths to override are '/com.snowplowanalytics.snowplow/tp2', '/com.snowplowanalytics.iglu/v1' and '/r/tp2'. e.g. { "/custom/path/" : "/com.snowplowanalytics.snowplow/tp2"} | `map(string)` | `{}` | no |
| <a name="input_enable_auto_scaling"></a> [enable\_auto\_scaling](#input\_enable\_auto\_scaling) | Whether to enable auto-scaling policies for the service | `bool` | `true` | no |
| <a name="input_iam_permissions_boundary"></a> [iam\_permissions\_boundary](#input\_iam\_permissions\_boundary) | The permissions boundary ARN to set on IAM roles created | `string` | `""` | no |
Expand Down
1 change: 1 addition & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ locals {
collector_hocon = templatefile("${path.module}/templates/config.hocon.tmpl", {
port = var.ingress_port
paths = var.custom_paths
cookie_enabled = var.cookie_enabled
cookie_domain = var.cookie_domain
good_stream_name = var.good_stream_name
bad_stream_name = var.bad_stream_name
Expand Down
2 changes: 1 addition & 1 deletion templates/config.hocon.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ collector {
secure = true
}
cookie {
enabled = true
enabled = ${cookie_enabled}
expiration = "365 days"
name = sp
domains = []
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,12 @@ variable "custom_paths" {
type = map(string)
}

variable "cookie_enabled" {
description = "Whether server side cookies are enabled or not"
default = true
type = bool
}

variable "cookie_domain" {
description = "Optional first party cookie domain for the collector to set cookies on (e.g. acme.com)"
default = ""
Expand Down

0 comments on commit e559930

Please sign in to comment.