docker-library / python

Docker Official Image packaging for Python

Home Page:https://www.python.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cant enable and find core dumped

vitassuper opened this issue · comments

When my Python program fails in a Docker container, no core dump or backtrace is generated. I tried enabling it using ulimit -c unlimited, but it didn't help. I cannot find a stack trace to determine why my program is crashing. All I get is a corrupted size vs. prev_size message.

Do you have an example that we can take a look at?

Do you have an example that we can take a look at?

Here is my program https://github.com/vitassuper/flux-bot and screen below
image

It would be helpful to add env vars to your docker compose to get it running quicky

environment:
      - DEBUG_MODE=false
      - SQLALCHEMY_DATABASE_URI=postgres://root:root@postgres
      - SQLALCHEMY_DATABASE_DB=connector
      - POSTGRES_SERVER=postgres
      - POSTGRES_USER=root
      - POSTGRES_PASSWORD=root
      - POSTGRES_DB=trading_view_connector
      - APP_KEY=1234
      - TELEGRAM_BOT_TOKEN=1234
      - API_PASSWORD=1234
      - TELEGRAM_CHAT_ID=1234
      - TELEGRAM_CHAT_ID2=1234

It would be helpful to add env vars to your docker compose to get it running quicky

environment:
      - DEBUG_MODE=false
      - SQLALCHEMY_DATABASE_URI=postgres://root:root@postgres
      - SQLALCHEMY_DATABASE_DB=connector
      - POSTGRES_SERVER=postgres
      - POSTGRES_USER=root
      - POSTGRES_PASSWORD=root
      - POSTGRES_DB=trading_view_connector
      - APP_KEY=1234
      - TELEGRAM_BOT_TOKEN=1234
      - API_PASSWORD=1234
      - TELEGRAM_CHAT_ID=1234
      - TELEGRAM_CHAT_ID2=1234

Good to know, but I read tip from docker doc
Don't use environment variables to pass sensitive information, such as passwords, in to your containers. Use [secrets](https://docs.docker.com/compose/use-secrets/) instead.
Anyway, this is not the reason for my issue

Yeah I know, I was trying to get the app started to see if I can reproduce. It starts but I didn't configure it correctly so it just gives errors

Yeah I know, I was trying to get the app started to see if I can reproduce. It starts but I didn't configure it correctly so it just gives errors

What errors did you get?

Maybe this is useful, but looking at the repo, flux-bot is using a slim variant. This variant strips debug info for file size, where the full fat images do not. Just found this out in #825 (comment)