|
| 1 | +# Licensed to the Apache Software Foundation (ASF) under one |
| 2 | +# or more contributor license agreements. See the NOTICE file |
| 3 | +# distributed with this work for additional information |
| 4 | +# regarding copyright ownership. The ASF licenses this file |
| 5 | +# to you under the Apache License, Version 2.0 (the |
| 6 | +# "License"); you may not use this file except in compliance |
| 7 | +# with the License. You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, |
| 12 | +# software distributed under the License is distributed on an |
| 13 | +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 14 | +# KIND, either express or implied. See the License for the |
| 15 | +# specific language governing permissions and limitations |
| 16 | +# under the License. |
| 17 | + |
| 18 | +FROM openjdk:11.0.6-slim-buster |
| 19 | + |
| 20 | +RUN apt-get update && apt-get -y install \ |
| 21 | + netcat-openbsd \ |
| 22 | + curl \ |
| 23 | + python \ |
| 24 | + python2.7-dev \ |
| 25 | + supervisor \ |
| 26 | + unzip |
| 27 | + |
| 28 | +ADD artifacts /heron |
| 29 | + |
| 30 | +WORKDIR /heron |
| 31 | + |
| 32 | +# run heron installer |
| 33 | +RUN /heron/heron-install.sh && \ |
| 34 | + rm -rf /heron/heron-install.sh && \ |
| 35 | + rm -rf /opt/heron/heron-core/lib/scheduler/heron-local-scheduler.jar && \ |
| 36 | + rm -rf /opt/heron/heron-core/lib/scheduler/heron-mesos-scheduler.jar && \ |
| 37 | + rm -rf /opt/heron/heron-core/lib/scheduler/heron-slurm-scheduler.jar |
| 38 | + |
| 39 | +RUN ln -s /usr/local/heron/dist/heron-core /heron \ |
| 40 | + && mkdir -p /heron/heron-tools \ |
| 41 | + && ln -s /usr/local/heron/bin /heron/heron-tools \ |
| 42 | + && ln -s /usr/local/heron/conf /heron/heron-tools \ |
| 43 | + && ln -s /usr/local/heron/dist /heron/heron-tools \ |
| 44 | + && ln -s /usr/local/heron/lib /heron/heron-tools \ |
| 45 | + && ln -s /usr/local/heron/release.yaml /heron/heron-tools \ |
| 46 | + && ln -s /usr/local/heron/examples /heron \ |
| 47 | + && ln -s /usr/local/heron/release.yaml /heron |
| 48 | + |
| 49 | +ENV HERON_HOME /heron/heron-core/ |
| 50 | +RUN export HERON_HOME |
| 51 | + |
| 52 | +# install zookeeper |
| 53 | +ARG ZK_DIST=zookeeper-3.4.14 |
| 54 | +ADD dist/scripts /opt/heron-docker/scripts |
| 55 | + |
| 56 | +RUN sh /opt/heron-docker/scripts/install-zookeeper.sh $ZK_DIST |
| 57 | + |
| 58 | +ADD dist/conf/zookeeper.conf /opt/zookeeper/conf/zookeeper.conf |
| 59 | +ADD dist/conf/sandbox.conf /etc/supervisor/conf.d/ |
0 commit comments