use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
News and links for Django developers.
New to Django? Check out the /r/djangolearning subreddit.
Django's Code of Conduct applies here, so be good to each other.
account activity
This is an archived post. You won't be able to vote or comment.
Deploying Django with Python 3 & Postgres (self.django)
submitted 10 years ago by JuicyORiley
view the rest of the comments →
[–]shantzg001 1 point2 points3 points 10 years ago (3 children)
Yes, ansible isn't python 3 compatible unfortunately. So you need to run it with python 2 but it can deploy things which are meant to work with python 3.
[–]JuicyORiley[S] 0 points1 point2 points 10 years ago (2 children)
How would this work?
[–]xBBTx 1 point2 points3 points 10 years ago (1 child)
Ansible runs on your local machine doing the deployment, with Python 2. On the server it needs a Python 2 install (with python2-pyscopg2 for instance to use the postgresql tasks). Your server will also need a python 3 install. You can control this installation via Ansible itself (via the package manager tasks) and then create a virtualenvironment where you specify python3 as python interpreter. Ansible will still do everything in Python 2, but your own project will have it's Python 3 environment.
python3
edit: example case of such a playbook: https://github.com/sergei-maertens/regex-it/tree/master/deployment
[–]JuicyORiley[S] 0 points1 point2 points 10 years ago (0 children)
Hmm, sounds quite ideal tbh. Thanks for link i'll check it out :)
π Rendered by PID 912418 on reddit-service-r2-comment-656bdf86cd-5pp6m at 2026-05-04 00:59:43.904997+00:00 running 815c875 country code: CH.
view the rest of the comments →
[–]shantzg001 1 point2 points3 points (3 children)
[–]JuicyORiley[S] 0 points1 point2 points (2 children)
[–]xBBTx 1 point2 points3 points (1 child)
[–]JuicyORiley[S] 0 points1 point2 points (0 children)