IBM i

Expand all | Collapse all

Is it possible to use Flask with Python on IBM i to build small apps?

  • 1.  Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Thu October 07, 2021 09:00 AM
    A developer reached out to me about using Flask open source on IBM i.  Is this possible?  We have Python and other utilities already installed on our development server at OS 7.3.  I found documentation for Flask but nothing helpful for installation on IBM i.

    Jim

    ------------------------------
    Jim Olliges
    ------------------------------


  • 2.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Fri October 08, 2021 02:10 AM
    Sorry for not answering your question but there are discussions regarding Flask and IBM i here: https://ibmioss.ryver.com/index.html#search
    Good luck!

    ------------------------------
    Torbjörn Appehl
    ------------------------------



  • 3.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Fri October 08, 2021 10:39 AM
    Yes, Flask works fine and can be installed as you would any Python package, using pip. I'd recommend using a virtual environment to install it (standard Python best practice). If you need to access harder to install packages that are installable via yum (eg. ibm_db, pyodbc, numpy, ...) you can use `--system-site-packages` option to venv.

    The builtin application server works, but deploying to production you probably want a better one. I'd recommend Gunicorn with an Apache or NGINX proxy in front of it.

    If you have more questions, I'd recommend the Ryver IBM i Python forum: https://ibmioss.ryver.com/index.html#forums/1000128/chat (signup here: http://ibm.biz/ibmioss-chat-join)

    ------------------------------
    Kevin Adler
    ------------------------------



  • 4.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Fri October 08, 2021 10:55 AM
    Thanks Kevin & Torbjorn,

        We went to our crash and burn engineering test system and figured out through trial and error how to install with pip using some modified instructions from here:


    https://flask.palletsprojects.com/en/2.0.x/installation/#install-flask 

    Thank you for your help!

    Jim

    ------------------------------
    Jim Olliges
    ------------------------------



  • 5.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Fri October 08, 2021 11:53 AM
    There's also more info on using Python on IBM i here: https://ibmi-oss-docs.readthedocs.io/en/latest/python/README.html

    ------------------------------
    Kevin Adler
    ------------------------------



  • 6.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Sat October 09, 2021 04:01 AM
    And why not go to Ocean User Group later this month and learn more.. https://www.oceanusergroup.org/index.php?option=com_jevents&task=icalevent.detail&evid=32

    ------------------------------
    Torbjörn Appehl
    ------------------------------



  • 7.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Sat October 09, 2021 12:21 PM

    Hello,

     

       Perfect timing on that!  Would love to attend but we are in the Midwest and it does not appear Stephanie will live stream the event in CA.  I reached out to her on LinkedIn.  Hopefully, she will conduct a webinar on this or attend IBM virtual events in the near future. 

     

    Thank you for your time,

     

     

    Jim Olliges | Technology | CDW LLC

    Email: jameoll@cdw.com |  Ph: 847.419.6369  |  Mobile: 847.507.8095

    ----------------------------------------------------------------------------------------

    Service Now : IBMiSupport@cdw.com

    On-Call IBM i Team Support Dial: 847.419.6593

    8FEFA60Eidg award

     

     






  • 8.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Sun October 10, 2021 02:45 AM
    Yeah, she is great. Maybe she can help your company as a service..

    ------------------------------
    Torbjörn Appehl
    ------------------------------



  • 9.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Tue October 12, 2021 07:55 AM
    Then this will be perfect for you; I have made a "get started with python flask on IBM i"

    https://github.com/NielsLiisberg/Python-flask-demo

    Simply follow the instructions in the readme.md


    ------------------------------
    Niels Liisberg
    ------------------------------



  • 10.  RE: Is it possible to use Flask with Python on IBM i to build small apps?

    Posted Wed October 13, 2021 09:49 AM
    Here's a session I did last year on using Flask with IBM i.

    Pass the Flask and Quickly Pour IBM i Python Web Apps and Services
    https://www.youtube.com/watch?v=k8IrBGebfvo

    If you're interested in any IBM i specific Python training, feel free to reach out.

    Regards,
    Richard Schoen
    Web: http://www.richardschoen.net
    Email: richard@richardschoen.net

     



    ------------------------------
    Richard Schoen
    ------------------------------