How to deploy Flask application in google app engine with core python packages?
<p>I want to deploy below python structure in google app engine I want to know how to configure .yaml files for below flask application with core python packages and please suggest a better way to deploy code in google app engine.(I want to deploy all the packages in one location/directory)</p>

<p>Packages:</p>

<pre><code> Model-Engine
    - api
            - api
                - __int__.py
                - view.py
                - utils.py
                - models.py
            - tests
            - runserver.py
            - setup.py
   - driver
        - driver
            - core
                - __init__.py
                - celery.py
                - celery_tasks.py
            - tests
            - setup.py


 Physics
            - core
                     - core
                        - __init__.py
                            - base.py
                            - pipe_line_simulation.py
                    -tests
            - setup.py


 Gas-model
            - src
                - model
                        - __init__.py
                        - gas_model.py
                - converter
                        - __init__.py
                        - hdf5_to_csv.py
            - setup.py
</code></pre>

<h1>My suggestion.</h1>

<p>1.Create application in Google admin console <a href="https://console.cloud.google.com/appengine?src=ac" rel="nofollow">google admin console</a></p>

<ol start="2">
<li>Put app.yaml inside your project root directory </li>
</ol>

<p>sample code:</p>

<pre><code>application: "Application name from google app engine"
version: 1 
runtime: python27
api_version: 1
threadsafe: yes

handlers:
- url: /
  script: home.app

- url: /index\.html
  script: home.app

- url: /stylesheets
  static_dir: stylesheets

- url: /(.*\.(gif|png|jpg))$
  static_files: static/\1
  upload: static/.*\.(gif|png|jpg)$

- url: /admin/.*
  script: admin.app
  login: admin 
</code></pre>

<ol start="3">
<li><p>Make folder (<code>lib</code>) inside the root directory put all the dependencies inside the folder</p></li>
<li><p>Create a file <code>appengine_config.py</code> inside the project directory and put the below codes.</p></li>
</ol>

<p><code>from google.appengine.ext import vendor</code></p>

<p><code>vendor.add('lib')</code></p>

<ol start="5">
<li><p>Run the app localy using this command - dev_appserver.py .</p></li>
<li><p>Deploy the application.</p>

<p><code>appcfg.py update -A {your-project-id} -V v1</code> .</p></li>
</ol>

<p>If this isn't your first deployment, you will need to set the new version as the default version with</p>

<pre><code>appcfg.py set_default_version -V v1 -A {your-project-id}
</code></pre>

<p>Congratulations! Your application is now live at your-app-id.appspot.com</p>

python google-app-engine flask