Skip to content

Instantly share code, notes, and snippets.

@copperlight
Forked from ourway/bottle_and_gunicorn.py
Last active June 8, 2016 01:12
Show Gist options
  • Select an option

  • Save copperlight/57e2e562f1526d225abb12e59e79af94 to your computer and use it in GitHub Desktop.

Select an option

Save copperlight/57e2e562f1526d225abb12e59e79af94 to your computer and use it in GitHub Desktop.

Revisions

  1. copperlight revised this gist Jun 8, 2016. 2 changed files with 5 additions and 8 deletions.
    10 changes: 5 additions & 5 deletions bottle_and_gunicorn.py
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,10 @@
    from bottle import route, run
    from bottle import Bottle

    @route('/')
    app = Bottle()

    @app.route('/')
    def index():
    '''test me'''
    return '<h1>Hello Bottle!</h1>'


    run(host='localhost', port=8080, server='gunicorn',
    reload=True, workers=4, debug=True)
    app.run(host='localhost', port=8080, server='gunicorn', reload=True, workers=4, debug=True)
    3 changes: 0 additions & 3 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -1,3 +0,0 @@
    virtualenv pyenv
    source pyenv/bin/activate
    pip install gunicorn bottle
  2. @ourway ourway revised this gist Feb 18, 2015. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion bottle_and_gunicorn.py
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,9 @@

    @route('/')
    def index():
    '''test me'''
    return '<h1>Hello Bottle!</h1>'


    run(host='localhost', port=8080, server='gunicorn', workers=4)
    run(host='localhost', port=8080, server='gunicorn',
    reload=True, workers=4, debug=True)
  3. @ourway ourway created this gist Feb 18, 2015.
    8 changes: 8 additions & 0 deletions bottle_and_gunicorn.py
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,8 @@
    from bottle import route, run

    @route('/')
    def index():
    return '<h1>Hello Bottle!</h1>'


    run(host='localhost', port=8080, server='gunicorn', workers=4)
    3 changes: 3 additions & 0 deletions setup.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    virtualenv pyenv
    source pyenv/bin/activate
    pip install gunicorn bottle