Skip to content

Commit

Permalink
Merge branch '1.1.0-hadoop2.7.1-java8'
Browse files Browse the repository at this point in the history
  • Loading branch information
ivan authored and ivan committed Jan 24, 2017
2 parents a7161d6 + 67cc3cd commit 9694ca9
Show file tree
Hide file tree
Showing 9 changed files with 197 additions and 79 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# Changes

Version 1.1.0 introduces healthchecks for the containers.

# Hadoop Docker

## Supported Hadoop Versions
Expand Down
8 changes: 5 additions & 3 deletions base/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
FROM debian:7
FROM debian:8
MAINTAINER Ivan Ermilov <[email protected]>

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends openjdk-7-jdk
ENV JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64/
RUN echo "deb http://ftp.debian.org/debian jessie-backports main" >> /etc/apt/sources.list

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends openjdk-8-jdk
ENV JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64/

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends net-tools curl

Expand Down
4 changes: 3 additions & 1 deletion datanode/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM bde2020/hadoop-base:1.0.0
FROM bde2020/hadoop-base:1.1.0-hadoop2.7.1-java8
MAINTAINER Ivan Ermilov <[email protected]>

HEALTHCHECK CMD curl -f http://localhost:50075/ || exit 1

ENV HDFS_CONF_dfs_datanode_data_dir=file:///hadoop/dfs/data
RUN mkdir -p /hadoop/dfs/data
VOLUME /hadoop/dfs/data
Expand Down
95 changes: 95 additions & 0 deletions docker-compose-local.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
version: "2"

services:
namenode:
build: ./namenode
hostname: namenode
container_name: namenode
volumes:
- ./data/namenode:/hadoop/dfs/name
environment:
- CLUSTER_NAME=test
env_file:
- ./hadoop.env

resourcemanager:
build: ./resourcemanager
hostname: resourcemanager
container_name: resourcemanager
depends_on:
- "namenode"
links:
- "namenode"
ports:
- "58088:8088"
env_file:
- ./hadoop.env

historyserver:
build: ./historyserver
hostname: historyserver
container_name: historyserver
volumes:
- ./data/historyserver:/hadoop/yarn/timeline
depends_on:
- "namenode"
links:
- "namenode"
ports:
- "58188:8188"
env_file:
- ./hadoop.env

nodemanager1:
build: ./nodemanager
hostname: nodemanager1
container_name: nodemanager1
depends_on:
- "namenode"
- "resourcemanager"
links:
- "namenode"
- "resourcemanager"
ports:
- "58042:8042"
env_file:
- ./hadoop.env

datanode1:
build: ./datanode
hostname: datanode1
container_name: datanode1
depends_on:
- "namenode"
links:
- "namenode"
volumes:
- ./data/datanode1:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode2:
build: ./datanode
hostname: datanode2
container_name: datanode2
depends_on:
- "namenode"
links:
- "namenode"
volumes:
- ./data/datanode2:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode3:
build: ./datanode
hostname: datanode3
container_name: datanode3
depends_on:
- "namenode"
links:
- "namenode"
volumes:
- ./data/datanode3:/hadoop/dfs/data
env_file:
- ./hadoop.env
151 changes: 79 additions & 72 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,74 +1,81 @@
namenode:
image: bde2020/hadoop-namenode:1.0.0
hostname: namenode
container_name: namenode
domainname: hadoop
net: hadoop
volumes:
- ./data/namenode:/hadoop/dfs/name
environment:
- CLUSTER_NAME=test
env_file:
- ./hadoop.env
version: "2"

resourcemanager:
image: bde2020/hadoop-resourcemanager:1.0.0
hostname: resourcemanager
container_name: resourcemanager
domainname: hadoop
net: hadoop
env_file:
- ./hadoop.env
services:
namenode:
image: bde2020/hadoop-namenode:1.1.0-hadoop2.7.1-java8
container_name: namenode
volumes:
- hadoop_namenode:/hadoop/dfs/name
environment:
- CLUSTER_NAME=test
env_file:
- ./hadoop.env

resourcemanager:
image: bde2020/hadoop-resourcemanager:1.1.0-hadoop2.7.1-java8
container_name: resourcemanager
depends_on:
- namenode
- datanode1
- datanode2
env_file:
- ./hadoop.env

