blob: 21998b8c0a976ec2929c96c3445c234aa1743891 [file] [log] [blame]
FROM adoptopenjdk/openjdk11:jre-11.0.11_9-alpine
LABEL maintainer="ONAP Integration team, morgan.richomme@orange.com"
LABEL Description="Reference ONAP JAVA 11 image based on alpine"
ENV JAVA_OPTS="-Xms256m -Xmx1g"
ENV JAVA_SEC_OPTS=""
ARG user=onap
ARG group=onap
# Install additional tools
RUN apk add --no-cache openssl ca-certificates
# Create a group and user
RUN addgroup -S $group && adduser -G $group -D $user && \
mkdir /var/log/$user && \
mkdir /app && \
chown -R $user:$group /var/log/$user && \
chown -R $user:$group /app
# Tell docker that all future commands should be run as the onap user
USER $user
WORKDIR /app
ENTRYPOINT exec java $JAVA_SEC_OPTS $JAVA_OPTS -jar /app/app.jar