Hi ! I have tried to install Metaflow in an on-pre...
# ask-metaflow
b
Hi ! I have tried to install Metaflow in an on-prem fashion following this guide :
<https://github.com/outerbounds/metaflow-with-airflow-minio>
• created a cluster using microk8s (because i had other apps running but deployment went just fine) • installed and forwarded MinIO and ran the
create-bucket.py
script without problem • created the secret using my own secrets • installed the metaflow suite using the command described in step
9
and tried to run a flow. (i forwarded all ports manually before creating the ingress routes just to be sure) the flow runs just fine and i can see the results by browsing the MinIO interface. But i cant access it from the UI. the
pod/metaflow-metaflow-ui
keeps on crashing with this trace :
Copy code
Traceback (most recent call last):
  File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/root/services/ui_backend_service/ui_server.py", line 167, in <module>
    main()
  File "/root/services/ui_backend_service/ui_server.py", line 144, in main
    the_app = app(loop, DBConfiguration())
  File "/root/services/ui_backend_service/ui_server.py", line 54, in app
    loop.run_until_complete(async_db._init(db_conf=db_conf, create_triggers=DB_TRIGGER_CREATE))
  File "/usr/lib/python3.7/asyncio/base_events.py", line 584, in run_until_complete
    return future.result()
  File "/root/services/data/postgres_async_db.py", line 100, in _init
    raise e
  File "/root/services/data/postgres_async_db.py", line 85, in _init
    echo=AIOPG_ECHO)
  File "/opt/latest/lib/python3.7/site-packages/aiopg/pool.py", line 300, in from_pool_fill
    await self._fill_free_pool(False)
  File "/opt/latest/lib/python3.7/site-packages/aiopg/pool.py", line 343, in _fill_free_pool
    **self._conn_kwargs,
  File "/opt/latest/lib/python3.7/site-packages/aiopg/connection.py", line 1225, in _connect
    await self._poll(self._waiter, self._timeout)  # type: ignore
  File "/opt/latest/lib/python3.7/site-packages/aiopg/connection.py", line 881, in _poll
    await asyncio.wait_for(self._waiter, timeout)
  File "/usr/lib/python3.7/asyncio/tasks.py", line 416, in wait_for
    return fut.result()
  File "/opt/latest/lib/python3.7/site-packages/aiopg/connection.py", line 788, in _ready
    state = self._conn.poll()
psycopg2.OperationalError: fe_sendauth: no password supplied
wich resembles this issue on the metaflow-tools github https://github.com/outerbounds/metaflow-tools/issues/48 Does anyone knows how to fix it ?
b
tried this on a local minikube cluster today and was getting the same errors. In my case this was due to the relevant environment variables not getting filled by the Helm chart for the metaflow-ui service. Will see about a fix for the chart if that is the cause instead of my setup. If you're missing the environment variables for the metaflow-ui service as well, then a quick fix would be to patch the same values that the metaflow-service is using, as they use the same DB in the chart, and the metaflow-service seemed to setup correctly.
b
Hi @bulky-afternoon-92433 thanks for your reply, wich ones of the variables needs to be filled out and with what value ? thanks for the answer
b
The env vars that had blank values in my test deployment, which shouldn't be blank due to being required:
Copy code
MF_METADATA_DB_NAME
MF_METADATA_DB_PSWD
MF_METADATA_DB_USER
if you deployed the Helm chart with the default
postgresql.enabled
, it created a database with placeholder credentials alongside. Value for all of these should be
metaflow
in that case. You can verify by comparing the values for the metadata service:
Copy code
kubectl describe pod metaflow-metaflow-service |grep MF_METADATA
https://github.com/outerbounds/metaflow-tools/pull/49 here's an update to the chart that should fix the issue
1
thankyou 2
b
thanks a lot ! it works !
🎉 1
b
excellent, glad to hear :)
b
i just needed to change the line 10-14 of the
k8s/helm/metaflow/charts/metaflow-ui/values.yaml
and add the url to my server and since i dont know how to add an env variable from the
helm install
command