Sign inSign up

drewantech/flask_sqlalchemy_psycopg2

By drewantech

•Updated over 9 years ago

psycopg2 2.6.2 installed on drewantech/flask_sqlalchemy:1.0.0

Image
0

298

drewantech/flask_sqlalchemy_psycopg2 repository overview

To run: docker run --net=host drewantech/flask_sqlalchemy_psycopg2:1.0.0

The above command launches the 'test_psycopg2.py' file which serves a webpage at 'http://127.0.0.2:5001/⁠' which prints 'psycopg2 version installed: 2.6.2 (dt dec pq3 ext lo64)' on the '/' url. To change ip use '--host=#.#.#.#' argument. For example: docker run --net=host drewantech/flask:1.0.0 --host=127.0.0.1

To change port use '--port=#' argument. For example: docker run --net=host drewantech/flask:1.0.0 --port=5000

See flask documentation for additional command line arguments.

Image runs with use of 'python_user' in directory of '/home/python_user'. 'test_psycopg2.py' is installed in the '/home/python_user' directory. To install own webserver, it is recommended to delete the '/home/python_user/test_psycopg2.py' file and install the webserver file. Additionally the container environment variable FLASK_APP will need to be updated to point to the new web server's installation location.

Tag summary

Content type

Image

Digest

Size

32.3 MB

Last updated

over 9 years ago

docker pull drewantech/flask_sqlalchemy_psycopg2:1.3.0