-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Changes to Dockerfile for DSOP (#360)
- Loading branch information
1 parent
7e5de22
commit e97b177
Showing
3 changed files
with
47 additions
and
33 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
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 |
---|---|---|
|
@@ -7,31 +7,34 @@ FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG} | |
ARG collector_version=xxx | ||
ARG module_version=xxx | ||
|
||
LABEL maintainer="StackRox <[email protected]>" | ||
LABEL io.stackrox.collector.module-version="${module_version}" | ||
LABEL io.stackrox.collector.version="${collector_version}" | ||
|
||
ENV COLLECTOR_VERSION=${collector_version} | ||
ENV MODULE_VERSION=${module_version} | ||
ENV COLLECTOR_HOST_ROOT=/host | ||
|
||
RUN yum update -y --nogpgcheck --disableplugin=subscription-manager | ||
RUN yum install -y kmod | ||
RUN rpm -e --nodeps \ | ||
rpm \ | ||
rpm-build-libs \ | ||
rpm-libs \ | ||
python3-rpm \ | ||
subscription-manager \ | ||
python3-subscription-manager-rhsm \ | ||
yum \ | ||
$(rpm -qa *dnf*) \ | ||
python3-hawkey \ | ||
; | ||
|
||
ADD bundle.tar.gz / | ||
|
||
RUN echo "${module_version}" >/kernel-modules/MODULE_VERSION.txt | ||
LABEL name="collector-rhel" \ | ||
vendor="StackRox" \ | ||
maintainer="[email protected]" \ | ||
summary="Runtime data collection for the StackRox Kubernetes Security Platform" \ | ||
description="This image supports runtime data collection in the StackRox Kubernetes Security Platform." \ | ||
io.stackrox.collector.module-version="${module_version}" \ | ||
io.stackrox.collector.version="${collector_version}" | ||
|
||
ENV COLLECTOR_VERSION=${collector_version} \ | ||
MODULE_VERSION=${module_version} \ | ||
COLLECTOR_HOST_ROOT=/host | ||
|
||
COPY scripts / | ||
COPY bundle.tar.gz / | ||
|
||
RUN mv collector-wrapper.sh /usr/local/bin/ && \ | ||
chmod 700 bootstrap.sh && \ | ||
tar -zxf bundle.tar.gz ./COPYING.txt && \ | ||
tar -zxf bundle.tar.gz ./kernel-modules/ && \ | ||
tar -zxf bundle.tar.gz ./usr/local/lib/libsinsp-wrapper.so && \ | ||
tar -zxf bundle.tar.gz ./usr/local/bin/collector && \ | ||
rm -f bundle.tar.gz && \ | ||
dnf upgrade -y && \ | ||
dnf install -y kmod && \ | ||
dnf clean all && \ | ||
rm -rf /var/cache/dnf && \ | ||
echo "${MODULE_VERSION}" > /kernel-modules/MODULE_VERSION.txt | ||
|
||
|
||
EXPOSE 8080 9090 | ||
|
||
|
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