You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2019/01/03 19:33:33 UTC

[GitHub] mistercrunch closed pull request #6504: Enhance Docker

mistercrunch closed pull request #6504: Enhance Docker
URL: https://github.com/apache/incubator-superset/pull/6504
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/contrib/docker/docker-compose.yml b/contrib/docker/docker-compose.yml
index 49119055fb..3cea89fad7 100644
--- a/contrib/docker/docker-compose.yml
+++ b/contrib/docker/docker-compose.yml
@@ -7,6 +7,7 @@ services:
       - 6379:6379
     volumes:
       - redis:/data
+
   postgres:
     image: postgres:10
     restart: unless-stopped
@@ -18,6 +19,7 @@ services:
       - 5432:5432
     volumes:
       - postgres:/var/lib/postgresql/data
+
   superset:
     build:
       context: ../../
@@ -44,6 +46,7 @@ services:
       - ./superset_config.py:/home/superset/superset/superset_config.py
       # this is needed for development, remove with SUPERSET_ENV=production
       - ../../superset:/home/superset/superset
+
 volumes:
   postgres:
     external: false
diff --git a/contrib/docker/docker-entrypoint.sh b/contrib/docker/docker-entrypoint.sh
index ff70ffc151..169e990fea 100755
--- a/contrib/docker/docker-entrypoint.sh
+++ b/contrib/docker/docker-entrypoint.sh
@@ -4,14 +4,19 @@ set -ex
 if [ "$#" -ne 0 ]; then
     exec "$@"
 elif [ "$SUPERSET_ENV" = "development" ]; then
-    superset worker &
+    celery worker --app=superset.sql_lab:celery_app --pool=gevent -Ofair &
     # needed by superset runserver
     (cd superset/assets/ && npm ci && npm run sync-backend)
     (cd superset/assets/ && npm run dev) &
-    flask run -p 8088 --with-threads --reload --debugger --host=0.0.0.0
+    FLASK_APP=superset:app flask run -p 8088 --with-threads --reload --debugger --host=0.0.0.0
 elif [ "$SUPERSET_ENV" = "production" ]; then
-    superset worker &
-    superset runserver -a 0.0.0.0 -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1))
+    celery worker --app=superset.sql_lab:celery_app --pool=gevent -Ofair &
+    gunicorn --bind  0.0.0.0:8088 \
+        --workers $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) \
+        --timeout 60 \
+        --limit-request-line 0 \
+        --limit-request-field_size 0 \
+        superset:app
 else
     superset --help
 fi


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org