yetanalytics / lrsql

A SQL-based Learning Record Store
https://www.sqllrs.com
Apache License 2.0
89 stars 18 forks source link

Failing to authenticate #345

Closed vosdim-supportsquare closed 11 months ago

vosdim-supportsquare commented 11 months ago

Hello,

I am trying to run the latest version of lrsql by using a docker image of my own making, it only contains 2 lines :

FROM yetanalytics/lrsql ENTRYPOINT ["bin/run_postgres.sh"]

This deploys just fine, providing some environment variables :

apiVersion: apps/v1 kind: StatefulSet metadata: name: lrsql namespace: ${application.namespace} spec: replicas: ${application.replicas} selector: matchLabels: app: lrsql serviceName: lrsql template: metadata: labels: app: lrsql spec: containers:

I can access the login page, but when i provide the credentials I defined above, nothing happens in the GUI and the folowing output is found in the logs :

14:33:15.222 [main] INFO com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Starting... 14:33:15.785 [main] INFO com.zaxxer.hikari.pool.HikariPool - HikariPool-1 - Added connection org.postgresql.jdbc.PgConnection@4bdd6fe0 14:33:15.831 [main] INFO com.zaxxer.hikari.HikariDataSource - HikariPool-1 - Start completed. 14:33:15.833 [main] INFO lrsql.system.database - Starting new connection for postgres database... 14:33:16.628 [main] INFO lrsql.system.lrs - Starting new LRS 14:33:16.669 [main] WARN lrsql.util.cert - No cert files found. Creating self-signed cert! 14:33:17.332 [main] INFO org.eclipse.jetty.util.log - Logging initialized @11066ms to org.eclipse.jetty.util.log.Slf4jLog 14:33:17.761 [main] INFO org.eclipse.jetty.server.Server - jetty-9.4.53.v20231009; built: 2023-10-09T12:29:09.265Z; git: 27bde00a0b95a1d5bbee0eae7984f891d2d0f8c9; jvm 11.0.14+9-alpine-r0 14:33:17.803 [main] INFO o.e.j.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@1e23e1ef{/,null,AVAILABLE} 14:33:17.827 [main] INFO o.e.jetty.server.AbstractConnector - Started ServerConnector@4095ebff{HTTP/1.1, (http/1.1, h2c)}{0.0.0.0:8080} 14:33:17.846 [main] INFO o.e.jetty.util.ssl.SslContextFactory - x509=X509@7b4791d9(lrsql_keystore,h=[com.yetanalytics.lrsql],a=[],w=[]) for Server@649a76c1[provider=null,keyStore=null,trustStore=null] 14:33:17.927 [main] INFO o.e.jetty.server.AbstractConnector - Started ServerConnector@470ce6e7{SSL, (ssl, alpn, h2, http/1.1)}{0.0.0.0:8443} 14:33:17.928 [main] INFO org.eclipse.jetty.server.Server - Started @11662ms 14:33:17.929 [main] INFO lrsql.system.webserver - Starting new webserver at host 0.0.0.0, HTTP port 8080, and SSL port 8443 14:33:17.929 [main] INFO lrsql.system.webserver -


|\ \ \ \ | | | | | | \ _\ \ | | || | | | / \ | | | | | / \ | \ / __| __| | | ____| | || | || |/ /\ \ \ \ | | | | / /| | | | | |/ \ / / | |\ /| | / / / | / \ \ \ \ | | | | /| | | | | | | | | || | | | | | |_| | | | | /__\ _\ | || |___|\| || ||| ||_||| || _||_//


   |  _____|  |  ___  |  | |          | |        |  ___  |  |  _____|
   | |_____   | |   | |  | |          | |        | |___| |  | |_____
   |_____  |  | |   | |  | |          | |        |   ____|  |_____  |
    _____| |  | |__ | |  | |_____     | |_____   | |\  \     _____| |
   |_______|  |_____\_\  |_______|    |_______|  |_|  \__\  |_______|
                    (c) 2021-2023 Yet Analytics Inc.

