I exported my Edge application via Bndtools (EdgeApp.bndrun → Export) and got an openems-edge.jar
. Using the same JAR, Dockerfile, and docker-compose.yml
:
- On Windows (Docker Desktop):
- Runs without issue.
- On Docker under WSL:
- Also runs fine.
- On Docker in a Raspberry Pi (Raspbian 11 64-bit):
- Container immediately crashes with:
java.lang.NoClassDefFoundError: org/apache/felix/framework/util/SecureAction
at org.apache.felix.framework.Felix.<clinit>(Felix.java:114)
…
Caused by: java.lang.ClassNotFoundException: org.apache.felix.framework.util.SecureAction
at java.base/java.net.URLClassLoader.findClass(Unknown Source)
…
Even pulling the latest openems/openems-edge
image from Docker Hub and using the same Compose file yields the same error on ARM64.
Has anyone seen SecureAction
load on x86 but not on Raspbian? Why would the identical setup work under Desktop/WSL but fail on Raspberry Pi?
Dockerfile:
# Use a multi-arch JRE 21 image (Temurin is available for ARM64)
FROM eclipse-temurin:21-jre-alpine
# Set working directory inside the container
WORKDIR /usr/lib/openems
# Copy the built OpenEMS Edge JAR file into the container
COPY openems-edge.jar .
# Expose port 8080 for the Apache Felix Web Console
EXPOSE 8080 8081
# Run the JAR with the configuration directory set to /etc/openems/
CMD ["java", "-Dfelix.cm.dir=/etc/openems.d", "-jar", "openems-edge.jar"]
docker-compose.yml:
services:
openems-edge:
image: my-openems-edge
container_name: openems_edge
restart: unless-stopped
# devices:
# - "/dev/ttyUSB0:/dev/ttyUSB0"
volumes:
- openems-edge-conf:/etc/openems.d:rw
- openems-edge-data:/var/opt/openems/data:rw
ports:
- "8080:8080"
- "8081:8081"
volumes:
openems-edge-conf:
openems-edge-data: