From 3abffe85fdde759dde298291e9fa9ea3516e0cc1 Mon Sep 17 00:00:00 2001 From: Semicolon Date: Mon, 11 Dec 2017 07:51:23 -0500 Subject: [PATCH 1/3] Made it work Fixed error conda not found. Removed conda-requirements.txt. Also, activated the env. --- bin/steps/conda_compile | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/bin/steps/conda_compile b/bin/steps/conda_compile index 6b7d452..994af56 100755 --- a/bin/steps/conda_compile +++ b/bin/steps/conda_compile @@ -1,18 +1,10 @@ -#!/usr/bin/env bash -CONDA_VERSION=3.8.3 if [ ! -d /app/.heroku/miniconda ]; then - puts-step "Preparing Python/Miniconda Environment (${CONDA_VERSION})" - curl -Os http://repo.continuum.io/miniconda/Miniconda-${CONDA_VERSION}-Linux-x86_64.sh - bash Miniconda-${CONDA_VERSION}-Linux-x86_64.sh -p /app/.heroku/miniconda/ -b | indent - rm -fr Miniconda-${CONDA_VERSION}-Linux-x86_64.sh + puts-step "Preparing Python/Miniconda Environment" + curl -Os https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh + bash Miniconda-latest-Linux-x86_64.sh -p /app/.heroku/miniconda/ -b | indent + rm -fr Miniconda-latest-Linux-x86_64.sh - conda update conda --quiet --yes | indent -fi - - -if [ -f conda-requirements.txt ]; then - puts-step "Installing dependencies using Conda" - conda install --file conda-requirements.txt --yes + conda install pip --yes | indent fi if [ -f environment.yml ]; then @@ -22,6 +14,9 @@ if [ -f environment.yml ]; then conda env create --name=heroku-env --file environment.yml fi +source activate heroku-env + + # Clean up the installation environment . # TODO Determine if removing packages might be bad here conda clean -pt --yes > /dev/null From 7ba77886d3b8f16fc036602cf2bcd458b421a320 Mon Sep 17 00:00:00 2001 From: Semicolon Date: Mon, 11 Dec 2017 08:15:51 -0500 Subject: [PATCH 2/3] Much better --- bin/steps/conda_compile | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/bin/steps/conda_compile b/bin/steps/conda_compile index 994af56..dc25ad5 100755 --- a/bin/steps/conda_compile +++ b/bin/steps/conda_compile @@ -1,19 +1,13 @@ if [ ! -d /app/.heroku/miniconda ]; then puts-step "Preparing Python/Miniconda Environment" - curl -Os https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh + wget -Os https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh bash Miniconda-latest-Linux-x86_64.sh -p /app/.heroku/miniconda/ -b | indent rm -fr Miniconda-latest-Linux-x86_64.sh - - conda install pip --yes | indent -fi - -if [ -f environment.yml ]; then - puts-step "Creating conda environment" - # TODO: Use update if its already there - conda env remove --yes --quiet --name heroku-env - conda env create --name=heroku-env --file environment.yml fi +puts-step "Creating conda environment" +# TODO: Use update if its already there +conda env create -f environment.yml source activate heroku-env From 2acd421bd6e872630e4c83d42678bda7d6e2895b Mon Sep 17 00:00:00 2001 From: Semicolon Date: Mon, 11 Dec 2017 08:23:34 -0500 Subject: [PATCH 3/3] I have no idea --- bin/steps/conda_compile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/bin/steps/conda_compile b/bin/steps/conda_compile index dc25ad5..86f2867 100755 --- a/bin/steps/conda_compile +++ b/bin/steps/conda_compile @@ -1,8 +1,6 @@ if [ ! -d /app/.heroku/miniconda ]; then puts-step "Preparing Python/Miniconda Environment" - wget -Os https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh - bash Miniconda-latest-Linux-x86_64.sh -p /app/.heroku/miniconda/ -b | indent - rm -fr Miniconda-latest-Linux-x86_64.sh + bash <(curl -s https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh) -p /app/.heroku/miniconda/ -b | indent fi puts-step "Creating conda environment"