This repository has been archived by the owner on Feb 8, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile
44 lines (33 loc) · 1.55 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
38
39
40
41
42
43
44
FROM ubuntu:14.04
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get update && apt-get install -y curl
ADD cloudera.list /etc/apt/sources.list.d/
RUN curl -o archive.key https://archive.cloudera.com/cdh5/ubuntu/trusty/amd64/cdh/archive.key \
&& apt-key add archive.key \
&& apt-key update \
&& apt-get update
RUN apt-get install -y hadoop-hdfs-namenode \
hadoop-hdfs-datanode hive hive-metastore \
impala impala-catalog impala-server \
impala-state-store impala-shell \
kudu-master kudu-tserver \
rsyslog
COPY ./etc /etc/cdh/
COPY ./default/impala /etc/default/impala
RUN echo "Configuring Hadoop, Hive and Impala" \
&& ln -sf /etc/cdh/core-site.xml /etc/hadoop/conf/ \
&& ln -sf /etc/cdh/hdfs-site.xml /etc/hadoop/conf/ \
&& ln -sf /etc/cdh/hive-site.xml /etc/hive/conf/ \
&& ln -sf /etc/cdh/hdfs-site.xml /etc/impala/conf/ \
&& ln -sf /etc/cdh/core-site.xml /etc/impala/conf/ \
&& ln -sf /etc/cdh/hive-site.xml /etc/impala/conf/ \
&& mkdir -p /var/run/hdfs-sockets \
&& chown hdfs:hadoop /var/run/hdfs-sockets \
&& echo "Formatting HDFS..." \
&& service hadoop-hdfs-namenode init \
&& echo "--use_hybrid_clock=false" >> /etc/kudu/conf/master.gflagfile \
&& echo "--use_hybrid_clock=false" >> /etc/kudu/conf/tserver.gflagfile
VOLUME /var/lib/hadoop-hdfs /var/lib/hive /var/lib/impala /var/lib/kudu
EXPOSE 7050 7051 8020 8050 8051 9083 15000 15001 15002 21000 21050 22000 23000 23020 24000 25000 25010 26000 28000 50010 25020 50070 50075
COPY ./docker-entrypoint.sh /usr/local/bin/
ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]