Created
June 29, 2018 22:57
-
-
Save j-griffith/acb3730c8f94c59d5feefeec5bac30da to your computer and use it in GitHub Desktop.
Dockerfile
This file contains hidden or 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
# Based on centos | |
FROM centos:7.4.1708 | |
LABEL maintainers="Gorka Eguileor <[email protected]>" | |
LABEL description="Cinderlib CSI Plugin" | |
RUN yum update -y && yum install -y epel-release \ | |
https://repos.fedorapeople.org/repos/openstack/openstack-pike/rdo-release-pike-1.noarch.rpm | |
RUN yum update -y && yum install -y targetcli \ | |
iscsi-initiator-utils \ | |
device-mapper-multipath \ | |
centos-release-openstack-pike \ | |
openstack-cinder \ | |
python-rbd \ | |
ceph-common \ | |
xfsprogs \ | |
e2fsprogs \ | |
btrfs-progs \ | |
lvm2 \ | |
python-pip \ | |
&& rm -rf /etc/yum.repos.d/* | |
RUN pip install --no-cache-dir --process-dependency-links cinderlib-csi 'krest>=1.3.0' | |
RUN sed -i -e 's/udev_sync = 1/udev_sync = 0/g' /etc/lvm/lvm.conf \ | |
&& sed -i -e 's/udev_rules = 1/udev_rules = 0/g' /etc/lvm/lvm.conf \ | |
&& sed -i -e 's/use_lvmetad = 0/use_lvmetad = 1/g' /etc/lvm/lvm.conf | |
# This is the default port, but if we change it via CSI_ENDPOINT then this will | |
# no longer be relevant. | |
EXPOSE 50051 | |
# Define default command | |
CMD ["/usr/sbin/tgtd; cinderlib-csi"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
docker build -t my-cinderlib-csi
https://gist.githubusercontent.com/j-griffith/acb3730c8f94c59d5feefeec5bac30da/raw/cdd5ce5488d5e9b5a4ebae878a86d8aabbd24428/cinderlib-csi-from-src