From 8869da5ceb4f3acb55a297670962cdea0963a540 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Fri, 5 Feb 2021 17:37:00 +0100 Subject: [PATCH] check going through oathkeeper --- docker/kratos/oathkeeper/access-rules.yml | 2 +- docker/nginx/conf.d/client.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docker/kratos/oathkeeper/access-rules.yml b/docker/kratos/oathkeeper/access-rules.yml index 97ac5ed3..339e1d67 100644 --- a/docker/kratos/oathkeeper/access-rules.yml +++ b/docker/kratos/oathkeeper/access-rules.yml @@ -91,7 +91,7 @@ preserve_host: true url: "http://accounts:3000" match: - url: "http://oathkeeper<{,:4455}>/<{user,user/**}>" + url: "http://oathkeeper<{,:4455}>/<{user,user/**,track/**}>" methods: - GET authenticators: diff --git a/docker/nginx/conf.d/client.conf b/docker/nginx/conf.d/client.conf index 476ea2a1..825905b6 100644 --- a/docker/nginx/conf.d/client.conf +++ b/docker/nginx/conf.d/client.conf @@ -348,7 +348,7 @@ server { if skylink and ngx.status >= ngx.HTTP_OK and ngx.status < ngx.HTTP_SPECIAL_RESPONSE then local http = require("socket.http") local headers = { Cookie = ngx.req.get_headers()["Cookie"] } - local ok, statusCode, headers, statusText = http.request { url = "http://accounts:3000/track/download/" .. skylink, method = "POST", headers = headers } + local ok, statusCode, headers, statusText = http.request { url = "http://oathkeeper:4455/track/download/" .. skylink, method = "POST", headers = headers } if statusCode ~= ngx.HTTP_NO_CONTENT then ngx.log(ngx.ERR, "accounts endpoint /track/download/" .. skylink .. " failed with error " .. statusCode) end