Flask Function as a Service
flask-faas
Migrating from serverless to a server application can be a headache at times. flask-faas provides you a layer that sits on top of your existing serverless application handlers and helps them convert to Flask routes. The prime goal is to be easy to use and easier to port. We currently support Google Cloud Function, AWS Lambda and OpenFaaS. We would have Azure Functions on the roadmap shortly.
Just import and use, no extra hassle!
from flask_faas.gcp import google_cloud_function
from flask_faas.aws import aws_lambda
from flask import Flask, jsonify
app = Flask(__name__)
@app.route("/gcp/<arg0>",methods=["GET"])
@google_cloud_function
def my_cloud_function_handler(req):
return jsonify(req.view_args)
@app.route("/aws/<arg0>/<arg1>",methods=["GET"])
@aws_lambda
def my_lambda_handler(event, context):
return jsonify([event["pathParameters"]])
if __name__ == '__main__':
app.run()
Supported FaaS handler
- Google Cloud Function
- AWS Lambda
- OpenFaaS
TODO
- Azure Function
Resources:
Metadata
Release files for flask-faas 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| flask-faas-0.0.1.tar.gz | 3.9 kB | Without provenance | Details for flask-faas-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| flask_faas-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for flask_faas-0.0.1-py3-none-any.whl |
Total release size: 8.2 kB
Release files / flask-faas-0.0.1.tar.gz
| Download URL | flask-faas-0.0.1.tar.gz |
|---|---|
| Size | 3.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
84b37a7a529a4f9320ed849c9dc1e9c1ccf87ae8ee0a5be59102f43c82721ab9
|
|
BLAKE2b-256 checksum How to use checksums |
5265932e5ddbb6e5229e4889fe55b785dc24f640ad497167a0d6b2ebbbe134ad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6
|
Release files / flask_faas-0.0.1-py3-none-any.whl
| Download URL | flask_faas-0.0.1-py3-none-any.whl |
|---|---|
| Size | 4.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2baa117afa0526b3fc9686f5f3e860773a69fb00a62a55a23eb4c9539d035bf0
|
|
BLAKE2b-256 checksum How to use checksums |
ac0b3904c5c1de31d2e3a97e45404f2d4d4ad1d32004a9c2377f205aa48bb8c3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6
|
Security for flask-faas 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.