generated from coop-cloud/example
Peertube does not understand the proper public IP address #7
Closed
opened 2021-06-24 16:04:00 +00:00 by decentral1se
·
6 comments
No Branch/Tag Specified
main
renovate/configure
issue-22
6.1.1+v6.3.3
dev
8.4.1+v8.3.1-trixie
8.4.0+v8.3.0-trixie
8.3.2+v8.2.4-trixie
8.3.1+v8.2.3-trixie
8.3.0+v8.2.2-trixie
8.2.0+v8.2.1-trixie
8.0.0+v8.0.2-trixie
7.3.1+v7.3.0-bookworm
7.3.0+v7.3.0-bookworm
7.2.1+v7.3.0-bookworm
7.2.0+v7.3.0-bookworm
7.1.0+v7.1.1-bookworm
7.0.0+v7.0.1-bookworm
6.1.1+v6.3.3-bookworm
6.1.0+v6.3.3-bookworm
6.1.0+v7.3.0-bookworm
7.1.1+v7.1.1-bookworm
6.0.2+v6.0.4-bookworm
6.0.1+v6.0.0-bookworm
6.0.0+v6.0.0-bookworm
5.0.1+v5.2.1-bullseye
5.0.0+v5.2.1-bullseye
4.1.0+v5.2.1-bullseye
4.0.0+v5.0.1-bullseye
3.0.0+v4.3.0-bullseye
2.2.0+v4.2.2-bullseye
2.1.1+v4.1.1-bullseye
2.1.0+v4.1.0-bullseye
2.0.0+v4.0.0-bullseye
1.0.0+v3.4.1-buster
Labels
No items
No labels
Milestone
No items
No Milestone
Projects
Clear projects
No projects
Assignees
3wordchant
aadil (Aadil Ayub)
abra-bot (Abra Bot)
ammaratef45
amras (Sarma)
Apfelwurm
appletalk
arjan
basebuilder
BornDeleuze (Born Deleuze)
Brooke
carla
cas (Cassowary)
codegod100
coopcloud
cyrnel
dannygroenewegen (Danny Groenewegen)
decentral1se (d1)
dede
devydave
fauno (fauno)
flancian
Frando
iexos
jade (Jade Ambrose)
javielico (Javielico)
jjsfunhouse
jmakdah2 (Jackie Makdah)
joe-irving (Joe Irving)
kawaiipunk (KawaiiPunk)
knoflook
kolaente
lambdabundesverband
linnealovespie (April)
marlon (marlon)
mayel
mirsal
moosemower
moritz
nicksellen (Nick Sellen)
notplants
oxaliq (sorrel)
p4u1 (p4u1)
pau
pharaohgraphy (Andrew 🐦🔥❤️🔥✴️)
PhiNatalie
renovate-bot (Comrade Renovate Bot)
ripclap
rix
rscmbbng
sef (sef)
simon
sixsmith (Sixsmith)
stevensting (stevensting)
tobias
trav (Trav Fryer)
val (val (he/him))
vaznasty
virtualboys
wolcen (Chris Thompson)
wykwit
xynosis
yksflip
Clear assignees
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: coop-cloud/peertube#7
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
I am not sure this is an issue? It seems like it might be?
That is odd,
trust_proxyalready contains the whole10.0.0.0/8block, see: https://git.autonomic.zone/coop-cloud/peertube/src/branch/main/compose.yml#L47it looks like the
PEERTUBE_TRUST_PROXYenvironment variable is not read or not taken into accountThanks for looking at this. I see that it is still around in the codebase (via https://github.com/Chocobozzz/PeerTube/search?q=PEERTUBE_TRUST_PROXY) but I do remember having some issues with this. Is the
[...]passed actually as a list to the config file? Maybe we should just hard code this in the file and not pass it via the env var?afaiu, it is passed as a string to the config file and it is then parsed as a json list further down. I'll try and debug it asap.
yeah, that would work, although I believe we should allow it to be overriden for anyone hosting behind a reverse proxy on the outside of the swarm.
Ok, so I just tested this and it works fine on a fresh VM,
X-Forwarded-Foris interpreted correctly, which meansPEERTUBE_TRUST_PROXYis read properly.It must be that you're coming through docker-proxy, which operates as a TCP reverse proxy and thus, cannot tell anything downstream about the client IP address.
In any case, peertube will only be able to get the client IP address if the client connects to traefik "directly" (without going through docker-proxy) which means in our case, using IPv4 and with traefik configured with TCP ports published in host-mode (called host mode networking in our traefik config).
I hope that doesn't make this even more confusing haha.
Right yep, that makes sense! Thanks for testing it out. I was not using host mode networking in my setup. Should that be the recommended setup? As I see it from the warning given by Peertube, the consequences could be a pretty broken Peertube?
I think so, yeah (also for performance reasons and to have traefik reachable from IPv6)