-
Notifications
You must be signed in to change notification settings - Fork 128
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Kubernetes Enterprise Operator Release 1.24.0 (#272)
* Updated * Updated * Remove references to rc images --------- Co-authored-by: Mircea Cosbuc <mircea.cosbuc@mongodb.com>
- Loading branch information
1 parent
6621196
commit 0d2de32
Showing
25 changed files
with
574 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
ARG imagebase | ||
FROM ${imagebase} as base | ||
|
||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
|
||
ARG agent_version | ||
|
||
LABEL name="MongoDB Agent" \ | ||
version="${agent_version}" \ | ||
summary="MongoDB Agent" \ | ||
description="MongoDB Agent" \ | ||
vendor="MongoDB" \ | ||
release="1" \ | ||
maintainer="support@mongodb.com" | ||
|
||
RUN microdnf install -y --disableplugin=subscription-manager curl \ | ||
hostname nss_wrapper tar gzip procps\ | ||
&& microdnf upgrade -y \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
RUN mkdir -p /agent \ | ||
&& mkdir -p /var/lib/mongodb-mms-automation \ | ||
&& mkdir -p /var/log/mongodb-mms-automation/ \ | ||
&& chmod -R +wr /var/log/mongodb-mms-automation/ \ | ||
# ensure that the agent user can write the logs in OpenShift | ||
&& touch /var/log/mongodb-mms-automation/readiness.log \ | ||
&& chmod ugo+rw /var/log/mongodb-mms-automation/readiness.log | ||
|
||
|
||
COPY --from=base /data/mongodb-agent.tar.gz /agent | ||
COPY --from=base /data/mongodb-tools.tgz /agent | ||
COPY --from=base /data/LICENSE /licenses/LICENSE | ||
|
||
RUN tar xfz /agent/mongodb-agent.tar.gz \ | ||
&& mv mongodb-mms-automation-agent-*/mongodb-mms-automation-agent /agent/mongodb-agent \ | ||
&& chmod +x /agent/mongodb-agent \ | ||
&& mkdir -p /var/lib/automation/config \ | ||
&& chmod -R +r /var/lib/automation/config \ | ||
&& rm /agent/mongodb-agent.tar.gz \ | ||
&& rm -r mongodb-mms-automation-agent-* | ||
|
||
RUN tar xfz /agent/mongodb-tools.tgz --directory /var/lib/mongodb-mms-automation/ && rm /agent/mongodb-tools.tgz | ||
|
||
USER 2000 | ||
CMD ["/agent/mongodb-agent", "-cluster=/var/lib/automation/config/automation-config.json"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
ARG imagebase | ||
FROM ${imagebase} as base | ||
|
||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
|
||
ARG agent_version | ||
|
||
LABEL name="MongoDB Agent" \ | ||
version="${agent_version}" \ | ||
summary="MongoDB Agent" \ | ||
description="MongoDB Agent" \ | ||
vendor="MongoDB" \ | ||
release="1" \ | ||
maintainer="support@mongodb.com" | ||
|
||
RUN microdnf install -y --disableplugin=subscription-manager --setopt=install_weak_deps=0 nss_wrapper | ||
RUN microdnf install -y --disableplugin=subscription-manager curl \ | ||
hostname tar gzip procps\ | ||
&& microdnf upgrade -y \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
RUN mkdir -p /agent \ | ||
&& mkdir -p /var/lib/mongodb-mms-automation \ | ||
&& mkdir -p /var/log/mongodb-mms-automation/ \ | ||
&& chmod -R +wr /var/log/mongodb-mms-automation/ \ | ||
# ensure that the agent user can write the logs in OpenShift | ||
&& touch /var/log/mongodb-mms-automation/readiness.log \ | ||
&& chmod ugo+rw /var/log/mongodb-mms-automation/readiness.log | ||
|
||
|
||
COPY --from=base /data/mongodb-agent.tar.gz /agent | ||
COPY --from=base /data/mongodb-tools.tgz /agent | ||
COPY --from=base /data/LICENSE /licenses/LICENSE | ||
|
||
RUN tar xfz /agent/mongodb-agent.tar.gz \ | ||
&& mv mongodb-mms-automation-agent-*/mongodb-mms-automation-agent /agent/mongodb-agent \ | ||
&& chmod +x /agent/mongodb-agent \ | ||
&& mkdir -p /var/lib/automation/config \ | ||
&& chmod -R +r /var/lib/automation/config \ | ||
&& rm /agent/mongodb-agent.tar.gz \ | ||
&& rm -r mongodb-mms-automation-agent-* | ||
|
||
RUN tar xfz /agent/mongodb-tools.tgz --directory /var/lib/mongodb-mms-automation/ && rm /agent/mongodb-tools.tgz | ||
|
||
USER 2000 | ||
CMD ["/agent/mongodb-agent", "-cluster=/var/lib/automation/config/automation-config.json"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
86 changes: 86 additions & 0 deletions
86
dockerfiles/mongodb-enterprise-database/1.23.0/ubi/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
ARG imagebase | ||
FROM ${imagebase} as base | ||
|
||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
|
||
|
||
|
||
LABEL name="MongoDB Enterprise Database" \ | ||
version="1.23.0" \ | ||
summary="MongoDB Enterprise Database Image" \ | ||
description="MongoDB Enterprise Database Image" \ | ||
vendor="MongoDB" \ | ||
release="1" \ | ||
maintainer="support@mongodb.com" | ||
|
||
|
||
|
||
|
||
|
||
ENV MMS_HOME /mongodb-automation | ||
ENV MMS_LOG_DIR /var/log/mongodb-mms-automation | ||
|
||
|
||
|
||
RUN microdnf update -y && rm -rf /var/cache/yum | ||
|
||
# these are the packages needed for the agent | ||
RUN microdnf install -y --disableplugin=subscription-manager \ | ||
hostname \ | ||
nss_wrapper \ | ||
procps | ||
|
||
|
||
# these are the packages needed for MongoDB | ||
# (https://docs.mongodb.com/manual/tutorial/install-mongodb-enterprise-on-red-hat-tarball/ "RHEL/CentOS 8" tab) | ||
RUN microdnf install -y --disableplugin=subscription-manager \ | ||
cyrus-sasl \ | ||
cyrus-sasl-gssapi \ | ||
cyrus-sasl-plain \ | ||
krb5-libs \ | ||
libcurl \ | ||
lm_sensors-libs \ | ||
net-snmp \ | ||
net-snmp-agent-libs \ | ||
openldap \ | ||
openssl \ | ||
jq \ | ||
tar \ | ||
findutils | ||
|
||
|
||
|
||
RUN ln -s /usr/lib64/libsasl2.so.3 /usr/lib64/libsasl2.so.2 | ||
|
||
|
||
# Set the required perms | ||
RUN mkdir -p "${MMS_LOG_DIR}" \ | ||
&& chmod 0775 "${MMS_LOG_DIR}" \ | ||
&& mkdir -p /var/lib/mongodb-mms-automation \ | ||
&& chmod 0775 /var/lib/mongodb-mms-automation \ | ||
&& mkdir -p /data \ | ||
&& chmod 0775 /data \ | ||
&& mkdir -p /journal \ | ||
&& chmod 0775 /journal \ | ||
&& mkdir -p "${MMS_HOME}" \ | ||
&& chmod -R 0775 "${MMS_HOME}" | ||
|
||
|
||
|
||
|
||
# USER needs to be set for this image to pass RedHat verification. Some customers have these requirements as well | ||
# It does not matter what number it is, as long as it is set to something. | ||
# However, OpenShift will run the container as a random user, | ||
# and the number in this configuration is not relevant. | ||
USER 2000 | ||
|
||
|
||
# The docker image doesn't have any scripts so by default does nothing | ||
# The script will be copied in runtime from init containers and the operator is expected | ||
# to override the COMMAND | ||
ENTRYPOINT ["sleep infinity"] | ||
|
||
|
||
COPY --from=base /data/licenses/mongodb-enterprise-database /licenses/mongodb-enterprise-database | ||
|
||
|
86 changes: 86 additions & 0 deletions
86
dockerfiles/mongodb-enterprise-database/1.24.0/ubi/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
ARG imagebase | ||
FROM ${imagebase} as base | ||
|
||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
|
||
|
||
|
||
LABEL name="MongoDB Enterprise Database" \ | ||
version="1.24.0" \ | ||
summary="MongoDB Enterprise Database Image" \ | ||
description="MongoDB Enterprise Database Image" \ | ||
vendor="MongoDB" \ | ||
release="1" \ | ||
maintainer="support@mongodb.com" | ||
|
||
|
||
|
||
|
||
|
||
ENV MMS_HOME /mongodb-automation | ||
ENV MMS_LOG_DIR /var/log/mongodb-mms-automation | ||
|
||
|
||
|
||
RUN microdnf update -y && rm -rf /var/cache/yum | ||
|
||
# these are the packages needed for the agent | ||
RUN microdnf install -y --disableplugin=subscription-manager --setopt=install_weak_deps=0 nss_wrapper | ||
RUN microdnf install -y --disableplugin=subscription-manager \ | ||
hostname \ | ||
procps | ||
|
||
|
||
# these are the packages needed for MongoDB | ||
# (https://docs.mongodb.com/manual/tutorial/install-mongodb-enterprise-on-red-hat-tarball/ "RHEL/CentOS 8" tab) | ||
RUN microdnf install -y --disableplugin=subscription-manager \ | ||
cyrus-sasl \ | ||
cyrus-sasl-gssapi \ | ||
cyrus-sasl-plain \ | ||
krb5-libs \ | ||
libcurl \ | ||
lm_sensors-libs \ | ||
net-snmp \ | ||
net-snmp-agent-libs \ | ||
openldap \ | ||
openssl \ | ||
jq \ | ||
tar \ | ||
findutils | ||
|
||
|
||
|
||
RUN ln -s /usr/lib64/libsasl2.so.3 /usr/lib64/libsasl2.so.2 | ||
|
||
|
||
# Set the required perms | ||
RUN mkdir -p "${MMS_LOG_DIR}" \ | ||
&& chmod 0775 "${MMS_LOG_DIR}" \ | ||
&& mkdir -p /var/lib/mongodb-mms-automation \ | ||
&& chmod 0775 /var/lib/mongodb-mms-automation \ | ||
&& mkdir -p /data \ | ||
&& chmod 0775 /data \ | ||
&& mkdir -p /journal \ | ||
&& chmod 0775 /journal \ | ||
&& mkdir -p "${MMS_HOME}" \ | ||
&& chmod -R 0775 "${MMS_HOME}" | ||
|
||
|
||
|
||
|
||
# USER needs to be set for this image to pass RedHat verification. Some customers have these requirements as well | ||
# It does not matter what number it is, as long as it is set to something. | ||
# However, OpenShift will run the container as a random user, | ||
# and the number in this configuration is not relevant. | ||
USER 2000 | ||
|
||
|
||
# The docker image doesn't have any scripts so by default does nothing | ||
# The script will be copied in runtime from init containers and the operator is expected | ||
# to override the COMMAND | ||
ENTRYPOINT ["sleep infinity"] | ||
|
||
|
||
COPY --from=base /data/licenses/mongodb-enterprise-database /licenses/mongodb-enterprise-database | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
35 changes: 35 additions & 0 deletions
35
dockerfiles/mongodb-enterprise-init-appdb/1.24.0/ubi/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
ARG imagebase | ||
FROM ${imagebase} as base | ||
|
||
FROM registry.access.redhat.com/ubi8/ubi-minimal | ||
|
||
ARG version | ||
LABEL name="MongoDB Enterprise Init AppDB" \ | ||
version="mongodb-enterprise-init-appdb-${version}" \ | ||
summary="MongoDB Enterprise AppDB Init Image" \ | ||
description="Startup Scripts for MongoDB Enterprise Application Database for Ops Manager" \ | ||
release="1" \ | ||
vendor="MongoDB" \ | ||
maintainer="support@mongodb.com" | ||
|
||
COPY --from=base /data/readinessprobe /probes/readinessprobe | ||
COPY --from=base /data/probe.sh /probes/probe.sh | ||
COPY --from=base /data/scripts/ /scripts/ | ||
COPY --from=base /data/licenses /licenses/ | ||
COPY --from=base /data/version-upgrade-hook /probes/version-upgrade-hook | ||
|
||
|
||
RUN microdnf update --nodocs \ | ||
&& microdnf -y install --nodocs tar gzip \ | ||
&& microdnf clean all | ||
|
||
COPY --from=base /data/mongodb_tools_ubi.tgz /tools/mongodb_tools.tgz | ||
|
||
|
||
RUN tar xfz /tools/mongodb_tools.tgz --directory /tools \ | ||
&& rm /tools/mongodb_tools.tgz | ||
|
||
USER 2000 | ||
ENTRYPOINT [ "/bin/cp", "-f", "-r", "/scripts/agent-launcher.sh", "/scripts/agent-launcher-lib.sh", "/probes/readinessprobe", "/probes/probe.sh", "/tools", "/opt/scripts/" ] | ||
|
||
|
Oops, something went wrong.