Skip to content

jakarta.servlet.ServletException: Handler dispatch failed: java.lang.UnsatisfiedLinkError: /tmp/minify-html-java-nativelib14195985978970674651linux-x64.nativelib #273

@ilhanyumer

Description

@ilhanyumer

The minify-html work on my computer (I have Windows 11 and coretto-25 on IntelliJ IDEA) but it does not work with amazoncorretto:25-jdk with Dockerfile.

I use Java 25, Spring Boot 3.5.11, and Gradle 9.

On Dockerfile I use amazoncorretto:25-jdk (same with amazoncorretto:25-alpine-jdk). I have the following configuration:

private final Configuration minConfiguration = new Configuration.Builder().setKeepHtmlAndHeadOpeningTags(true).setMinifyCss(true).build();

And when I run the following code:

String minified = MinifyHtml.minify(messageContent, minConfiguration);

I get the following error:

jakarta.servlet.ServletException: Handler dispatch failed: java.lang.UnsatisfiedLinkError: /tmp/minify-html-java-nativelib14195985978970674651linux-x64.nativelib: /lib64/libm.so.6: version `GLIBC_2.35' not found (required by /tmp/minify-html-java-nativelib14195985978970674651linux-x64.nativelib)

What am I missing here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions