docker-taiga / taiga

docker-compose.yml for simple taiga setup
215 stars 75 forks source link

Using TAIGA_PORT kinda breaks it all #42

Closed mrtolkien closed 3 years ago

mrtolkien commented 3 years ago

Title says it all.

I was able to run the docker-compose.yml easily on localhost without changing anything, but setting TAIGA_PORT to anything else than 80 breaks a lot of things. It is also unclear what should be changed in docker-compose.yml to accomodate for it.

Shouldn’t just changing the proxy port from 80:80 to 8080:80 be sufficient? I tried but was then stuck on the error page.

w1ck3dg0ph3r commented 3 years ago

Hi! Can't reproduce this on fresh run. And yes, changing the proxy port mapping is enough. If you're changing TAIGA_PORT after the first run, you should manually modify relevant urls in back/config.py and front/config.json as it was decided to run variable substitution on the first run only to preserve any user-made changes to config files.

mrtolkien commented 3 years ago

You’re right, and my issue was not very clear.

Here is the process I followed:

And the result was that:

Here is a video of the whole process: https://www.youtube.com/watch?v=DdaB2Bp37_o

w1ck3dg0ph3r commented 3 years ago

Still can't reproduce with the exact same steps. This might be a docker for windows issue, I'm not familiar with how networking is implemented here and not able to test it under windows. Maybe the browser console log would shed some light on what may be wrong.

mrtolkien commented 3 years ago

When I posted the issue I had followed the same steps on my Ubuntu 20.04.1 LTS server, so I do not think it is due to WSL2.

Let’s say I want to run Taiga on the port 8080 of a server, we agree the only things I should need to change are:

Is that right? Why do we need to set TAIGA_HOST by the way?

w1ck3dg0ph3r commented 3 years ago

we agree the only things I should need to change are: ... Is that right?

And the TAIGA_PORT, right.

TAIGA_HOST is necessary to configure the frontend to be able to access APIs on this host and the backend to form urls (to e.g. media or static files) correctly.

mrtolkien commented 3 years ago

Why do you need to change TAIGA_PORT since in the internal docker-compose network it will not change and still be 80?

When redirecting the proxy from 80 to 8080, the underlying docker-compose network should not need to change anything. But I’m not sure how Taiga works so that might be where it’s creating issues.

I will try again with changing TAIGA_PORT but it also failed when I tried yesterday (hence the issue being opened).

w1ck3dg0ph3r commented 3 years ago

TAIGA_PORT is not affecting internal connectivity, it is used in conjunction with TAIGA_HOST to form urls for the client: MEDIA_URL = "$TAIGA_SCHEME://$TAIGA_HOST$TAIGA_PORT/media/" "api": "$TAIGA_SCHEME://$TAIGA_HOST$TAIGA_PORT/api/v1/"

mrtolkien commented 3 years ago

I see, indeed I must have screwed something up and I can make it work now. Sorry for the annoyance!