Skip to content

Commit

Permalink
feat: Add clickhouse password to dictionary definition (#19344)
Browse files Browse the repository at this point in the history
Add clickhouse password to dictionary definition
  • Loading branch information
robbie-c authored Dec 15, 2023
1 parent ea40b68 commit a1c6ec9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions posthog/models/channel_type/sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
MergeTreeEngine,
ReplicationScheme,
)
from posthog.settings import CLICKHOUSE_CLUSTER
from posthog.settings import CLICKHOUSE_CLUSTER, CLICKHOUSE_PASSWORD

CHANNEL_DEFINITION_TABLE_NAME = "channel_definition"
CHANNEL_DEFINITION_DICTIONARY_NAME = "channel_definition_dict"
Expand Down Expand Up @@ -68,7 +68,7 @@ def format_value(value):
type_if_organic Nullable(String)
)
PRIMARY KEY domain, kind
SOURCE(CLICKHOUSE(TABLE '{CHANNEL_DEFINITION_TABLE_NAME}'))
SOURCE(CLICKHOUSE(TABLE '{CHANNEL_DEFINITION_TABLE_NAME}' PASSWORD '{CLICKHOUSE_PASSWORD}'))
LIFETIME(MIN 3000 MAX 3600)
LAYOUT(COMPLEX_KEY_HASHED())
"""
Expand Down

0 comments on commit a1c6ec9

Please sign in to comment.