Dockerfile 941 B

12345678910111213141516171819
  1. # The development Docker image build a self-contained Ray instance suitable
  2. # for developers that need the source code to actively modify.
  3. FROM rayproject/ray-deps:latest
  4. ADD ray.tar /ray
  5. ADD git-rev /ray/git-rev
  6. # Install dependencies needed to build ray
  7. RUN sudo apt-get update && sudo apt-get install -y curl unzip cmake gcc g++ && sudo apt-get clean
  8. RUN sudo chown -R ray:users /ray && cd /ray && git init && ./ci/travis/install-bazel.sh --system
  9. ENV PATH=$PATH:/home/ray/bin
  10. RUN echo 'build --remote_cache="https://storage.googleapis.com/ray-bazel-cache"' >> $HOME/.bazelrc
  11. RUN echo 'build --remote_upload_local_results=false' >> $HOME/.bazelrc
  12. WORKDIR /ray/
  13. # The result of bazel build is reused in pip install. It if run first to allow
  14. # for failover to serial build if parallel build requires too much resources.
  15. RUN bazel build //:ray_pkg || bazel build --jobs 1 //:ray_pkg
  16. WORKDIR /ray/python/
  17. RUN pip install -e .
  18. WORKDIR /ray