Improve environment doc
This commit is contained in:
@@ -8,11 +8,12 @@ requirements.txt file.
|
|||||||
|
|
||||||
## Customizing this image
|
## Customizing this image
|
||||||
|
|
||||||
Most commonly you might want to add package dependencies. Edit
|
To add package dependencies, edit requirements.txt to add what you
|
||||||
requirements.txt to add what you need, and rebuild this image.
|
need, and rebuild this image (instructions below).
|
||||||
|
|
||||||
You also may want to customize what's available to the function in its
|
You also may want to customize what's available to the function in its
|
||||||
context. You can do this by editing server.py.
|
request context. You can do this by editing server.py (see the
|
||||||
|
comment in that file about customizing request context).
|
||||||
|
|
||||||
## Rebuilding and pushing the image
|
## Rebuilding and pushing the image
|
||||||
|
|
||||||
|
|||||||
@@ -24,6 +24,8 @@ def f():
|
|||||||
print("Generic container: no requests supported")
|
print("Generic container: no requests supported")
|
||||||
abort(500)
|
abort(500)
|
||||||
#
|
#
|
||||||
|
# Customizing the request context
|
||||||
|
#
|
||||||
# If you want to pass something to the function, you can add it to 'g':
|
# If you want to pass something to the function, you can add it to 'g':
|
||||||
# g.myKey = myValue
|
# g.myKey = myValue
|
||||||
# And the user func can then access that (after doing a "from flask import g").
|
# And the user func can then access that (after doing a "from flask import g").
|
||||||
|
|||||||
Reference in New Issue
Block a user