Hello,
Would you please help as I am currently stuck with this issue for a week now.
I am running Things Stack version: ‘3.7’ on a ubuntu 18.04 virtual machine sitting on a LAN, it has domain name and public IP assigned and configured to automatically retrieve and update Let’s Encrypt certificates as per these instructions.
Following same config instructions as above link, I have edited every instance of the domain name thethings.example.com
with my host local IP address. I am able to access host via SSL but , I get Forbidden Token Exchange Refused so the authorisation request generated from within the docker container is not getting redirected to ports 1885 & 8885.
So I get that this issue is around correctly handling requests between the docker container and my ubuntu VM.
Here’s my log:
stack_1 | INFO Request handled duration=360.55µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XGK788MF8NYV9A1D4ZPS response_size=0 status=302 url=https://mydomain.com/
stack_1 | INFO Request handled duration=2.641752ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XGKFZHG6N03RRVQKNF82 response_size=982 status=200 url=https://mydomain.com/console/
stack_1 | INFO Client error duration=1.400846ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XHWFN35TFJJ6YEE2M4DE response_size=198 status=401 url=https://mydomain.com/console/api/auth/token
stack_1 | INFO Request handled duration=481.657µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJ38R5CBVGWT57PEGNAK response_size=0 status=302 url=https://mydomain.com/console/login/ttn-stack?next=/
stack_1 | INFO Request handled duration=534.572µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJ4PNCD8TJ28WTYRCJX2 response_size=0 status=302 url=https://mydomain.com/oauth/authorize?client_id=console&redirect_uri=%2Fconsole%2Foauth%2Fcallback&response_type=code&state=OrQvGCe9SRzNAMaG
stack_1 | INFO Request handled duration=1.480533ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJ56F4981SHFG7QB9Y9M response_size=846 status=200 url=https://mydomain.com/oauth/login?n=%2Foauth%2Fauthorize%3Fclient_id%3Dconsole%26redirect_uri%3D%252Fconsole%252Foauth%252Fcallback%26response_type%3Dcode%26state%3DOrQvGCe9SRzNAMaG
stack_1 | INFO Request handled duration=11.699325ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJ6DF2TR59N4F2ZM201Q response_size=95755 status=200 url=https://mydomain.com/assets/oauth.c475f2586d4d38b3f6a3.css
stack_1 | INFO Request handled duration=47.449028ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJ6D76NJR4JEQBJ8KYW8 response_size=1629970 status=200 url=https://mydomain.com/assets/oauth.3eaa6be75c3c43aa14f9.js
stack_1 | INFO Client error duration=1.638817ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJWDDZSSFSMX2778Y6VH response_size=177 status=401 url=https://mydomain.com/oauth/api/me
stack_1 | INFO Request handled duration=400.577µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJWQKWV92FAG4KGSRPXY response_size=6239 status=200 url=https://mydomain.com/assets/oauth-favicon.svg
stack_1 | INFO Request handled duration=668.806µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJZPSW9X4Q2V73GGNF1B response_size=25520 status=200 url=https://mydomain.com/assets/source-sans-pro-v13-latin_latin-ext-600.117e12cdb861ed7356c805f6f515afbb.woff2
stack_1 | INFO Client error duration=32.678µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XJZRKVJ92SV7HCCT26Q6 response_size=19 status=404 url=https://mydomain.com/assets/oauth-favicon.png
stack_1 | INFO Request handled duration=86.249µs method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02XK0BE4AK41R98FYKFRZT response_size=1096 status=200 url=https://mydomain.com/assets/oauth-favicon.ico
stack_1 | INFO Request handled duration=66.213893ms method=POST namespace=web remote_addr=10.2.80.39 request_id=01ER02Y53WCJCK41PS695AV0PE response_size=0 status=204 url=https://mydomain.com/oauth/api/auth/login
stack_1 | INFO Request handled duration=32.44624ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02Y56HF8YBV62BQ6NP5Z4W response_size=0 status=302 url=https://mydomain.com/oauth/authorize?client_id=console&redirect_uri=%2Fconsole%2Foauth%2Fcallback&response_type=code&state=OrQvGCe9SRzNAMaG
stack_1 | INFO Client error duration=1.045586957s method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02Y57S3F669S7Y9YASD6T7 response_size=1181 status=403 url=https://mydomain.com/console/oauth/callback?code=MF2XI.HTVSLP5DIYB4PMXGS6NFSSX7SS25LTUDYIFULCQ.5NLGJ7HUCUCUXVQSRHOAAF4VQS4YFKHXVNX3OQ3WT4MRHL3OY3MQ&state=OrQvGCe9SRzNAMaG
stack_1 | INFO Client error duration=4.737586ms method=GET namespace=web remote_addr=10.2.80.39 request_id=01ER02Y6W0E5C7PT6W2TPK8690 response_size=198 status=401 url=https://mydomain.com/console/api/auth/token
stack_1 | INFO Request handled duration=34.382µs method=GET namespace=web remote_addr=127.0.0.1 request_id=01ER02YZRJPBYWNN3PRNW7KF2Z response_size=3 status=200 url=http://localhost:1885/healthz/live
Is there a known clear way of debugging this issue or a way to test that the config is working as it is designed to work?