historyserver:
image: bde2020/hadoop-historyserver:1.1.0-hadoop2.7.1-java8
container_name: historyserver
depends_on:
- namenode
- datanode1
- datanode2
volumes:
- hadoop_historyserver:/hadoop/yarn/timeline
env_file:
- ./hadoop.env

nodemanager1:
image: bde2020/hadoop-nodemanager:1.1.0-hadoop2.7.1-java8
container_name: nodemanager1
depends_on:
- namenode
- datanode1
- datanode2
env_file:
- ./hadoop.env

datanode1:
image: bde2020/hadoop-datanode:1.1.0-hadoop2.7.1-java8
container_name: datanode1
depends_on:
- namenode
volumes:
- hadoop_datanode1:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode2:
image: bde2020/hadoop-datanode:1.1.0-hadoop2.7.1-java8
container_name: datanode2
depends_on:
- namenode
volumes:
- hadoop_datanode2:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode3:
image: bde2020/hadoop-datanode:1.1.0-hadoop2.7.1-java8
container_name: datanode3
depends_on:
- namenode
volumes:
- hadoop_datanode3:/hadoop/dfs/data
env_file:
- ./hadoop.env

historyserver:
image: bde2020/hadoop-historyserver:1.0.0
hostname: historyserver
container_name: historyserver
domainname: hadoop
net: hadoop
volumes:
- ./data/historyserver:/hadoop/yarn/timeline
env_file:
- ./hadoop.env

nodemanager1:
image: bde2020/hadoop-nodemanager:1.0.0
hostname: nodemanager1
container_name: nodemanager1
domainname: hadoop
net: hadoop
env_file:
- ./hadoop.env

datanode1:
image: bde2020/hadoop-datanode:1.0.0
hostname: datanode1
container_name: datanode1
domainname: hadoop
net: hadoop
volumes:
- ./data/datanode1:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode2:
image: bde2020/hadoop-datanode:1.0.0
hostname: datanode2
container_name: datanode2
domainname: hadoop
net: hadoop
volumes:
- ./data/datanode2:/hadoop/dfs/data
env_file:
- ./hadoop.env

datanode3:
image: bde2020/hadoop-datanode:1.0.0
hostname: datanode3
container_name: datanode3
domainname: hadoop
net: hadoop
volumes:
- ./data/datanode3:/hadoop/dfs/data
env_file:
- ./hadoop.env
volumes:
hadoop_namenode:
hadoop_datanode1:
hadoop_datanode2:
hadoop_datanode3:
hadoop_historyserver:
2 changes: 2 additions & 0 deletions historyserver/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM bde2020/hadoop-base:1.0.0
MAINTAINER Ivan Ermilov <[email protected]>

HEALTHCHECK CMD curl -f http://localhost:8188/ || exit 1

ENV YARN_CONF_yarn_timeline___service_leveldb___timeline___store_path=/hadoop/yarn/timeline
RUN mkdir -p /hadoop/yarn/timeline
VOLUME /hadoop/yarn/timeline
Expand Down
4 changes: 3 additions & 1 deletion namenode/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM bde2020/hadoop-base:1.0.0
FROM bde2020/hadoop-base:1.1.0-hadoop2.7.1-java8
MAINTAINER Ivan Ermilov <[email protected]>

HEALTHCHECK CMD curl -f http://localhost:50070/ || exit 1

ENV HDFS_CONF_dfs_namenode_name_dir=file:///hadoop/dfs/name
RUN mkdir -p /hadoop/dfs/name
VOLUME /hadoop/dfs/name
Expand Down
4 changes: 3 additions & 1 deletion nodemanager/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM bde2020/hadoop-base:1.0.0
FROM bde2020/hadoop-base:1.1.0-hadoop2.7.1-java8
MAINTAINER Ivan Ermilov <[email protected]>

HEALTHCHECK CMD curl -f http://localhost:8042/ || exit 1

ADD run.sh /run.sh
RUN chmod a+x /run.sh

Expand Down
4 changes: 3 additions & 1 deletion resourcemanager/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
FROM bde2020/hadoop-base:1.0.0
FROM bde2020/hadoop-base:1.1.0-hadoop2.7.1-java8
MAINTAINER Ivan Ermilov <[email protected]>

HEALTHCHECK CMD curl -f http://localhost:8088/ || exit 1

ADD run.sh /run.sh
RUN chmod a+x /run.sh

Expand Down

0 comments on commit 9694ca9

Please sign in to comment.