14:33:56.691 [qtp855277552-23] ERROR i.p.http.impl.servlet-interceptor - {:msg "error-stylobate triggered", :context {:response {:status 200, :headers {"Content-Length" "169848", "Last-Modified" "Fri, 13 Oct 2023 14:42:44 GMT", "Content-Type" "font/ttf"}, :body #object[sun.net.www.protocol.jar.JarURLConnection$JarURLInputStream 0x675f7c4e "sun.net.www.protocol.jar.JarURLConnection$JarURLInputStream@675f7c4e"]}, :io.pedestal.interceptor.chain/stack (#Interceptor{:name :io.pedestal.http.impl.servlet-interceptor/terminator-injector}), :request {:protocol "HTTP/1.1", :async-supported? true, :remote-addr "10.84.1.86", :servlet-response #object[org.eclipse.jetty.server.Response 0x42a282e8 "HTTP/1.1 200 \nDate: Thu, 19 Oct 2023 14:33:56 GMT\r\nContent-Length: 169848\r\nLast-Modified: Fri, 13 Oct 2023 14:42:44 GMT\r\nContent-Type: font/ttf\r\n\r\n"], :servlet #object[io.pedestal.http.servlet.FnServlet 0x5e7923d6 "io.pedestal.http.servlet.FnServlet@5e7923d6"], :headers {"sec-fetch-site" "same-origin", "x-forwarded-host" "dev-lrsql.", "host" "dev-lrsql.", "user-agent" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/118.0", "cookie" "_ga=GA1.1.1387383280.1680861545; _ga_0C4M1PWYZ7=GS1.1.1697721509.43.1.1697721525.0.0.0; _ga_T11SF3WXX2=GS1.1.1697721510.40.1.1697721525.45.0.0; _ga_K2SPJK2C73=GS1.1.1697721510.36.1.1697721525.45.0.0", "x-forwarded-port" "443", "referer" "https://dev-lrsql.***/admin/css/style.css", "accept" "application/font-woff2;q=1.0,application/font-woff;q=0.9,/;q=0.8", "accept-language" "en-US,en;q=0.5", "x-forwarded-scheme" "https", "sec-fetch-dest" "font", "x-forwarded-for" "81.82.253.13", "accept-encoding" "gzip, deflate, br", "x-forwarded-proto" "https", "x-scheme" "https", "sec-fetch-mode" "cors", "x-request-id" "4dacd17625e195ae380a0ada5ff14932", "x-real-ip" "81.82.253.13"}, :server-port 80, :servlet-request #object[org.eclipse.jetty.server.Request 0x9e3d27f "Request(GET //dev-lrsql.supportsquare.io/admin/css/fonts/RobotoCondensed-Regular.ttf)@9e3d27f"], :path-info "/admin/css/fonts/RobotoCondensed-Regular.ttf", :uri "/admin/css/fonts/RobotoCondensed-Regular.ttf", :server-name "dev-lrsql.", :query-string nil, :body #object[org.eclipse.jetty.server.HttpInputOverHTTP 0x4e647b41 "HttpInputOverHTTP@4e647b41[c=0,q=0,[0]=null,s=STREAM]"], :scheme :http, :request-method :get, :context-path ""}, :com.yetanalytics.lrs.pedestal.interceptor/statement-html? true, :enter-async [#object[io.pedestal.http.impl.servlet_interceptor$start_servlet_async 0x188705a7 "io.pedestal.http.impl.servlet_interceptor$start_servlet_async@188705a7"]], :io.pedestal.interceptor.chain/terminators (#object[io.pedestal.http.impl.servlet_interceptor$terminator_inject$fn28762 0xf77f2f2 "io.pedestal.http.impl.servlet_interceptor$terminator_inject$fn28762@f77f2f2"]), :servlet-response #object[org.eclipse.jetty.server.Response 0x42a282e8 "HTTP/1.1 200 \nDate: Thu, 19 Oct 2023 14:33:56 GMT\r\nContent-Length: 169848\r\nLast-Modified: Fri, 13 Oct 2023 14:42:44 GMT\r\nContent-Type: font/ttf\r\n\r\n"], :com.yetanalytics.lrs.pedestal.interceptor/path-prefix "/xapi", :servlet #object[io.pedestal.http.servlet.FnServlet 0x5e7923d6 "io.pedestal.http.servlet.FnServlet@5e7923d6"], :servlet-request #object[org.eclipse.jetty.server.Request 0x9e3d27f "Request(GET //dev-lrsql./admin/css/fonts/RobotoCondensed-Regular.ttf)@9e3d27f"], :com.yetanalytics.lrs.pedestal.interceptor/www-auth-realm "LRS", :io.pedestal.interceptor.chain/execution-id 1, :servlet-config #object[org.eclipse.jetty.servlet.ServletHolder$Config 0x1810b949 "org.eclipse.jetty.servlet.ServletHolder$Config@1810b949"], :async? #object[io.pedestal.http.impl.servlet_interceptor$servlet_asyncQMARK 0x75c36779 "io.pedestal.http.impl.servlet_interceptor$servlet_asyncQMARK@75c36779"]}, :line 242} clojure.lang.ExceptionInfo: org.eclipse.jetty.io.EofException in Interceptor :io.pedestal.http.impl.servlet-interceptor/ring-response - at io.pedestal.interceptor.chain$throwableGT_ex_info.invokeStatic(chain.clj:35) at io.pedestal.interceptor.chain$throwableGT_ex_info.invoke(chain.clj:32) at io.pedestal.interceptor.chain$try_f.invokeStatic(chain.clj:57) at io.pedestal.interceptor.chain$try_f.invoke(chain.clj:44) at io.pedestal.interceptor.chain$leave_all_with_binding.invokeStatic(chain.clj:254) at io.pedestal.interceptor.chain$leave_all_with_binding.invoke(chain.clj:237) at io.pedestal.interceptor.chain$leave_all$fn23643.invoke(chain.clj:268) at clojure.lang.AFn.applyToHelper(AFn.java:152) at clojure.lang.AFn.applyTo(AFn.java:144) at clojure.core$apply.invokeStatic(core.clj:667) at clojure.core$with_bindingsSTAR.invokeStatic(core.clj:1990) at clojure.core$with_bindingsSTAR.doInvoke(core.clj:1990) at clojure.lang.RestFn.invoke(RestFn.java:425) at io.pedestal.interceptor.chain$leave_all.invokeStatic(chain.clj:266) at io.pedestal.interceptor.chain$leave_all.invoke(chain.clj:260) at io.pedestal.interceptor.chain$execute.invokeStatic(chain.clj:379) at io.pedestal.interceptor.chain$execute.invoke(chain.clj:352) at io.pedestal.interceptor.chain$execute.invokeStatic(chain.clj:389) at io.pedestal.interceptor.chain$execute.invoke(chain.clj:352) at io.pedestal.http.impl.servlet_interceptor$interceptor_service_fn$fn__28787.invoke(servlet_interceptor.clj:351) at io.pedestal.http.servlet.FnServlet.service(servlet.clj:28) at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:799) at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:554) at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1440) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:505) at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1355) at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) at org.eclipse.jetty.server.Server.handle(Server.java:516) at org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:487) at org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:732) at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:479) at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:277) at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:105) at org.eclipse.jetty.io.ChannelEndPoint$1.run(ChannelEndPoint.java:104) at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:883) at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1034) at java.base/java.lang.Thread.run(Thread.java:829) Caused by: org.eclipse.jetty.io.EofException: null at org.eclipse.jetty.io.ChannelEndPoint.flush(ChannelEndPoint.java:280) at org.eclipse.jetty.io.WriteFlusher.flush(WriteFlusher.java:422) at org.eclipse.jetty.io.WriteFlusher.write(WriteFlusher.java:277) at org.eclipse.jetty.io.AbstractEndPoint.write(AbstractEndPoint.java:381) at org.eclipse.jetty.server.HttpConnection$SendCallback.process(HttpConnection.java:837) at org.eclipse.jetty.util.IteratingCallback.processing(IteratingCallback.java:248) at org.eclipse.jetty.util.IteratingCallback.iterate(IteratingCallback.java:229) at org.eclipse.jetty.server.HttpConnection.send(HttpConnection.java:555) at org.eclipse.jetty.server.HttpChannel.sendResponse(HttpChannel.java:1014) at org.eclipse.jetty.server.HttpChannel.write(HttpChannel.java:1086) at org.eclipse.jetty.server.HttpOutput.channelWrite(HttpOutput.java:285) at org.eclipse.jetty.server.HttpOutput.channelWrite(HttpOutput.java:269) at org.eclipse.jetty.server.HttpOutput.write(HttpOutput.java:873) at clojure.java.io$fn11651.invokeStatic(io.clj:307) at clojure.java.io$fn__11651.invoke(io.clj:302) at clojure.lang.MultiFn.invoke(MultiFn.java:239) at clojure.java.io$copy.invokeStatic(io.clj:406) at clojure.java.io$copy.doInvoke(io.clj:391) at clojure.lang.RestFn.invoke(RestFn.java:425) at io.pedestal.http.impl.servlet_interceptor$fn28441.invokeStatic(servlet_interceptor.clj:78) at io.pedestal.http.impl.servlet_interceptor$fn28441.invoke(servlet_interceptor.clj:42) at io.pedestal.http.impl.servlet_interceptor$fn28422$G28406__28429.invoke(servlet_interceptor.clj:38) at io.pedestal.http.impl.servlet_interceptor$write_body.invokeStatic(servlet_interceptor.clj:93) at io.pedestal.http.impl.servlet_interceptor$write_body.invoke(servlet_interceptor.clj:91) at io.pedestal.http.impl.servlet_interceptor$send_response.invokeStatic(servlet_interceptor.clj:170) at io.pedestal.http.impl.servlet_interceptor$send_response.invoke(servlet_interceptor.clj:162) at io.pedestal.http.impl.servlet_interceptor$leave_ring_response.invokeStatic(servlet_interceptor.clj:229) at io.pedestal.http.impl.servlet_interceptor$leave_ring_response.invoke(servlet_interceptor.clj:218) at io.pedestal.interceptor.chain$try_f.invokeStatic(chain.clj:54) ... 39 common frames omitted Caused by: java.io.IOException: Broken pipe at java.base/sun.nio.ch.FileDispatcherImpl.writev0(Native Method) at java.base/sun.nio.ch.SocketDispatcher.writev(SocketDispatcher.java:51) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:182) at java.base/sun.nio.ch.IOUtil.write(IOUtil.java:130) at java.base/sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:493) at java.base/java.nio.channels.SocketChannel.write(SocketChannel.java:507) at org.eclipse.jetty.io.ChannelEndPoint.flush(ChannelEndPoint.java:274) ... 67 common frames omitted

Can someone tell me what I am doing wrong or how to fix this ? I do manage to get version 3.7 up and running but newer versions seem to fail.

vosdim-supportsquare commented 11 months ago

In the end, it turned out I needed this to get my setup working