Deploying Flask Application with pandas to Elastic Beanstalk
<p>I a new to AWS. Trying to deploy a simple flask application to AWS. I had no problem until I included pandas package. </p>

<p>No even with the simplest application I get errors such as "your requirements.txt file is invalid". </p>

<p>My test application is very simple: 
There are only two files in the folder
application.py and requirements.txt. </p>

<h2>Application.py is basic:</h2>

<pre><code>from flask import Flask
from pandas import DataFrame

application = Flask(__name__)

@application.route("/")
def home():
            return "hello pandas "


if __name__ == '__main__':
            application.run()
</code></pre>

<hr>

<p>Requirements file was created with pip freeze
    boto3==1.4.1
    botocore==1.4.60
    click==6.6
    docutils==0.12
    Flask==0.11.1
    itsdangerous==0.24
    Jinja2==2.8
    jmespath==0.9.0
    MarkupSafe==0.23
    numpy==1.11.2
    pandas==0.19.0
    python-dateutil==2.5.3
    pytz==2016.7
    s3transfer==0.1.7
    six==1.10.0</p>

<h2>    Werkzeug==0.11.11</h2>

<p>I have seen posts recommending choosing a bigger instance type than t1.micro that is default. I have done that as follows:</p>

<pre><code> eb create -i m4.large --timeout 100
</code></pre>

<p>but still no luck. </p>

<p>If anyone has deployed flask application that uses pandas to AWS successfully please advise on the best way to do that. 
Thank you.</p>

<p>I have had the same problem deploying a django app to EBS with pandas, and the issue was that there are certain C libraries that need to be installed first. Just add this in your .ebextensions folder:</p>

<pre><code>commands:
  install_devtools:
    command: yum -y groupinstall 'Development tools'
</code></pre>

<p>Heads up, I believe that this will only work on sizes T2 small and above.</p>

python amazon-web-services pandas flask elastic-beanstalk