10

When I look at package lists they suggest that all sorts of Java 8 packages exist for Alpine, but when I try to install them I always get:

apk add openjdk8
ERROR: unsatisfiable constraints:
  openjdk8-jre (missing):
    required by: world[openjdk8]

And this also happens with other Java 8 packages, such as openjdk8-jre.

According to this: https://pkgs.alpinelinux.org/packages?name=openjdk8&branch=v3.10&arch=x86_64 the package exists for version 3.10 64 bit, which I'm using, so why wouldn't it install?

2
  • 1
    Could you post the contents of /etc/apk/repositories?
    – valiano
    Commented Dec 13, 2019 at 6:56
  • 1
    @valiano After looking at that file, I noticed that most repos were commented out, after uncommenting them "openjdk8" installed, thanks
    – Maxim
    Commented Dec 13, 2019 at 16:25

2 Answers 2

10

openjdk is in the community repo. It seems that you didn't enable community repo. Go ahead and first enable community repo by uncommenting the community repo in /etc/apk/repositories, then run apk update then execute apk add openjdk11.

1
4

Try another version of openJdk8:

RUN apk add openjdk8=8.242.08-r0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .