Skip to content

Create debian templates for the python 3 flask templates. #30

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 8, 2020

Conversation

alexellis
Copy link
Member

The current python3-flask templates use the Alpine base python image.
Precompiled wheels for many important python libraries are not available
for Alpine, but are easily available for Debian. Using Debian makes it
much simpler and easier to use python packages like Numpy or Pillow.

Updated existing Alpine Docker files to include comments.
The template yaml file for the python-http-debian was modified to remove
unneeded libraries.

Both docker files were changed to force python 3.7. Gevent 1.4 is
incompatible with Python 3.8, and the rest of the docker files use
python 3.7.

This has been tested with a bare bones basic function and builds,
runs, and executes properly.

Change listening address for WSGI server.

Update the listening address for the WSGI server to use 0.0.0.0
instead of ''. This should resolve errors about Address family
not supported by protocol (Python OSError Errno 97.

Closes #26

Signed-off-by: Alex Ellis (OpenFaaS Ltd) [email protected]
Signed-off-by: Jeff Lowrey [email protected]

The current python3-flask templates use the Alpine base python image.
Precompiled wheels for many important python libraries are not available
for Alpine, but are easily available for Debian. Using Debian makes it
much simpler and easier to use python packages like Numpy or Pillow.

Updated existing Alpine Docker files to include comments.
The template yaml file for the python-http-debian was modified to remove
unneeded libraries.

Both docker files were changed to force python 3.7. Gevent 1.4 is
incompatible with Python 3.8, and the rest of the docker files use
python 3.7.

This has been tested with a bare bones basic function and builds,
runs, and executes properly.

Change listening address for WSGI server.

Update the listening address for the WSGI server to use 0.0.0.0
instead of ''. This should resolve errors about Address family
not supported by protocol (Python OSError Errno 97.

Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
Signed-off-by: Jeff Lowrey <[email protected]>
@alexellis
Copy link
Member Author

@LucasRoesler @viveksyngh @Jeff-Lowrey FYI

This commit squashes all the WIP commits and reworking down into one concise commit and message.

@alexellis alexellis merged commit 4b6a15d into master Apr 8, 2020
@alexellis alexellis deleted the debian-template branch April 8, 2020 15:27
@alexellis
Copy link
Member Author

@Jeff-Lowrey can you now send a PR to the template store for the new templates?

https://github.com/openfaas/store/blob/master/templates.json

@alexellis
Copy link
Member Author

The README also needs to be updated as per:

Screenshot 2020-04-08 at 16 28 33

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant