Skip to content
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

Swap out keycloak-connect for jsonwebtoken for JWT authentication #109

Merged
merged 1 commit into from
Apr 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions app/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ const helmet = require('helmet');

const { name: appName, version: appVersion } = require('./package.json');
const carboneCopyApi = require('./src/components/carboneCopyApi');
const keycloak = require('./src/components/keycloak');
const log = require('./src/components/log')(module.filename);
const httpLogger = require('./src/components/log').httpLogger;
const { getGitRevision, prettyStringify } = require('./src/components/utils');
const { getConfigBoolean, getGitRevision, prettyStringify } = require('./src/components/utils');
const v2Router = require('./src/routes/v2');

const { authorizedParty } = require('./src/middleware/authorizedParty');
Expand Down Expand Up @@ -52,9 +51,8 @@ if (process.env.NODE_ENV !== 'test') {
}

// Use Keycloak OIDC Middleware
if (config.has('keycloak.enabled')) {
if (getConfigBoolean('keycloak.enabled')) {
log.info('Running in authenticated mode');
app.use(keycloak.middleware());
} else {
log.info('Running in public mode');
}
Expand Down
Loading
Loading