Skip to content

Instantly share code, notes, and snippets.

@kazuhisya
Last active February 27, 2017 12:06
Show Gist options
  • Save kazuhisya/e36d36f12b2f5bacb14e23e60f2c78e2 to your computer and use it in GitHub Desktop.
Save kazuhisya/e36d36f12b2f5bacb14e23e60f2c78e2 to your computer and use it in GitHub Desktop.
# vi: set ft=dockerfile :
FROM centos:6
RUN yum install -y epel-release && \
yum groupinstall -y "Base" "Development Tools" && \
yum install -y --nogpgcheck http://ymu.dl.osdn.jp/linux-ha/66141/pacemaker-repo-1.1.14-1.1.el6.x86_64.rpm && \
yum install -y corosync corosynclib corosynclib-devel && \
yum install -y userspace-rcu userspace-rcu-devel yasm yasm-devel && \
yum install -y fuse fuse-devel && \
yum install -y rpm-build rpmdevtools rpmlint && \
curl -L -o /etc/yum.repos.d/bigtop.repo http://www.apache.org/dist/bigtop/bigtop-1.1.0/repos/centos6/bigtop.repo && \
yum install -y --nogpgcheck zookeeper-native && \
yum clean all
COPY ./sheepdog /root/sheepdog
WORKDIR /root/sheepdog
RUN git submodule update --init ./tests/unit/unity && \
git submodule update --init ./tests/unit/cmock
RUN ./autogen.sh && \
./configure --enable-zookeeper --enable-sheepfs && \
LANG=C make -j8 rpm
# vi: set ft=dockerfile :
FROM centos:7
RUN yum install -y epel-release && \
yum groupinstall -y "Base" "Development Tools" && \
yum install -y corosync corosynclib corosynclib-devel && \
yum install -y userspace-rcu userspace-rcu-devel yasm yasm-devel && \
yum install -y fuse fuse-devel && \
yum install -y rpm-build rpmdevtools rpmlint && \
curl -L -o /etc/yum.repos.d/bigtop.repo http://www.apache.org/dist/bigtop/bigtop-1.1.0/repos/centos7/bigtop.repo && \
yum install -y --nogpgcheck zookeeper-native && \
yum clean all
RUN git clone --depth=1 -b v1.0.2_rc0 https://github.com/sheepdog/sheepdog /root/sheepdog
WORKDIR /root/sheepdog
RUN git submodule update --init ./tests/unit/unity && \
git submodule update --init ./tests/unit/cmock
ADD https://github.com/kazuhisya/sheepdog/commit/1082eb6.diff ./
ADD https://github.com/kazuhisya/sheepdog/commit/15bd7e4.diff ./
ADD https://github.com/kazuhisya/sheepdog/commit/3579b74.diff ./
RUN patch -u < 1082eb6.diff && \
patch -u < 15bd7e4.diff && \
patch -u < 3579b74.diff
RUN ./autogen.sh && \
./configure --enable-zookeeper --enable-sheepfs && \
LANG=C make -j8 rpm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment