Merge ~pjdc/charm-k8s-mattermost/+git/charm-k8s-mattermost:logging into charm-k8s-mattermost:master

Proposed by Paul Collins
Status: Merged
Approved by: Paul Collins
Approved revision: e57910aa3a750d85ed3c06f241dfa12644609f99
Merged at revision: 438a6ee97ac61c14e811b689f17f38d3efc31bc0
Proposed branch: ~pjdc/charm-k8s-mattermost/+git/charm-k8s-mattermost:logging
Merge into: charm-k8s-mattermost:master
Diff against target: 28 lines (+8/-0)
2 files modified
config.yaml (+4/-0)
src/charm.py (+4/-0)
Reviewer Review Type Date Requested Status
Stuart Bishop (community) Approve
Mattermost Charmers Pending
Review via email: mp+384602@code.launchpad.net

Commit message

configure logging via the pod spec, add "debug" setting

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Stuart Bishop (stub) wrote :

Yup

review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision 438a6ee97ac61c14e811b689f17f38d3efc31bc0

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/config.yaml b/config.yaml
index 1bb6bca..985f777 100644
--- a/config.yaml
+++ b/config.yaml
@@ -1,4 +1,8 @@
1options:1options:
2 debug:
3 type: boolean
4 description: Set the Mattermost log level to DEBUG, otherwise INFO.
5 default: false
2 open_server:6 open_server:
3 type: boolean7 type: boolean
4 description: Allows users to sign up from the root page without an invite8 description: Allows users to sign up from the root page without an invite
diff --git a/src/charm.py b/src/charm.py
index 5f55abd..05e97e9 100755
--- a/src/charm.py
+++ b/src/charm.py
@@ -126,6 +126,10 @@ class MattermostK8sCharm(CharmBase):
126 'MM_CONFIG': db_uri,126 'MM_CONFIG': db_uri,
127 'MM_SQLSETTINGS_DATASOURCE': db_uri,127 'MM_SQLSETTINGS_DATASOURCE': db_uri,
128 'MM_ENABLEOPENSERVER': config['open_server'],128 'MM_ENABLEOPENSERVER': config['open_server'],
129 # logging
130 'MM_LOGSETTINGS_CONSOLELEVEL': 'DEBUG' if config['debug'] else 'INFO',
131 'MM_LOGSETTINGS_ENABLECONSOLE': 'true',
132 'MM_LOGSETTINGS_ENABLEFILE': 'false',
129 }133 }
130134
131 if config['site_url']:135 if config['site_url']:

Subscribers

People subscribed via source and target branches