Repository navigation
JavaScript Support #10190
thomasdarimont
started this conversation in
Archive
JavaScript Support
#10190
Replies: 3 comments
|
Moving this to archive as we already have an issue open to address Nashorn removal related to supporting OpenJDK 17. |
0 replies
|
Need help in enabling the script feature. I have mapped the script feature using the environment variable. Attached is the complete dockerfile. Built an image based on that and still under Authentication - > Add Execution step, I don't see an script option to create Javascript. Do I need to add the javascript as well under the /opt/keycloak/providers/ during the build stage itself. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
The Nashorn JS engine has eventually been removed in Java 15. This makes the Javascript support not usable with a plain JDK > 14.
However, it is possible to add the self-contained nashorn-core library manually to the
$KC_HOME/providersfolder.After a config rebuild (via
kc.sh buildor--auto-build) one can use the JavaScript support with JDK versions > JDK 14.I just verified this with the latest JDK 17.
The scripting feature can be enabled with
--features=scriptsif one wants to be able to edit scripts in the admin ui then enable theupload-scriptsfeature as well, via--features=scripts,upload-scripts.I think it would be a good idea to add the JS engine to the distribution by default - once the JDK will be updated to JDK17+, WDYT?
All reactions