anchor.diff:  #
   # Install git, clone repo, install Python dependencies
   #
  -WORKDIR /root
  -RUN apt-get install -y git
   RUN git clone https://github.com/rjurney/Agile_Data_Code_2
   WORKDIR /root/Agile_Data_Code_2
   ENV PROJECT_HOME=/Agile_Data_Code_2
  -RUN pip install --upgrade pip
  -RUN pip install -r requirements.txt
  -RUN bash /root/Agile_Data_Code_2/download.sh
  +RUN pip install --upgrade pip && \
  +    pip install -r requirements.txt
  +
  +#
  +# Download the data
  +#
  +WORKDIR /root/Agile_Data_Code_2/data
  +
  +# On-time performance records
  +ADD http://s3.amazonaws.com/agile_data_science/On_Time_On_Time_Performance_2015.csv.gz /root/Agile_Data_Code_2/data/On_Time_On_Time_Performance_2015.csv.gz
  +
  +# Openflights data
  +ADD https://raw.githubusercontent.com/jpatokal/openflights/master/data/airports.dat /root/Agile_Data_Code_2/data/airports.dat
  +ADD https://raw.githubusercontent.com/jpatokal/openflights/master/data/airlines.dat /root/Agile_Data_Code_2/data/airlines.dat
  +ADD https://raw.githubusercontent.com/jpatokal/openflights/master/data/routes.dat /root/Agile_Data_Code_2/data/routes.dat
  +ADD https://raw.githubusercontent.com/jpatokal/openflights/master/data/countries.dat /root/Agile_Data_Code_2/data/countries.dat
  +
  +# FAA data
  +ADD http://av-info.faa.gov/data/ACRef/tab/aircraft.txt /root/Agile_Data_Code_2/data/aircraft.txt
  +ADD http://av-info.faa.gov/data/ACRef/tab/ata.txt /root/Agile_Data_Code_2/data/ata.txt
  +ADD http://av-info.faa.gov/data/ACRef/tab/compt.txt /root/Agile_Data_Code_2/data/compt.txt
  +ADD http://av-info.faa.gov/data/ACRef/tab/engine.txt /root/Agile_Data_Code_2/data/engine.txt
  +ADD http://av-info.faa.gov/data/ACRef/tab/prop.txt /root/Agile_Data_Code_2/data/prop.txt
  +
  +# WBAN Master List
  +ADD http://www.ncdc.noaa.gov/homr/file/wbanmasterlist.psv.zip /tmp/wbanmasterlist.psv.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201501.zip /tmp/QCLCD201501.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201502.zip /tmp/QCLCD201502.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201503.zip /tmp/QCLCD201503.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201504.zip /tmp/QCLCD201504.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201505.zip /tmp/QCLCD201505.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201506.zip /tmp/QCLCD201506.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201507.zip /tmp/QCLCD201507.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201508.zip /tmp/QCLCD201508.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201509.zip /tmp/QCLCD201509.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201510.zip /tmp/QCLCD201510.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201511.zip /tmp/QCLCD201511.zip
  +ADD https://www.ncdc.noaa.gov/orders/qclcd/QCLCD201512.zip /tmp/QCLCD201512.zip
  +
  +RUN unzip -o /tmp/wbanmasterlist.psv.zip && \
  +    unzip -o /tmp/QCLCD201501.zip && \
  +    unzip -o /tmp/QCLCD201502.zip && \
  +    unzip -o /tmp/QCLCD201503.zip && \
  +    unzip -o /tmp/QCLCD201504.zip && \
  +    unzip -o /tmp/QCLCD201505.zip && \
  +    unzip -o /tmp/QCLCD201506.zip && \
  +    unzip -o /tmp/QCLCD201507.zip && \
  +    unzip -o /tmp/QCLCD201508.zip && \
  +    unzip -o /tmp/QCLCD201509.zip && \
  +    unzip -o /tmp/QCLCD201510.zip && \
  +    unzip -o /tmp/QCLCD201511.zip && \
  +    unzip -o /tmp/QCLCD201512.zip && \
  +    rm -f /tmp/wbanmasterlist.psv.zip && \
  +    rm -f /tmp/QCLCD201501.zip && \
  +    rm -f /tmp/QCLCD201502.zip && \
  +    rm -f /tmp/QCLCD201503.zip && \
  +    rm -f /tmp/QCLCD201504.zip && \
  +    rm -f /tmp/QCLCD201505.zip && \
  +    rm -f /tmp/QCLCD201506.zip && \
  +    rm -f /tmp/QCLCD201507.zip && \
  +    rm -f /tmp/QCLCD201508.zip && \
  +    rm -f /tmp/QCLCD201509.zip && \
  +    rm -f /tmp/QCLCD201510.zip && \
  +    rm -f /tmp/QCLCD201511.zip && \
  +    rm -f /tmp/QCLCD201512.zip
  +
  +# Back to /root
  +WORKDIR /root
   
   #
   # Install Hadoop: may need to update this link... see http://hadoop.apache.org/releases.html
   #
  -WORKDIR /root
   ADD http://apache.osuosl.org/hadoop/common/hadoop-2.7.3/hadoop-2.7.3.tar.gz /tmp/hadoop-2.7.3.tar.gz
  -RUN mkdir -p /root/hadoop
  -RUN tar -xvf /tmp/hadoop-2.7.3.tar.gz -C hadoop --strip-components=1
  +RUN mkdir -p /root/hadoop && \
  +    tar -xvf /tmp/hadoop-2.7.3.tar.gz -C hadoop --strip-components=1
   ENV HADOOP_HOME=/root/hadoop
   ENV PATH=$PATH:$HADOOP_HOME/bin
   ENV HADOOP_CLASSPATH=/root/hadoop/etc/hadoop/:/root/hadoop/share/hadoop/common/lib/*:/root/hadoop/share/hadoop/common/*:/root/hadoop/share/hadoop/hdfs:/root/hadoop/share/hadoop/hdfs/lib/*:/root/hadoop/share/hadoop/hdfs/*:/root/hadoop/share/hadoop/yarn/lib/*:/root/hadoop/share/hadoop/yarn/*:/root/hadoop/share/hadoop/mapreduce/lib/*:/root/hadoop/share/hadoop/mapreduce/*:/root/hadoop/etc/hadoop:/root/hadoop/share/hadoop/common/lib/*:/root/hadoop/share/hadoop/common/*:/root/hadoop/share/hadoop/hdfs:/root/hadoop/share/hadoop/hdfs/lib/*:/root/hadoop/share/hadoop/hdfs/*:/root/hadoop/share/hadoop/yarn/lib/*:/root/hadoop/share/hadoop/yarn/*:/root/hadoop/share/hadoop/mapreduce/lib/*:/root/hadoop/share/hadoop/mapreduce/*:/root/hadoop/contrib/capacity-scheduler/*.jar:/root/hadoop/contrib/capacity-scheduler/*.jar
  
positive.code: FROM ubuntu
  MAINTAINER Russell Jurney, russell.jurney@gmail.com
  
  # Update apt-get
  RUN apt-get update
  
  # Things we'll need
  RUN apt-get install -y zip unzip curl bzip2 python-dev build-essential
  
  # Setup Oracle Java8
  RUN apt-get install -y software-properties-common debconf-utils
  RUN add-apt-repository -y ppa:webupd8team/java
  RUN apt-get update
  RUN echo "oracle-java8-installer shared/accepted-oracle-license-v1-1 select true" | debconf-set-selections
  RUN apt-get install -y oracle-java8-installer
  ENV JAVA_HOME=/usr/lib/jvm/java-8-oracle
  
  # Download and install Anaconda Python
  WORKDIR /root
  ADD http://repo.continuum.io/archive/Anaconda3-4.2.0-Linux-x86_64.sh /tmp/Anaconda3-4.2.0-Linux-x86_64.sh
  RUN bash /tmp/Anaconda3-4.2.0-Linux-x86_64.sh -b -p /root/anaconda
  ENV PATH="/root/anaconda/bin:$PATH"
  
negative.code: #
  # Install and setup Kafka
  #
  ADD http://www-us.apache.org/dist/kafka/0.10.1.1/kafka_2.11-0.10.1.1.tgz /tmp/kafka_2.11-0.10.1.1.tgz
  RUN mkdir -p /root/kafka && \
      tar -xvzf /tmp/kafka_2.11-0.10.1.1.tgz -C kafka --strip-components=1 && \
      rm -f /tmp/kafka_2.11-0.10.1.1.tgz
  
  # Run zookeeper (which kafka depends on), then Kafka
  RUN /root/kafka/bin/zookeeper-server-start.sh /root/kafka/config/zookeeper.properties && \
      /root/kafka/bin/kafka-server-start.sh /root/kafka/config/server.properties
  
  #
  # Install and set up Airflow
  #
  # Install Apache Incubating Airflow
  RUN pip install airflow && \
      mkdir /root/airflow && \
      mkdir /root/airflow/dags && \
      mkdir /root/airflow/logs && \
      mkdir /root/airflow/plugins && \
      airflow initdb && \
      airflow webserver -D && \
      airflow scheduler -D
  
  #
  # Install and setup Zeppelin
  #
  WORKDIR /root
  ADD http://www-us.apache.org/dist/zeppelin/zeppelin-0.6.2/zeppelin-0.6.2-bin-all.tgz /tmp/zeppelin-0.6.2-bin-all.tgz
  RUN mkdir -p /root/zeppelin && \
      tar -xvzf /tmp/zeppelin-0.6.2-bin-all.tgz -C zeppelin --strip-components=1 && \
      rm -f /tmp/zeppelin-0.6.2-bin-all.tgz
  
  # Configure Zeppelin
  RUN cp /root/zeppelin/conf/zeppelin-env.sh.template /root/zeppelin/conf/zeppelin-env.sh && \
      echo "export SPARK_HOME=/root/spark" >> /root/zeppelin/conf/zeppelin-env.sh && \
      echo "export SPARK_MASTER=local" >> /root/zeppelin/conf/zeppelin-env.sh && \
      echo "export SPARK_CLASSPATH=" >> /root/zeppelin/conf/zeppelin-env.sh
  
  # Cleanup
  RUN rm -rf /var/lib/apt/lists/*
  
  # Done!