Compare commits

..

7 Commits

Author SHA1 Message Date
Brad Beck 1f5f927d71 Updating to NXRM 3.3.2-02 2017-06-19 15:30:14 -05:00
Nicholas Blair 97d3daf7fe update java download url (#74) 2017-05-23 09:52:17 -05:00
Brad Beck 222b63f15d Updating to NXRM 3.3.1-01 2017-05-01 15:26:44 -05:00
Brad Beck 7a91327b7f Updating to NXRM 3.3.0-01 2017-04-11 15:49:47 -05:00
Jeffry Hesse 65915646ed English!
Learn it!
2017-04-11 10:05:23 -08:00
Jeffry Hesse b7e9f09126 Update README.md
Change issue link to reflect that we use JIRA for our bug/etc... triage
2017-04-11 10:03:22 -08:00
Brad Beck 04c718287b [NEXUS-12835] Move java memory opts to INSTALL4J_ADD_VM_PARAMS (#72) 2017-04-10 13:08:16 -05:00
2 changed files with 16 additions and 18 deletions
+11 -8
View File
@@ -20,7 +20,7 @@ LABEL vendor=Sonatype \
com.sonatype.license="Apache License, Version 2.0" \
com.sonatype.name="Nexus Repository Manager base image"
ARG NEXUS_VERSION=3.2.1-01
ARG NEXUS_VERSION=3.3.2-02
ARG NEXUS_DOWNLOAD_URL=https://download.sonatype.com/nexus/3/nexus-${NEXUS_VERSION}-unix.tar.gz
RUN yum install -y \
@@ -30,8 +30,9 @@ RUN yum install -y \
# configure java runtime
ENV JAVA_HOME=/opt/java \
JAVA_VERSION_MAJOR=8 \
JAVA_VERSION_MINOR=112 \
JAVA_VERSION_BUILD=15
JAVA_VERSION_MINOR=131 \
JAVA_VERSION_BUILD=11 \
JAVA_DOWNLOAD_HASH=d54c1d3a095b4ff2b6607d096fa80163
# configure nexus runtime
ENV SONATYPE_DIR=/opt/sonatype
@@ -44,7 +45,7 @@ ENV NEXUS_HOME=${SONATYPE_DIR}/nexus \
RUN mkdir -p /opt \
&& curl --fail --silent --location --retry 3 \
--header "Cookie: oraclelicense=accept-securebackup-cookie; " \
http://download.oracle.com/otn-pub/java/jdk/${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-b${JAVA_VERSION_BUILD}/server-jre-${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-linux-x64.tar.gz \
http://download.oracle.com/otn-pub/java/jdk/${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-b${JAVA_VERSION_BUILD}/${JAVA_DOWNLOAD_HASH}/server-jre-${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-linux-x64.tar.gz \
| gunzip \
| tar -x -C /opt \
&& ln -s /opt/jdk1.${JAVA_VERSION_MAJOR}.0_${JAVA_VERSION_MINOR} ${JAVA_HOME}
@@ -60,7 +61,11 @@ RUN mkdir -p ${NEXUS_HOME} \
# configure nexus
RUN sed \
-e '/^nexus-context/ s:$:${NEXUS_CONTEXT}:' \
-i ${NEXUS_HOME}/etc/nexus-default.properties
-i ${NEXUS_HOME}/etc/nexus-default.properties \
&& sed \
-e '/^-Xms/d' \
-e '/^-Xmx/d' \
-i ${NEXUS_HOME}/bin/nexus.vmoptions
RUN useradd -r -u 200 -m -c "nexus role account" -d ${NEXUS_DATA} -s /bin/false nexus \
&& mkdir -p ${NEXUS_DATA}/etc ${NEXUS_DATA}/log ${NEXUS_DATA}/tmp ${SONATYPE_WORK} \
@@ -73,8 +78,6 @@ EXPOSE 8081
USER nexus
WORKDIR ${NEXUS_HOME}
ENV JAVA_MAX_MEM=1200m \
JAVA_MIN_MEM=1200m \
EXTRA_JAVA_OPTS=""
ENV INSTALL4J_ADD_VM_PARAMS="-Xms1200m -Xmx1200m"
CMD ["bin/nexus", "run"]
+5 -10
View File
@@ -44,19 +44,14 @@ $ docker logs -f nexus
logs, and storage. This directory needs to be writable by the Nexus
process, which runs as UID 200.
* Three environment variables can be used to control the JVM arguments
* There is an environment variable that can used to pass JVM arguments to the startup script
* `JAVA_MAX_MEM`, passed as -Xmx. Defaults to `1200m`.
* `INSTALL4J_ADD_VM_PARAMS`, passed to the Install4J startup script. Defaults to `-Xms1200m -Xmx1200m`.
* `JAVA_MIN_MEM`, passed as -Xms. Defaults to `1200m`.
* `EXTRA_JAVA_OPTS`. Additional options can be passed to the JVM via
this variable.
These can be used supplied at runtime to control the JVM:
This can be supplied at runtime:
```
$ docker run -d -p 8081:8081 --name nexus -e JAVA_MAX_MEM=768m sonatype/nexus3
$ docker run -d -p 8081:8081 --name nexus -e INSTALL4J_ADD_VM_PARAMS="-Xms2g -Xmx2g" sonatype/nexus3
```
* Another environment variable can be used to control the Nexus Context Path
@@ -108,6 +103,6 @@ docker build --rm --tag nexus-custom --build-arg NEXUS_VERSION=3.x.y --build-arg
Looking to contribute to our Docker image but need some help? There's a few ways to get information or our attention:
* File a public issue [here on GitHub](https://github.com/sonatype/docker-nexus3/issues)
* File an issue [on our public JIRA](https://issues.sonatype.org/projects/NEXUS/)
* Check out the [Nexus3](http://stackoverflow.com/questions/tagged/nexus3) tag on Stack Overflow
* Check out the [Nexus Repository User List](https://groups.google.com/a/glists.sonatype.com/forum/?hl=en#!forum/nexus-users)