Home Docker container with postgres and java
Reply: 0

Docker container with postgres and java

user654 Published in March 23, 2018, 7:07 am

I would like a Docker Postgres container with Java. Here my Dockerfile:

FROM postgres AS postgres

FROM openjdk
COPY --from=postgres . .

I don't get any errors. But when I execute java -version it says

command not found

I also tried this:

FROM postgres
RUN apt-get update -y
RUN apt-get install -y oracle-java8-installer

But I get the error

Package oracle-java8-installer is not available, but is referred to by another package.

What did I do wrong? How do I accomplish this?

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.402847 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO