UNCLASSIFIED
Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Ironbank Containers
C
Confluent
Confluent Component Operator
cp-server-operator-6.1.1
Commits
7eb1c3bc
Commit
7eb1c3bc
authored
Aug 23, 2021
by
Scott Stroud
Browse files
meh
parent
9419d280
Pipeline
#438977
passed with stages
in 25 minutes and 59 seconds
Changes
3
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
92 additions
and
254 deletions
+92
-254
.gitignore
.gitignore
+2
-1
Dockerfile
Dockerfile
+32
-20
hardening_manifest.yaml
hardening_manifest.yaml
+58
-233
No files found.
.gitignore
View file @
7eb1c3bc
...
@@ -2,4 +2,5 @@ archive.key
...
@@ -2,4 +2,5 @@ archive.key
*.whl
*.whl
*.jar
*.jar
*.tar.gz
*.tar.gz
*.rpm
*.rpm
\ No newline at end of file
*.rpm.1
Dockerfile
View file @
7eb1c3bc
...
@@ -9,17 +9,22 @@ FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}
...
@@ -9,17 +9,22 @@ FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}
ENV
LANG="C.UTF-8"
ENV
LANG="C.UTF-8"
# IB custom ENV vars
# IB custom ENV vars
ENV
RPM_VERSION=6.1.
2
-1
ENV
RPM_VERSION=6.1.
3
-1
ENV
IMG_TAR_VERSION=6.1.
2
.1
ENV
IMG_TAR_VERSION=6.1.
3
.1
USER
root
USER
root
########################################
########################################
## Install Python
## Install Python
RUN
dnf update
-y
&&
dnf
install
-y
python38.x86_64 python38-pip-wheel.noarch
openssl
tar
procps iputils
hostname
findutils nc
\
RUN
dnf update
-y
--nodocs
&&
dnf
install
-y
--nodocs
python3
openssl
tar
procps iputils
hostname
\
&&
ln
-s
/usr/bin/python3 /usr/bin/python
\
&&
ln
-s
/usr/bin/python3 /usr/bin/python
\
&&
ln
-s
/usr/bin/pip3 /usr/bin/pip
&&
ln
-s
/usr/bin/pip3 /usr/bin/pip
\
&&
alias
python
=
python3
\
&&
alias
pip
=
pip3
\
&&
alternatives
--set
python /usr/bin/python3
\
&&
dnf clean all
\
&&
rm
-rf
/var/cache/dnf
## Python Installed
## Python Installed
########################################
########################################
...
@@ -27,11 +32,18 @@ RUN dnf update -y && dnf install -y python38.x86_64 python38-pip-wheel.noarch op
...
@@ -27,11 +32,18 @@ RUN dnf update -y && dnf install -y python38.x86_64 python38-pip-wheel.noarch op
## Add the Confluent Docker Utility Belt which helps with starting the proper applications
## Add the Confluent Docker Utility Belt which helps with starting the proper applications
## https://github.com/confluentinc/common-docker/tree/master/utility-belt
## https://github.com/confluentinc/common-docker/tree/master/utility-belt
COPY
cp-init-container-operator-6.1.2.1_UsrLocalLib64.tar.gz /usr/local/lib64/
COPY
cp-init-container-operator-6.1.2.1_1_UsrLocalLib.tar.gz /usr/local/lib/
COPY
confluent_docker_utils-0.0.44-py3-none-any.whl /tmp/confluent_docker_utils-0.0.44-py3-none-any.whl
COPY
confluent_docker_utils-0.0.44-py3-none-any.whl /tmp/confluent_docker_utils-0.0.44-py3-none-any.whl
COPY
*.whl /tmp/python-dependencies/
COPY
*.whl /tmp/python-dependencies/
COPY
*.gz /tmp/python-dependencies/
COPY
*.gz /tmp/python-dependencies/
RUN
pip3
install
--no-index
--prefix
=
/usr/local
--upgrade
--find-links
/tmp/python-dependencies/ /tmp/confluent_docker_utils-0.0.44-py3-none-any.whl
## copy in the python libs and then
RUN
cd
/usr/local/lib64
&&
tar
-xvf
*
_UsrLocalLib64.tar.gz
&&
rm
*
_UsrLocalLib64.tar.gz
\
&&
cd
/usr/local/lib
&&
tar
-xvf
*
_UsrLocalLib.tar.gz
&&
rm
*
_UsrLocalLib.tar.gz
\
&&
pip3
install
--no-index
--prefix
=
/usr/local
--find-links
/tmp/python-dependencies/ /tmp/confluent_docker_utils-0.0.44-py3-none-any.whl
## dub installed
## dub installed
########################################
########################################
...
@@ -48,7 +60,7 @@ RUN chown appuser:appuser -R /usr/logs
...
@@ -48,7 +60,7 @@ RUN chown appuser:appuser -R /usr/logs
# Copy required RPMs
# Copy required RPMs
COPY
*.rpm /tmp/
COPY
*.rpm /tmp/
COPY
archive.key /tmp/
#
COPY archive.key /tmp/
########################################
########################################
# confluentinc/kafka-images/server
# confluentinc/kafka-images/server
...
@@ -60,15 +72,15 @@ ARG KAFKA_ADVERTISED_LISTENERS
...
@@ -60,15 +72,15 @@ ARG KAFKA_ADVERTISED_LISTENERS
ENV
KAFKA_ADVERTISED_LISTENERS=${KAFKA_ADVERTISED_LISTENERS}
ENV
KAFKA_ADVERTISED_LISTENERS=${KAFKA_ADVERTISED_LISTENERS}
ENV
COMPONENT=kafka
ENV
COMPONENT=kafka
ENV
CONFLUENT_VERSION=6.1.
2
ENV
CONFLUENT_VERSION=6.1.
3
ENV
CUB_CLASSPATH='"/usr/share/java/cp-base-new/*"'
ENV
CUB_CLASSPATH='"/usr/share/java/cp-base-new/*"'
# primary
# primary
EXPOSE
9092
EXPOSE
9092
# Add back in the archive key stuff
RUN
echo
"===> Installing
${
COMPONENT
}
"
\
RUN
echo
"===> Installing
${
COMPONENT
}
"
\
&&
rpm
--import
/tmp/archive.key
\
&&
dnf
install
--nogpgcheck
-y
/tmp/confluent-common-
${
RPM_VERSION
}
.noarch.rpm
\
&&
dnf
install
-y
/tmp/confluent-common-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-rest-utils-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-rest-utils-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-metadata-service-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-metadata-service-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-server-
${
RPM_VERSION
}
.noarch.rpm
\
/tmp/confluent-server-
${
RPM_VERSION
}
.noarch.rpm
\
...
@@ -97,21 +109,21 @@ ENV DOCKER_SCRIPT_DIR=/opt/caas/bin
...
@@ -97,21 +109,21 @@ ENV DOCKER_SCRIPT_DIR=/opt/caas/bin
## Operator stuff
## Operator stuff
RUN
mkdir
-p
/etc/confluent/ironbank
RUN
mkdir
-p
/etc/confluent/ironbank
COPY
cp-server-operator-*_OptCaas.tar.gz /opt/
#
COPY cp-server-operator-*_OptCaas.tar.gz /opt/
COPY
cp-server-operator-*_UsrShareJava.tar.gz /usr/share/
#
COPY cp-server-operator-*_UsrShareJava.tar.gz /usr/share/
COPY
cp-server-operator-*_EtcConfluent.tar.gz /etc/
#
COPY cp-server-operator-*_EtcConfluent.tar.gz /etc/
## For auditing & debugging
## For auditing & debugging
COPY
Dockerfile /etc/confluent/ironbank/
COPY
Dockerfile /etc/confluent/ironbank/
COPY
hardening_manifest.yaml /etc/confluent/ironbank/
COPY
hardening_manifest.yaml /etc/confluent/ironbank/
RUN
echo
"===> Installing operator stuff"
\
#
RUN echo "===> Installing operator stuff" \
&&
cd
/usr/share
&&
tar
-xvf
*
_UsrShareJava.tar.gz
&&
rm
*
_UsrShareJava.tar.gz
\
#
&& cd /usr/share && tar -xvf *_UsrShareJava.tar.gz && rm *_UsrShareJava.tar.gz \
&&
cd
/opt
&&
tar
-xvf
*
_OptCaas.tar.gz
&&
rm
*
_OptCaas.tar.gz
\
#
&& cd /opt && tar -xvf *_OptCaas.tar.gz && rm *_OptCaas.tar.gz \
&&
cd
/etc
&&
tar
-xvf
*
_EtcConfluent.tar.gz
&&
rm
*
_EtcConfluent.tar.gz
\
#
&& cd /etc && tar -xvf *_EtcConfluent.tar.gz && rm *_EtcConfluent.tar.gz \
&&
chown
-R
appuser:appuser /etc/confluent
\
#
&& chown -R appuser:appuser /etc/confluent \
&&
mkdir
-p
"
$KAFKA_DATA_DIR
"
"
${
KAFKA_LOG4J_DIR
}
"
"
${
KAFKA_CONFIG_DIR
}
"
"
${
COMPONENT_SCRIPT_DIR
}
/
${
COMPONENT
}
"
\
#
&& mkdir -p "$KAFKA_DATA_DIR" "${KAFKA_LOG4J_DIR}" "${KAFKA_CONFIG_DIR}" "${COMPONENT_SCRIPT_DIR}/${COMPONENT}" \
&&
chmod
-R
ag+w
"
${
KAFKA_LOG4J_DIR
}
"
"
${
KAFKA_CONFIG_DIR
}
"
"
$KAFKA_DATA_DIR
"
"/opt"
#
&& chmod -R ag+w "${KAFKA_LOG4J_DIR}" "${KAFKA_CONFIG_DIR}" "$KAFKA_DATA_DIR" "/opt"
WORKDIR
/opt
WORKDIR
/opt
CMD
["/opt/caas/bin/run"]
CMD
["/opt/caas/bin/run"]
...
...
hardening_manifest.yaml
View file @
7eb1c3bc
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment