Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to build and deploy Python web applications

I have a Python web application consisting of several Python packages. What is the best way of building and deploying this to the servers?

Currently I'm deploying the packages with Capistrano, installing the packages into a virtualenv with bash, and configuring the servers with puppet, but I would like to go for a more Python based solution.

I've been looking a bit into zc.buildout, but it's not clear for me what I can/should use it for.

like image 920
sverrejoh Avatar asked Oct 03 '08 10:10

sverrejoh


People also ask

Can I build a web app with Python?

Python can be used to build server-side web applications. While a web framework is not required to build web apps, it's rare that developers would not use existing open source libraries to speed up their progress in getting their application working. Python is not used in a web browser.

How are Python applications deployed?

When you deploy your app, App Engine uses Cloud Build to build the app into a container and deploy the container to the runtime in the app's region. Cloud Build does not have permission to deploy Python 2 apps by default, so you need to give permission before you can deploy apps.


1 Answers

Depends on what Your infrastructure is. We're just using debian packages and buildbot to make them.

On other setups, I use Fabric scripts. As for format, I'm just using tbz2 files, but I've heard about people just depoloying eggs.

I'd strongly recommend having proper build and having BuildBot/Hudson to build packages, as using SCM beats the purpose and encourage bad practices.

like image 105
Almad Avatar answered Oct 16 '22 15:10

Almad