diff --git a/Dockerfile b/Dockerfile index 8a05f55..6fc1229 100644 --- a/Dockerfile +++ b/Dockerfile @@ -61,4 +61,4 @@ WORKDIR $PYSETUP_PATH EXPOSE 5000-9000 # Run your app -CMD [ "python", "-m", "storage_service" ] \ No newline at end of file +CMD [ "./run-queue.sh" ] \ No newline at end of file diff --git a/run-queue.sh b/run-queue.sh index 3f1d882..283b925 100755 --- a/run-queue.sh +++ b/run-queue.sh @@ -1,6 +1,10 @@ #!/bin/sh - -rq worker --with-scheduler +if [[ $1 == "--queue" || $1 == "-q" ]]; then + rq worker --with-scheduler + exit 0 +else + python -m storage_service +fi exec "$@" \ No newline at end of file