Sign inSign up

oysteinjakobsen/armv7-oracle-java8

By oysteinjakobsen

•Updated almost 11 years ago

Debian Wheezy ARMv7hf image with Oracle Java 8, meant for use on Raspberry Pi 2 and similar devices.

Image
1

10K+

oysteinjakobsen/armv7-oracle-java8 repository overview

⁠Introduction

This image is built to run on ARMv7 devices, like the Raspberry Pi 2. It can be used to build and run Java programs using Oracle Java 8.

Source code is on GitHub⁠

TIP: Check out this article⁠ if you haven't yet got Docker up and running on your Raspberry Pi 2.

⁠How to use this image

⁠Run a simple Java program

The image has a mount-point /data that can be used to supply the Java program to the container. Here's how to run a small Java program /myapp/MyApp.class:

docker run \
  --rm -it \
  -v /myapp:/data \
  oysteinjakobsen/armv7-oracle-java8 \
  java /data/MyApp.class

⁠Running a webapp

Let's assume you have a webapp packaged as a jar with an embedded Jetty container. Then you can run your program like this:

docker run \
  --rm -it \
  -p 8080:8080 \
  -v /myapp:/data \
  oysteinjakobsen/armv7-oracle-java8 \
  java -jar /data/MyWebApp.jar

⁠Making your own image

You can also package your application in your own image by creating a Dockerfile:

FROM oysteinjakobsen/armv7-oracle-java8
ADD /projects/mywebapp /data
EXPOSE 8080
CMD ["java" "-jar" "/data/mywebapp/MyWebApp.jar"]

Rembember that the image must be built on the ARMv7 device.

Tag summary

Content type

Image

Digest

sha256:6b7dcf86a…

Size

128.2 MB

Last updated

almost 11 years ago

docker pull oysteinjakobsen/armv7-oracle-java8