Skip to content
Open
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
2 changes: 2 additions & 0 deletions images/init-native/func.init.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
runtime: docker
format: http-stream
2 changes: 0 additions & 2 deletions images/runtime/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ FROM openjdk:8-slim
COPY target/runtime-*.jar target/dependency/*.jar /function/runtime/
COPY src/main/c/libfnunixsocket.so /function/runtime/lib/

RUN ["/usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java", "-Xshare:dump"]

# UseCGroupMemoryLimitForHeap looks up /sys/fs/cgroup/memory/memory.limit_in_bytes inside the container to determine
# what the heap should be set to. This is an experimental feature at the moment, thus we need to unlock to use it.
#
Expand Down
4 changes: 1 addition & 3 deletions images/runtime/Dockerfile-jre11
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@ FROM openjdk:11-jre-slim
COPY target/runtime-*.jar target/dependency/*.jar /function/runtime/
COPY src/main/c/libfnunixsocket.so /function/runtime/lib/

RUN ["/usr/bin/java", "-Xshare:dump"]

# The UseExeperimentalVMOptions, UseCGroupMemoryLimitForHeap and MaxRAMFraction options that were used in the JDK 9 builds are
# no longer supported in JDK 11 - so these have been removed. We now rely on the built-in ContainerSupport option that Linux JDKs
# use to configure themselves when detecting they are running in a container.
#
# SerialGC is used here as it's likely that we'll be running many JVMs on the same host machine and it's also likely
# that the number of JVMs will outnumber the number of available processors.
#
ENTRYPOINT [ "/usr/bin/java", "-XX:-UsePerfData", "-XX:+UseSerialGC", "-Xshare:on", \
ENTRYPOINT [ "/usr/bin/java", "-XX:-UsePerfData", "-XX:+UseSerialGC", \
"-Djava.library.path=/function/runtime/lib", "-cp", "/function/app/*:/function/runtime/*", "com.fnproject.fn.runtime.EntryPoint" ]