Skip to content

stg7/bottle_docker_kit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

docker-compose kit for python3 web apps with bottle

This docker-compose file is mainly based on the guide:

Both parts, the docker-compose.yml and app/main.py can be seen as a first starting point to develop a python3 web application.

start

run

docker build -t bottleserver .

just run

docker-compose up -d web

and now your web-server is running at http://localhost:8080

Default settings are performing python autoload, if the main.py is changed, for a production setup this should be changed (check app/uwsgi.ini and comment py-autoreload = 2 line).

example api runs

For a REST api check the main.py example, there is a small example provided, e.g.

curl -d '{"key1":"value1", "key2":"value2"}' -H "Content-Type: application/json" -X POST http://localhost:8080/api

should output:

{"request": {"key1": "value1", "key2": "value2"}}

About

template for docker and bottle apps

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published