All Projects → GoogleCloudPlatform → appengine-bottle-skeleton

GoogleCloudPlatform / appengine-bottle-skeleton

Licence: Apache-2.0 license
A skeleton app that illustrates how to run the Bottle micro-framework with App Engine

Programming Languages

python
139335 projects - #7 most used programming language

Python Bottle Framework Scaffold for Google App Engine

A skeleton for building Python applications on Google App Engine with the Bottle micro framework version 0.11.6

See our other Google Cloud Platform github repos for other sample applications.

Run Locally

  1. Install the App Engine Python SDK. See the README file for directions. You'll need python 2.7 and pip 1.4 or later installed too.

  2. Clone this repository with

    git clone https://github.com/GoogleCloudPlatform/appengine-python-bottle-skeleton.git
    
  3. Install dependencies in the project's lib/ directory. Note: App Engine can only import libraries from inside your project directory.

    cd appengine-python-bottle-skeleton
    pip install -r requirements.txt -t lib/
    
  4. Run this project locally from the command line:

    dev_appserver.py .
    

Open http://localhost:8080

See the development server documentation for options when running dev_appserver.

Deploy

To deploy the application:

  1. Use the Admin Console to create an app and get the project/app id. (App id and project id are identical)
  2. Deploy the application with
gcloud app deploy
  1. Congratulations! Your application is now live at your-project-id.appspot.com

Next Steps

This skeleton includes TODO markers you can search for to determine some of the basic areas you will want to customize.

Relational Databases and Datastore

To add persistence to your models, use NDB for scale. Consider CloudSQL if you need a relational database.

Installing Libraries

See the Third party libraries page for libraries that are already included in the SDK. To include SDK libraries, add them in your app.yaml file. All other libraries must be included in your project directory in order to be used by App Engine. Only pure python libraries may be added to an App Engine project.

Feedback

Star this repo if you found it useful. Use the github issue tracker to give feedback on this repo and to ask for skeletons for other frameworks or use cases.

Contributing changes

See CONTRIB.md

Licensing

See LICENSE

Authors

Logan Henriquez and Johan Euphrosine

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].