Commit 0bd7c9fa authored by Jérome Perrin's avatar Jérome Perrin

metabase wip

parent 721ba78d
[instance-profile] [instance-profile]
filename = instance.cfg.in filename = instance.cfg.in
md5sum = b2a0acafc7dc9f7592be5ffd9459ffcd md5sum = 5355b75d006d355fe5da7448e8ae68fd
...@@ -42,10 +42,9 @@ promises = ...@@ -42,10 +42,9 @@ promises =
[metabase-promise] [metabase-promise]
<= monitor-promise-base <= monitor-promise-base
module = check_port_listening module = check_url_available
name = $${:_buildout_section_name_}.py name = $${:_buildout_section_name_}.py
config-hostname= $${metabase-instance:ip} config-url= $${metabase-instance:url}/api/session/properties
config-port = $${metabase-instance:port}
[metabase-keystore] [metabase-keystore]
recipe = plone.recipe.command recipe = plone.recipe.command
...@@ -55,7 +54,7 @@ command = ...@@ -55,7 +54,7 @@ command =
-alias "metabase" \ -alias "metabase" \
-keyalg RSA \ -keyalg RSA \
-keypass "$${:password}" \ -keypass "$${:password}" \
-dname "CN=metabase,OU=Unit,O=Organization,L=City,S=State,C=Country" \ -dname "CN=$${metabase-instance:ip},OU=Unit,O=Organization,L=City,S=State,C=Country" \
-keystore "$${:file}" \ -keystore "$${:file}" \
-storepass "$${:password}" -storepass "$${:password}"
file = $${directory:etc}/.metabase_keystore file = $${directory:etc}/.metabase_keystore
......
...@@ -47,18 +47,8 @@ class TestMetabaseSetup(MetabaseTestCase): ...@@ -47,18 +47,8 @@ class TestMetabaseSetup(MetabaseTestCase):
self.assertTrue(resp.text) self.assertTrue(resp.text)
# get a setup token as described in https://github.com/metabase/metabase/issues/4240#issuecomment-290717451 # get a setup token as described in https://github.com/metabase/metabase/issues/4240#issuecomment-290717451
# XXX this can timeout for some reasons, maybe a race condition in metabase, but if
# we retry it seems to work
try:
properties = requests.get( properties = requests.get(
parse.urljoin(url, '/api/session/properties'), parse.urljoin(url, '/api/session/properties'), verify=False,
verify=False,
timeout=10).json()
except requests.ReadTimeout:
self.logger.exception("getting setup token failed, retrying")
properties = requests.get(
parse.urljoin(url, '/api/session/properties'),
verify=False,
timeout=10).json() timeout=10).json()
email = "youlooknicetoday@email.com" email = "youlooknicetoday@email.com"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment