-
Notifications
You must be signed in to change notification settings - Fork 21
PR for all MapR docker containers #21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from 1 commit
bf36aea
a95013c
bdc12e6
be1582f
3c9fe45
f5602e0
e35f692
3004ec0
702f0af
c2ddb51
e2852a7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,69 @@ | ||
| # Copyright 2017 Teradata | ||
| # | ||
| # Licensed under the Apache License, Version 2.0 (the "License"); | ||
| # you may not use this file except in compliance with the License. | ||
| # You may obtain a copy of the License at | ||
| # | ||
| # http://www.apache.org/licenses/LICENSE-2.0 | ||
| # | ||
| # Unless required by applicable law or agreed to in writing, software | ||
| # distributed under the License is distributed on an "AS IS" BASIS, | ||
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| # See the License for the specific language governing permissions and | ||
| # limitations under the License. | ||
|
|
||
| FROM teradatalabs/centos6-java8-oracle | ||
| MAINTAINER Teradata Docker Team <docker@teradata.com> | ||
|
|
||
| # ADD REPO FOR MAPR | ||
| ADD files/maprtech.repo /etc/yum.repos.d/maprtech.repo | ||
| COPY files/id_rsa.pub /root/ | ||
| RUN yum update -y \ | ||
| # ... GET MapRGPG KEY | ||
| && rpm --import http://package.mapr.com/releases/pub/maprgpg.key \ | ||
|
|
||
| # INSTALL UTILITY SOFTWARE | ||
| && yum install -y iputils vim openssh-server openssh-clients sudo lsof \ | ||
|
||
| # CONFIGURE SSH | ||
| && chkconfig sshd on \ | ||
| && grep -rl '#Port 22' /etc/ssh/sshd_config | xargs sed -i 's/#Port 22/Port 22/g' \ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why is that needed? The other containers expose sshd as well and they don't seem to be sed-ing the 22 Port in config anywhere AFAIR?
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Its not working without that , other containers will all have same problems when some one will ssh hadoop-master from outside. |
||
|
|
||
| # INSTALL MAPR | ||
| && yum install -y mapr-fileserver mapr-nfs mapr-nodemanager mapr-cldb \ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. squash into a single yum install invocation |
||
| && yum install -y mapr-zookeeper mapr-resourcemanager mapr-historyserver \ | ||
| && yum install -y mapr-webserver mapr-gateway mapr-httpfs \ | ||
|
|
||
| # ADD USERS AND CHANGE OWNERSHIPS | ||
| && adduser mapr \ | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. extract a function 'setup_user' that adds and configures a single user, then call 3 times for the users
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @ArturGajowy do you want the function to be created inside docker file or seperate shell script which will be called from docker file |
||
| && adduser hive \ | ||
| && adduser hdfs \ | ||
| && touch /home/mapr /home/hive /home/hdfs \ | ||
| && echo "cd /home/mapr" >> /home/mapr/.bashrc \ | ||
| && echo "cd /home/hive" >> /home/hive/.bashrc \ | ||
| && echo "cd /home/hdfs" >> /home/hdfs/.bashrc \ | ||
| && chown -R mapr:mapr /home/mapr /opt/mapr/httpfs \ | ||
| && chown hive:hive /home/hive \ | ||
| && chown hdfs:hdfs /home/hdfs \ | ||
| # CONFIGURE ZOOKEEPER'S DATA DIRECTORY | ||
| && rm -rf /opt/mapr/zkdata \ | ||
| && mkdir /opt/mapr/zkdata \ | ||
| && chmod 777 /opt/mapr/zkdata \ | ||
| && mkdir -p /mapr \ | ||
|
|
||
| # INSTALL PYTHON AND SUPERVISORD | ||
| && yum install -y python-setuptools \ | ||
| && easy_install pip \ | ||
| && pip install supervisor \ | ||
| && mkdir /etc/supervisord.d/ \ | ||
| # ... AND ITS MISSING DEPENDENCY | ||
| && wget http://dl.fedoraproject.org/pub/epel/6/x86_64/python-meld3-0.6.7-1.el6.x86_64.rpm \ | ||
| && rpm -ihv python-meld3-0.6.7-1.el6.x86_64.rpm \ | ||
| && rm python-meld3-0.6.7-1.el6.x86_64.rpm \ | ||
|
|
||
| # CLEANUP | ||
| && yum -y clean all && rm -rf /tmp/* /var/tmp/* \ | ||
|
|
||
| # GENERATE SSH KEYS | ||
| && ssh-keygen -t rsa -b 4096 -C "automation@teradata.com" -N "" -f /root/.ssh/id_rsa \ | ||
| && cp /root/.ssh/id_rsa.pub /root/.ssh/authorized_keys \ | ||
| && cat /root/id_rsa.pub | cat >> ~/.ssh/authorized_keys | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| # mapr52-base | ||
|
||
|
|
||
|
|
||
| Docker image with all MapR related softwares installed and there dependencies. | ||
|
||
|
|
||
| ## Oracle license | ||
|
|
||
| By using this image, you accept the Oracle Binary Code License Agreement for Java SE available here: | ||
| [http://www.oracle.com/technetwork/java/javase/terms/license/index.html](http://www.oracle.com/technetwork/java/javase/terms/license/index.html) | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA1PL4EwRZFy1ewBTa4a1TK+mQ4rAupOeZsiqir/su61dAGvC6pEFAa+Litj6ub6NvcBRMAdXeBtbOnQpInE7BFwKVhwU3n60Mc69SjLiozK3Oxh9sfmbJv/JdELRS5aB9x82Y0bO5fZFPFj7SxPNMugQQMEMQHW01wsa5nJR2pYLwCtu7yoD6fQ0TJEsRqWwyQTNoR19yzL6h7p/hq9SqiqCKfsHWK4+Tj0IgF7Nwz8i+BqqOq2kC9lTRuT8HalNbqVVQ6iI+ER7FgdfSZtKKX6R9SOaKQ7p0Dt6JLFibMNhjwt5EKHsgfMOsl1G8SEncDREtTng8/JLlvIhiqmWzwQ== root@d57cdb1934d1 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| [maprtech] | ||
| name=MapR Technologies | ||
| baseurl=http://package.mapr.com/releases/v5.2.0/redhat/ | ||
| enabled=1 | ||
| gpgcheck=0 | ||
| protect=1 | ||
|
|
||
| [maprecosystem] | ||
| name=MapR Technologies | ||
| baseurl=http://package.mapr.com/releases/MEP/MEP-1.0/redhat | ||
| enabled=1 | ||
| gpgcheck=0 | ||
| protect=1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing space