Closed MohamedElashri closed 1 year ago
@MohamedElashri how did you setup the instance?
I did it via
docker run --rm -it --name mathics-web -p 8000:8000 -v /tmp:/usr/src/app/data mathicsorg/mathics --mode ui
Ok - thanks for the information. I guess we need to change the Django side .
I will try to get this all fixed up within a week or so
@MohamedElashri Mathics-django master at https://github.com/Mathics3/mathics-django/commit/ab98c70f2d7ae87a89956760a13361757c4863a6 has been updated to allow setting ALLOWED_HOSTS
via an environment variable. Please try it when you get a chance.
What remains here is just to allow passing new environment variables through.
Hello, That's great. However, this problem comes with docker, so we need to allow passing new environment variables (and build the image) before it can be tested.
I had intended to look at this, but I might not be able to get around to this. This kind of thing is pretty straightforward to add, and the existing code has a pattern to follow. Also, this is open-source code which means anyone can contribute.
Maybe you can try adding and putting in a PR?
(A trepidation I have here though is that the API is a little unstable right now - so fixing this up just might open the flood gates for that, unless you work with the last packaged versions)
@MohamedElashri - Please let me know if #12 fixes things with the current master of Mathics Django.
Hello
There is a problem with using the docker image on any public instance. You will get an error like that.
I think you will need a way to specify
ALLOWED_HOSTS = ['*']
in Djangosettings.py
by default if we are using docker.