remove unused backend auth host and rename lazy auth host

Signed-off-by: MiniDigger <admin@benndorf.dev>
This commit is contained in:
MiniDigger 2021-11-23 07:49:45 +01:00 committed by MiniDigger | Martin
parent 7c20548ef4
commit 90a71b6c07
4 changed files with 6 additions and 10 deletions

View File

@ -64,7 +64,7 @@ jobs:
CI: true CI: true
# keep these in sync with compose! # keep these in sync with compose!
proxyHost: "http://hangar_new_backend:8080" proxyHost: "http://hangar_new_backend:8080"
authHost: "http://hangar_new_auth:8000" authHost: "https://hangar-auth.benndorf.dev"
host: "0.0.0.0" host: "0.0.0.0"
PUBLIC_HOST: "https://hangar.benndorf.dev" PUBLIC_HOST: "https://hangar.benndorf.dev"
run: (cd frontend && yarn build) run: (cd frontend && yarn build)

View File

@ -48,8 +48,7 @@ jobs:
CI: true CI: true
# keep these in sync with compose! # keep these in sync with compose!
proxyHost: "http://hangar_new_backend:8080" proxyHost: "http://hangar_new_backend:8080"
authHost: "http://hangar_new_auth:8000" authHost: "https://hangar-auth.benndorf.dev"
lazyAuthHost: "https://hangar-auth.benndorf.dev"
host: "0.0.0.0" host: "0.0.0.0"
PUBLIC_HOST: "https://hangar.benndorf.dev" PUBLIC_HOST: "https://hangar.benndorf.dev"
run: (cd frontend && yarn build) run: (cd frontend && yarn build)

View File

@ -11,8 +11,7 @@ services:
environment: environment:
# keep these in sync with gh-action! # keep these in sync with gh-action!
proxyHost: "http://hangar_new_backend:8080" proxyHost: "http://hangar_new_backend:8080"
authHost: "http://hangar_new_auth:8000" authHost: "https://hangar-auth.benndorf.dev"
lazyAuthHost: "https://hangar-auth.benndorf.dev"
host: "0.0.0.0" host: "0.0.0.0"
PUBLIC_HOST: "https://hangar.benndorf.dev" PUBLIC_HOST: "https://hangar.benndorf.dev"
stdin_open: true stdin_open: true

View File

@ -18,7 +18,6 @@ require('dotenv').config();
const proxyHost = process.env.proxyHost || 'http://localhost:8080'; const proxyHost = process.env.proxyHost || 'http://localhost:8080';
const oauthHost = process.env.oauthHost || 'http://localhost:4444'; const oauthHost = process.env.oauthHost || 'http://localhost:4444';
const authHost = process.env.authHost || 'http://localhost:8000'; const authHost = process.env.authHost || 'http://localhost:8000';
const lazyAuthHost = process.env.lazyAuthHost || 'http://localhost:8000';
const publicHost = process.env.PUBLIC_HOST || 'http://localhost:3000'; const publicHost = process.env.PUBLIC_HOST || 'http://localhost:3000';
const host = process.env.host || 'localhost'; const host = process.env.host || 'localhost';
const nodeEnv = process.env.NODE_ENV; const nodeEnv = process.env.NODE_ENV;
@ -61,7 +60,6 @@ export default {
proxyHost, proxyHost,
oauthHost, oauthHost,
authHost, authHost,
lazyAuthHost,
publicHost, publicHost,
host, host,
nodeEnv, nodeEnv,
@ -135,8 +133,8 @@ export default {
proxyHost + '/*/sitemap.xml', proxyHost + '/*/sitemap.xml',
proxyHost + '/statusz', proxyHost + '/statusz',
// auth // auth
lazyAuthHost + '/avatar', authHost + '/avatar',
lazyAuthHost + '/oauth/logout', authHost + '/oauth/logout',
oauthHost + '/oauth2', oauthHost + '/oauth2',
], ],
@ -202,7 +200,7 @@ export default {
"'self'", "'self'",
'https://www.google-analytics.com', 'https://www.google-analytics.com',
'https://www.gravatar.com', 'https://www.gravatar.com',
lazyAuthHost, authHost,
'data: papermc.io paper.readthedocs.io', 'data: papermc.io paper.readthedocs.io',
'https:', // ppl can use images in descriptions, we would need an image proxy or smth 'https:', // ppl can use images in descriptions, we would need an image proxy or smth
], ],