-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile
37 lines (28 loc) · 1.02 KB
/
Dockerfile
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
36
37
# Creates pseudo distributed hadoop 2.4 running giraph
#
# docker build -t uwsampa/giraph .
FROM sequenceiq/hadoop-docker:2.4.1
MAINTAINER uwsampa
USER root
# install software
ADD giraph-setup.sh /etc/giraph-setup.sh
RUN chown root:root /etc/giraph-setup.sh && chmod 700 /etc/giraph-setup.sh && /etc/giraph-setup.sh
# set home variables
ENV HADOOP_HOME $HADOOP_PREFIX
ENV HADOOP_CONF_DIR $HADOOP_PREFIX/etc/hadoop
ENV GIRAPH_HOME /usr/local/giraph
ENV GIRAPH_PREFIX /usr/local/giraph
ENV ZOOKEEPER_HOME /usr/local/zookeeper
ENV ZOOKEEPER_PREFIX /usr/local/zookeeper
# add zookeeper configuration
ADD zoo.cfg $ZOOKEEPER_PREFIX/conf/zoo.cfg
# add sample intput
ADD tiny-graph.txt $GIRAPH_PREFIX/tiny-graph.txt
# our bootstrap file
ADD giraph-bootstrap.sh /etc/giraph-bootstrap.sh
RUN chown root:root /etc/giraph-bootstrap.sh && chmod 700 /etc/giraph-bootstrap.sh
# add our pagerank example
ADD pagerank $GIRAPH_PREFIX/pagerank
ADD exercise_pagerank $GIRAPH_PREFIX/exercise_pagerank
# default command
CMD ["/etc/giraph-bootstrap.sh", "-d"]