How to setup oracle connection - docker-compose/python version issues: from urllib.parse import urlparse, urlunparse, ImportError: No module named parse

Issue Summary

I followed the steps from this post

After creating the oracle specific image, I ran the following steps:

docker-compose up -d ===> WORKS FINE
docker-compose run --rm server create_db ===> causes error

After running “docker-compose run --rm server create_db”, I get the following error:

/home/akash/Documents/redash/venv/lib/python2.7/site-packages/paramiko/ CryptographyDeprecationWarning: Python 2 is no longer supported by the Python core team. Support for it is now deprecated in cryptography, and will be removed in the next release.
  from cryptography.hazmat.backends import default_backend
Starting redash_postgres_1 ... done
Starting redash_redis_1    ... done
Traceback (most recent call last):
  File "/app/", line 6, in <module>
    from redash.cli import manager
  File "/app/redash/", line 13, in <module>
    from . import settings
  File "/app/redash/settings/", line 7, in <module>
    from .helpers import (
  File "/app/redash/settings/", line 2, in <module>
    from urllib.parse import urlparse, urlunparse
ImportError: No module named parse

So as you can see here, its trying to import parse from urllib.parse but couldn’t.

I’m using “FROM redash/redash:latest” tag. I think this pulling a version of redash that is based on Python3, isn’t it? But seems like my docker-compose is unable to load Phython3 related libraries. I don’t know why docker-compose is unable to do so. Is there some version conflicts here that I need to resolve, whether related to docker-compose, or the redash itself?

Also, this issue is not found if I use the master repository to create the new image, since this doesn’t use Python2 libraries.

Technical details: