Flask APP to run on OpenShift with automatic deploys by WerckerCI
pip install -r requirements.txt
python app.py
then
http://localhost:5000/calc/sum/1/2
{"result": 3}
Operations are: sum, sub, mul, div
The Swagger API is available at:
http://localhost:5000/apidocs/index.html
Create a fork on your own github account
click the link below and change the git url to your own repo
- Create your wercker account
- Register a new application: https://app.wercker.com/#applications/create using your forked repo
- Trigger a build and see it passing
- Create an access token on OPenShift https://openshift.redhat.com/app/console/authorizations/new
- Paste this access token on wercker deploy page https://app.wercker.com/#applications/YOUR_APP_ID/settings/targets/openshift
- Then Wwercker will create an SSH Key for you, add this key to your OPenShift panel https://openshift.redhat.com/app/console/keys/new
- select [x] Auto Deploy on successful build
- DONE! in the next github commit the deployment will be automatic