mirror of
https://github.com/wassname/catalyst.git
synced 2026-06-30 08:44:01 +08:00
Merge pull request #1310 from quantopian/vagrantf
VagrantFile for Ubuntu 14.04 that includes all the development requirements
This commit is contained in:
+5
-1
@@ -23,4 +23,8 @@
|
||||
#
|
||||
FROM quantopian/zipline
|
||||
|
||||
RUN cd /zipline && pip install -r etc/requirements_dev.txt -r etc/requirements_blaze.txt
|
||||
WORKDIR /zipline
|
||||
|
||||
RUN pip install -r etc/requirements_dev.txt -r etc/requirements_blaze.txt
|
||||
# Clean out any cython assets. The pip install re-builds them.
|
||||
RUN find . -type f -name '*.c' -exec rm {} + && pip install -e .[all]
|
||||
|
||||
Vendored
+1
-2
@@ -2,8 +2,7 @@
|
||||
# vi: set ft=ruby :
|
||||
|
||||
Vagrant.configure("2") do |config|
|
||||
config.vm.box = "precise64"
|
||||
config.vm.box_url = "http://files.vagrantup.com/precise64.box"
|
||||
config.vm.box = "ubuntu/trusty64"
|
||||
config.vm.provider :virtualbox do |vb|
|
||||
vb.customize ["modifyvm", :id, "--memory", 2048, "--cpus", 2]
|
||||
end
|
||||
|
||||
@@ -12,6 +12,9 @@ Enhancements
|
||||
must search for when querying data. The checkpoints should have novel deltas
|
||||
applied (:issue:`1276`).
|
||||
|
||||
- Updated VagrantFile to include all dev requirements and use a newer image
|
||||
(:issue:`1310`).
|
||||
|
||||
Bug Fixes
|
||||
~~~~~~~~~
|
||||
|
||||
|
||||
+27
-24
@@ -10,6 +10,7 @@
|
||||
# from the root of the zipline github checkout.
|
||||
# This will put the zipline code in the
|
||||
# /vagrant folder in the system.
|
||||
set -e
|
||||
|
||||
VAGRANT_LOG="/home/vagrant/vagrant.log"
|
||||
|
||||
@@ -18,33 +19,35 @@ VAGRANT_LOG="/home/vagrant/vagrant.log"
|
||||
# (grub-pc will complain that your boot device changed, probably
|
||||
# due to something that vagrant did, and break your console)
|
||||
|
||||
echo "Obstructing updates to grub-pc..."
|
||||
apt-mark hold grub-pc 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Obstructing updates to grub-pc..." | tee -a "$VAGRANT_LOG"
|
||||
apt-mark hold grub-pc 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
|
||||
# Run a full apt-get update first.
|
||||
echo "Updating apt-get caches..."
|
||||
apt-get -y update 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Adding python apt repo..." | tee -a "$VAGRANT_LOG"
|
||||
apt-add-repository -y ppa:fkrull/deadsnakes-python2.7 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
echo "Updating apt-get caches..." | tee -a "$VAGRANT_LOG"
|
||||
apt-get -y update 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
|
||||
# Install required packages
|
||||
echo "Installing required packages..."
|
||||
apt-get -y install python-pip python-dev g++ make libfreetype6-dev libpng-dev libopenblas-dev liblapack-dev gfortran 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Installing required system packages..." | tee -a "$VAGRANT_LOG"
|
||||
apt-get -y install python2.7 python-dev g++ make libfreetype6-dev libpng-dev libopenblas-dev liblapack-dev gfortran pkg-config git 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
|
||||
# Add ta-lib
|
||||
echo "Installing ta-lib integration..."
|
||||
wget http://switch.dl.sourceforge.net/project/ta-lib/ta-lib/0.4.0/ta-lib-0.4.0-src.tar.gz 2>&1 "$VAGRANT_LOG"
|
||||
tar -xvzf ta-lib-0.4.0-src.tar.gz 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Installing ta-lib..." | tee -a "$VAGRANT_LOG"
|
||||
wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz --no-verbose -a "$VAGRANT_LOG"
|
||||
tar -xvzf ta-lib-0.4.0-src.tar.gz 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
cd ta-lib/
|
||||
./configure --prefix=/usr 2>&1 >> "$VAGRANT_LOG"
|
||||
make 2>&1 >> "$VAGRANT_LOG"
|
||||
sudo make install 2>&1 >> "$VAGRANT_LOG"
|
||||
./configure --prefix=/usr 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
make 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
sudo make install 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
cd ../
|
||||
|
||||
# Add Zipline python dependencies
|
||||
echo "Installing python package dependencies..."
|
||||
/vagrant/etc/ordered_pip.sh /vagrant/etc/requirements.txt 2>&1 >> "$VAGRANT_LOG"
|
||||
# Add scipy next (if it's not done now, breaks installing of statsmodels for some reason ??)
|
||||
echo "Installing scipy..."
|
||||
pip install scipy==0.12.0 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Installing zipline dev python dependencies..."
|
||||
pip install --exists-action w -r /vagrant/etc/requirements_dev.txt 2>&1 >> "$VAGRANT_LOG"
|
||||
echo "Finished!"
|
||||
echo "Installing pip and setuptools..." | tee -a "$VAGRANT_LOG"
|
||||
wget https://bootstrap.pypa.io/get-pip.py 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
python get-pip.py 2>&1 >> "$VAGRANT_LOG" | tee -a "$VAGRANT_LOG"
|
||||
echo "Installing zipline python dependencies..." | tee -a "$VAGRANT_LOG"
|
||||
/vagrant/etc/ordered_pip.sh /vagrant/etc/requirements.txt 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
echo "Installing zipline extra python dependencies..." | tee -a "$VAGRANT_LOG"
|
||||
pip install -r /vagrant/etc/requirements_dev.txt -r /vagrant/etc/requirements_blaze.txt 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
echo "Installing zipline package itself..." | tee -a "$VAGRANT_LOG"
|
||||
# Clean out any cython assets. The pip install re-builds them.
|
||||
find /vagrant/ -type f -name '*.c' -exec rm {} +
|
||||
pip install -e /vagrant[all] 2>&1 | tee -a "$VAGRANT_LOG"
|
||||
echo "Finished! zipline repo is in '/vagrant'." | tee -a "$VAGRANT_LOG"
|
||||
|
||||
Reference in New Issue
Block a user