Compare commits

..

2 Commits

Author SHA1 Message Date
CMYanko 26ee0f7d34 moved n some rhel specific stuff 2019-02-26 16:35:35 -05:00
CMYanko b5f028837a Update to new UBI images from Red HAt 2019-02-26 11:51:01 -05:00
4 changed files with 24 additions and 24 deletions
+10 -9
View File
@@ -12,16 +12,17 @@
# See the License for the specific language governing permissions and
# limitations under the License.
FROM registry.access.redhat.com/ubi8/ubi
FROM registry.access.redhat.com/ubi7/ubi
MAINTAINER Sonatype <cloud-ops@sonatype.com>
LABEL vendor=Sonatype \
maintainer="Sonatype <cloud-ops@sonatype.com>" \
com.sonatype.license="Apache License, Version 2.0" \
com.sonatype.name="Nexus Repository Manager base image"
ARG NEXUS_VERSION=3.19.1-01
ARG NEXUS_VERSION=3.15.2-01
ARG NEXUS_DOWNLOAD_URL=https://download.sonatype.com/nexus/3/nexus-${NEXUS_VERSION}-unix.tar.gz
ARG NEXUS_DOWNLOAD_SHA256_HASH=7a2e62848abeb047c99e114b3613d29b4afbd635b03a19842efdcd6b6cb95f4e
ARG NEXUS_DOWNLOAD_SHA256_HASH=acde357f5bbc6100eb0d5a4c60a1673d5f1f785e71a36cfa308b8dfa45cf25d0
# configure nexus runtime
ENV SONATYPE_DIR=/opt/sonatype
@@ -37,19 +38,18 @@ ARG NEXUS_REPOSITORY_MANAGER_COOKBOOK_URL="https://github.com/sonatype/chef-nexu
ADD solo.json.erb /var/chef/solo.json.erb
# Install using chef-solo
# Chef version locked to avoid needing to accept the EULA on behalf of whomever builds the image
RUN yum install -y --disableplugin=subscription-manager hostname procps \
&& curl -L https://www.getchef.com/chef/install.sh | bash -s -- -v 14.12.9 \
RUN curl -L https://www.getchef.com/chef/install.sh | bash \
&& /opt/chef/embedded/bin/erb /var/chef/solo.json.erb > /var/chef/solo.json \
&& chef-solo \
--node_name nexus_repository_red_hat_docker_build \
--recipe-url ${NEXUS_REPOSITORY_MANAGER_COOKBOOK_URL} \
--json-attributes /var/chef/solo.json \
&& rpm -qa *chef* | xargs rpm -e \
&& rpm --rebuilddb \
&& rm -rf /etc/chef \
&& rm -rf /opt/chefdk \
&& rm -rf /var/cache/yum \
&& rm -rf /var/chef \
&& yum clean all
&& rm -rf /var/chef
VOLUME ${NEXUS_DATA}
@@ -58,4 +58,5 @@ USER nexus
ENV INSTALL4J_ADD_VM_PARAMS="-Xms1200m -Xmx1200m -XX:MaxDirectMemorySize=2g -Djava.util.prefs.userRoot=${NEXUS_DATA}/javaprefs"
ENTRYPOINT ["/uid_entrypoint.sh"]
CMD ["sh", "-c", "${SONATYPE_DIR}/start-nexus-repository-manager.sh"]
+5 -5
View File
@@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.
FROM centos:centos7
FROM registry.access.redhat.com/ubi7/ubi
MAINTAINER Sonatype <cloud-ops@sonatype.com>
LABEL name="Nexus Repository Manager" \
vendor=Sonatype \
version="3.19.1-01" \
release="3.19.1" \
version="3.15.2-01" \
release="3.15.2" \
url="https://sonatype.com" \
summary="The Nexus Repository Manager server \
with universal support for popular component formats." \
@@ -37,9 +37,9 @@ LABEL name="Nexus Repository Manager" \
io.openshift.expose-services="8081:8081" \
io.openshift.tags="Sonatype,Nexus,Repository Manager"
ARG NEXUS_VERSION=3.19.1-01
ARG NEXUS_VERSION=3.15.2-01
ARG NEXUS_DOWNLOAD_URL=https://download.sonatype.com/nexus/3/nexus-${NEXUS_VERSION}-unix.tar.gz
ARG NEXUS_DOWNLOAD_SHA256_HASH=7a2e62848abeb047c99e114b3613d29b4afbd635b03a19842efdcd6b6cb95f4e
ARG NEXUS_DOWNLOAD_SHA256_HASH=acde357f5bbc6100eb0d5a4c60a1673d5f1f785e71a36cfa308b8dfa45cf25d0
# configure nexus runtime
ENV SONATYPE_DIR=/opt/sonatype
+5 -5
View File
@@ -12,14 +12,14 @@
# See the License for the specific language governing permissions and
# limitations under the License.
FROM registry.access.redhat.com/rhel7/rhel
FROM registry.access.redhat.com/ubi7/ubi
MAINTAINER Sonatype <cloud-ops@sonatype.com>
LABEL name="Nexus Repository Manager" \
vendor=Sonatype \
version="3.19.1-01" \
release="3.19.1" \
version="3.15.2-01" \
release="3.15.2" \
url="https://sonatype.com" \
summary="The Nexus Repository Manager server \
with universal support for popular component formats." \
@@ -37,9 +37,9 @@ LABEL name="Nexus Repository Manager" \
io.openshift.expose-services="8081:8081" \
io.openshift.tags="Sonatype,Nexus,Repository Manager"
ARG NEXUS_VERSION=3.19.1-01
ARG NEXUS_VERSION=3.15.2-01
ARG NEXUS_DOWNLOAD_URL=https://download.sonatype.com/nexus/3/nexus-${NEXUS_VERSION}-unix.tar.gz
ARG NEXUS_DOWNLOAD_SHA256_HASH=7a2e62848abeb047c99e114b3613d29b4afbd635b03a19842efdcd6b6cb95f4e
ARG NEXUS_DOWNLOAD_SHA256_HASH=acde357f5bbc6100eb0d5a4c60a1673d5f1f785e71a36cfa308b8dfa45cf25d0
# configure nexus runtime
ENV SONATYPE_DIR=/opt/sonatype
+4 -5
View File
@@ -20,7 +20,7 @@
[![Join the chat at https://gitter.im/sonatype/nexus-developers](https://badges.gitter.im/sonatype/nexus-developers.svg)](https://gitter.im/sonatype/nexus-developers?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
A Dockerfile for Sonatype Nexus Repository Manager 3, starting with 3.18 the image is based on the [Red Hat Universal Base Image](https://www.redhat.com/en/blog/introducing-red-hat-universal-base-image) while earlier versions used CentOS.
A Dockerfile for Sonatype Nexus Repository Manager 3, based on CentOS.
* [Contribution Guidlines](#contribution-guidelines)
* [Running](#running)
@@ -39,7 +39,7 @@ we would like things to flow.
## Running
To run, binding the exposed port 8081 to the host, use:
To run, binding the exposed port 8081 to the host.
```
$ docker run -d -p 8081:8081 --name nexus sonatype/nexus3
@@ -48,7 +48,7 @@ $ docker run -d -p 8081:8081 --name nexus sonatype/nexus3
To test:
```
$ curl http://localhost:8081/
$ curl -u admin:admin123 http://localhost:8081/service/metrics/ping
```
## Building the Nexus Repository Manager image
@@ -93,8 +93,7 @@ and qualified accounts can pull it from registry.connect.redhat.com.
## Notes
* Our [system requirements](https://help.sonatype.com/display/NXRM3/System+Requirements) should be taken into account when provisioning the Docker container.
* Default user is `admin` and the uniquely generated password can be found in the `admin.password` file inside the volume. See [Persistent Data](#user-content-persistent-data) for information about the volume.
* Default credentials are: `admin` / `admin123`
* It can take some time (2-3 minutes) for the service to launch in a
new container. You can tail the log to determine once Nexus is ready: