Push an app with a main web process that runs forever (in this case it does nothing) and there is no healthcheck
Download main.py
, http-call.py
, and requirement.txt
into a directory. Then from that directory, run:
cf push py-simple -b https://github.com/cloudfoundry/python-buildpack.git -c "python main.py" -u none
Once the app is pushed, you can tail the logs
cf tail -f py-simple
Then you can run a task using any other python file that is bundled with the app, like http-call.py:
cf run-task py-simple "python http-call.py"
In the logs, you should see the status of the request print out
2019-04-08T21:27:10.22-0600 [APP/TASK/744dbd64/0] OUT https://pivotal.io STATUS 200