Home > OS >  How to run a containerized streamlit app in a headless/noninteractive mode?
How to run a containerized streamlit app in a headless/noninteractive mode?

Time:04-26

Streamlit server (run e.g. with streamlit run app-name.py) upon first run for each user requires interaction from her - accepting or rejecting this intro message:

  Welcome to Streamlit!

  If you are one of our development partners or are interested in
  getting personal technical support, please enter your email address
  below. Otherwise, you may leave the field blank.

  Email:

Streamlit then waits for input, failing to daemonize (run in background), which quickly causes docker containers in Kubernetes or Openshift to crash (enter the famous crash-loop back off procedure).

How to avoid such crashing, by running Streamlit in headless/noninteractive mode?

CodePudding user response:

In the streamlit documentation you can find a detailed list of configurable options. Scroll down and you will find the headless option. Just edit the config file.

headless = true

Please also refer to this post.

  • Related