-
Notifications
You must be signed in to change notification settings - Fork 4
/
Dockerfile_base
35 lines (26 loc) · 1.17 KB
/
Dockerfile_base
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
FROM registry.redhat.io/ubi8/ubi
# Based on https://catalog.redhat.com/software/containers/ubi8/python-38/5dde9cacbed8bd164a0af24a
# Use this dockerfile to create a base container that has ocs-ci
# installed.
# Configure k8s repository to install kubectl packages.
COPY k8s.repo /etc/yum.repos.d/k8s.repo
# Python package installation.
RUN INSTALL_PKGS="python38 python38-devel python38-setuptools python38-pip \
libffi-devel libcurl-devel openssl-devel libxslt-devel libxml2-devel libtool-ltdl enchant glibc-langpack-en redhat-rpm-config \
git gcc kubectl" && \
yum -y module enable python38:3.8 && \
yum -y --setopt=tsflags=nodocs install $INSTALL_PKGS && \
rpm -V $INSTALL_PKGS && \
yum -y clean all --enablerepo='*' && \
rm -rf /var/cache/yum
# Environment variables containing various file locations required by
# scripts.
ENV OCSCI_INSTALL_DIR=/opt/ocs-ci \
CLUSTER_DIR=/opt/cluster
# Copy installation and test scripts inside the container.
COPY bin/install-ocs-ci.sh /usr/local/bin/
RUN chmod 755 /usr/local/bin/*.sh
# Install ocs-ci inside the container.
RUN install-ocs-ci.sh
CMD [ "/bin/echo", "ocsci base container" ]
# vim: ft=dockerfile