-
Notifications
You must be signed in to change notification settings - Fork 14
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
Add support for third-party services #1303
Conversation
c7aae51
to
ab028b4
Compare
ab028b4
to
07ba123
Compare
07ba123
to
f6018a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
I have some improvement suggestions. Let's discuss how and when to implement these.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice team work!
Now let other perform double check, especially documentation.
19cc951
to
9580d69
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm requesting changes here to prevent this PR from being merged while not being ready. First, #1310 should be improved upon and merged into this branch, resolving the issue that the plugins are not reachable from the Next.js server when running the frontend in prod mode (i.e. built in Docker).
…er types refactor: show modals after the open flag is set to true in order to populate the default form data on load.
For json, typescript, nginx, bash
refactor: user menu hook moved inside component fix: create license files tests: create svg component test and fix muiSnackbar test refactor: update plugin config url
Listen to main server block so that requests to port 80 that do not match server_names are not handled by the first block
5ec608d
to
f201d6a
Compare
frontend/config/getPlugins.ts
Outdated
if (/^(https?:\/\/)/.test(pluginName)) { | ||
return pluginName | ||
} else if (process.env.NODE_ENV === 'development') { | ||
return `http://localhost/plugin/${pluginName}` | ||
} else { | ||
const baseUrl = process.env.RSD_REVERSE_PROXY_URL | ||
return `${baseUrl}/plugin/${pluginName}` | ||
} | ||
} | ||
|
||
async function getPlugin({pluginName, token}:{pluginName: string, token?: string}){ | ||
const url = getPluginBaseUrl(pluginName) + '/api/v1/config' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe move /api/v1/config
into getPluginUrl and use it only in elseif cases (when only plugin name is provided)?
frontend/config/getPlugins.ts
Outdated
} else if (process.env.NODE_ENV === 'development') { | ||
return `http://localhost/plugin/${pluginName}` | ||
} else { | ||
const baseUrl = process.env.RSD_REVERSE_PROXY_URL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we can add default http://nginx
?
const baseUrl = process.env.RSD_REVERSE_PROXY_URL ?? 'http://nginx'
BREAKING: adds a new environment variable RSD_REVERSE_PROXY url that is required by the frontend container to construct the plugin base url when running it in the same docker network.
f201d6a
to
c0e9d0c
Compare
Quality Gate passed for 'authentication'Issues Measures |
Quality Gate failed for 'rsd-frontend'Failed conditions |
Sonar cloud complains about |
Fixes #1288
Changes proposed in this pull request:
userMenu
andsoftwareEditNav
(seetype PluginSlot
)data
attribute to the user token which containseduPersonEntitlements
if the user logs in via HelmholtzIDHow to test:
PR Checklist:
docker-compose.yml