cyberark/cyberark-conjur-cli

View on GitHub
Dockerfile.test.rhel8

Summary

Maintainability
Test Coverage
FROM registry.access.redhat.com/ubi8/ubi:8.8
 
ENV INSTALL_DIR=/opt/cyberark-conjur-cli
 
RUN yum --disableplugin=subscription-manager -y \
install -y bash \
binutils \
yum-utils \
gcc gcc-c++ make \
git \
jq \
libffi-devel \
openssl-devel \
python3-devel \
procps \
zlib-devel \
&& yum --disableplugin=subscription-manager clean all
 
# Copy public keys for repo GPG check
RUN curl -L https://www.centos.org/keys/RPM-GPG-KEY-CentOS-Official > /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS
 
# Import gpg key
RUN gpg --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS
 
# Copy below repo file to enable installation of gnome-keyring and dbus-x11
COPY ./test/CentOS-Linux-AppStream.repo \
/etc/yum.repos.d/
RUN yum --disableplugin=subscription-manager -y \
install -y dbus-x11 \
gnome-keyring \
&& yum --disableplugin=subscription-manager clean all
 
RUN mkdir -p $INSTALL_DIR
WORKDIR $INSTALL_DIR
 
# Generate unique machne-id file required by dbus-11
RUN dbus-uuidgen > /var/lib/dbus/machine-id
 
# Install Python 3.11 using pyenv, wheel and required libs
ENV PYENV_ROOT="/root/.pyenv"
ENV PATH="$PYENV_ROOT/bin:$PYENV_ROOT/shims:$PATH"
 
COPY ./requirements.txt $INSTALL_DIR/
RUN curl -L -s https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash \
&& eval "$(pyenv init --path)" \
&& env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.11 \
&& pyenv global 3.11 \
&& pip install wheel \
&& pip install -r requirements.txt
 
COPY ./bin/build_integrations_tests_runner ./test/configure_test_executor.sh /
COPY . $INSTALL_DIR
 
ENTRYPOINT ["./test/configure_test_executor.sh"]