Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gunicorn entrypoint throws error using Dockerfile from official documentation #17599

Closed
3 tasks done
mxchinegod opened this issue Nov 30, 2021 · 1 comment
Closed
3 tasks done
Labels
question & help wanted Use Github discussions instead

Comments

@mxchinegod
Copy link

mxchinegod commented Nov 30, 2021

Attempting to deploy the configuration recommended by documentation to enable Alerting & Reports in a Docker environment, the Superset image(s) fail on an entrypoint with a gunicorn command saying not found.

How to reproduce the bug

  1. Go to official documentation
  2. Create image using aforementioned Dockerfile as instructed (including the .py config)
  3. Attempt to use Docker image in a deployment
  4. Experience failure at entrypoint command for said image.

Expected results

Docker container to work (all else being equal regarding other container nodes)

Actual results

/usr/bin/docker-entrypoint.sh: line 21: exec: gunicorn --bind 0.0.0.0:8088 --access-logfile - --error-logfile - --workers 5 --worker-class gthread --threads 4 --timeout 200 --limit-request-line 4094 --limit-request-field_size 8190 superset.app: not found

Screenshots

If applicable, add screenshots to help explain your problem.

Environment

(please complete the following information):

  • browser type and version:
  • superset version: apache/superset:1.0.1
  • python version: python --version
  • node.js version: node -v
  • any feature flags active:

Checklist

Make sure to follow these steps before submitting your issue - thank you!

  • I have checked the superset logs for python stacktraces and included it here as text if there are any.
  • I have reproduced the issue with at least the latest released version of superset.
  • I have checked the issue tracker for the same issue and I haven't found one similar.

Additional context

My Dockerfile:

version: '3.6'
services:
  redis:
    image: redis:6.0.9-buster
    restart: on-failure
    volumes:
      - /mnt/zfs-nce-qa/infswmnceunxd/superset/redis:/mnt/zfs-nce-qa/infswmnceunxd/superset/redis
  postgres:
    image: postgres
    restart: on-failure
    environment:
      POSTGRES_DB: superset
      POSTGRES_PASSWORD: superset
      POSTGRES_USER: superset
    volumes:
      - /mnt/zfs-nce-qa/infswmnceunxd/superset/postgres:/mnt/zfs-nce-qa/infswmnceunxd/superset/postgres
  worker:
    image: <internally managed Nexus>/superset:latest
    restart: on-failure
    healthcheck:
      disable: true
    depends_on:
      - superset
      - postgres
      - redis
    command: 
      - 'celery --app=superset.tasks.celery_app:app worker --pool=gevent --concurrency=500'
    volumes:
      - /mnt/zfs-nce-qa/infswmnceunxd/superset/python:/mnt/zfs-nce-qa/infswmnceunxd/superset/python
  beat:
    image: <internally managed Nexus>/superset:latest
    restart: on-failure
    healthcheck:
      disable: true
    depends_on:
      - superset
      - postgres
      - redis
    command: 
      - 'celery --app=superset.tasks.celery_app:app beat --pidfile /tmp/celerybeat.pid --schedule /tmp/celerybeat-schedule'
    volumes:
      - /mnt/zfs-nce-qa/infswmnceunxd/superset/python:/mnt/zfs-nce-qa/infswmnceunxd/superset/python
  superset:
    image: <internally managed Nexus>/superset:latest
    restart: on-failure
    environment:
      - SUPERSET_PORT=8088
    ports:
      - "8088:8088"
    depends_on:
      - postgres
      - redis
    command: 
      - 'gunicorn --bind  0.0.0.0:8088 --access-logfile - --error-logfile - --workers 5 --worker-class gthread --threads 4 --timeout 200 --limit-request-line 4094 --limit-request-field_size 8190 superset.app'
    volumes:
      - /mnt/zfs-nce-qa/infswmnceunxd/superset/python:/mnt/zfs-nce-qa/infswmnceunxd/superset/python
volumes:
  redis:
    external: true
  db:
    external: true

superset_config.py.txt

I have also seen that previous versions used superset.app:create_app(), and newer ones leave the command at superset.app according to #8795

I have tried both on the 1.0.1 and latest registry objects.

@mxchinegod mxchinegod added the #bug Bug report label Nov 30, 2021
@mxchinegod
Copy link
Author

Just wanted to add that removing

command: 
      - 'gunicorn --bind  0.0.0.0:8088 --access-logfile - --error-logfile - --workers 5 --worker-class gthread --threads 4 --timeout 200 --limit-request-line 4094 --limit-request-field_size 8190 superset.app:create_app()'

Removed the breaking error and Gunicorn started successfully, so what's going on here?

@geido geido added question & help wanted Use Github discussions instead and removed #bug Bug report labels Jan 25, 2022
@apache apache locked and limited conversation to collaborators Feb 2, 2022
@geido geido converted this issue into discussion #18353 Feb 2, 2022

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
question & help wanted Use Github discussions instead
Projects
None yet
Development

No branches or pull requests

2 participants