-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error when using initial-data when communicating through traefik #187
Comments
Hm. Do you run Openslides behind a self configured proxy? Please have a look which request comes in. Maybe your proxy does not forward the correct content-type header. The openslides tool uses GRPC to connect to the server, so the instance expects respective header (https://github.com/OpenSlides/OpenSlides/blob/main/proxy/caddy_base.json#L167). |
the proxy that we use informs about a 502 response by the service. that's what Caddy / the proxy service is telling: {
"level": "error",
"ts": 1659357956.5641763,
"logger": "http.log.error",
"msg": "net/http: HTTP/1.x transport connection broken: malformed HTTP response \"\\x00\\x00\\x06\\x04\\x00\\x00\\x00\\x00\\x00\\x00\\x05\\x00\\x00@\\x00\"",
"request": {
"remote_addr": "192.168.0.3:54710",
"proto": "HTTP/1.1",
"method": "POST",
"host": "openslides.example.org:443",
"uri": "/Manage/InitialData",
"headers": {
"User-Agent": [
"grpc-go/1.45.0"
],
"Content-Type": [
"application/grpc"
],
"X-Forwarded-Port": [
"443"
],
"X-Forwarded-Proto": [
"https"
],
"X-Forwarded-Server": [
"6e13e21b3b77"
],
"Authorization": [
"xxx"
],
"Grpc-Timeout": [
"4925074u"
],
"X-Forwarded-For": [
"11.22.33.44"
],
"X-Real-Ip": [
"11.22.33.44"
],
"Te": [
"trailers"
],
"X-Forwarded-Host": [
"openslides.exmaple.org:443"
],
"Accept-Encoding": [
"gzip"
]
}
},
"duration": 0.005011078,
"status": 502,
"err_id": "r6sa2evtm",
"err_trace": "reverseproxy.statusError (reverseproxy.go:783)"
} it shows that the content-type header is passed. but nonetheless, the issue is caused by the employed reverse proxy traefik, it requires to specify a specific URL scheme for grpc services. here's an imperfect snippet as reference for the services:
proxy:
labels:
traefik.enable: "true"
traefik.http.services.openslides-proxy.loadbalancer.server.port: "8000"
traefik.http.routers.openslides.service: openslides-proxy
traefik.http.routers.openslides.rule: Host(`openslides.example.org`)
traefik.http.services.openslides-manage.loadbalancer.server.port: "8000"
traefik.http.services.openslides-manage.loadbalancer.server.scheme: h2c
traefik.http.routers.openslides-manage.service: openslides-manage
traefik.http.routers.openslides-manage.rule: Host(`openslides.example.org`) && PathPrefix(`/Manage/`) i'd like to keep this issue open until #186 is solved (or not), so that other users can find this information. |
i have a reachable OpenSlides instance, but when i execute the
initial-data
subcommand, i get an error:as a sidenote, the
README.md
doesn't give any hint what the purpose and possible contents of this initial data would be, and hence i really can't assess whether this situation poses a problem.addendum: i seems that this command would at least set the
superadmin
password as i can't login to the instance.The text was updated successfully, but these errors were encountered: