SlideShare a Scribd company logo
Deploy  Python  apps  
   in  5  minutes
    with  a  PaaS
             Nate  Aune
    PyCon  on  the  Charles,  part  1
           Feb.  25,  2013
Jazkarta  (2004-­‐current)
2010-­‐2011

• Nothing  equivalent  to  Heroku  for  Django  
  developers
• Built  my  own  PaaS  (“How  hard  can  it  be?”)
• Shut  down  last  year.  Increased  compeTTon  
  from  big  corps  meant  a  race  to  the  boUom
Appsembler  (2012-­‐current)
Agenda

• Why  should  I  care?  
• What  is  a  PaaS?  What  are  the  advantages?
• Which  PaaS  should  I  use?
• When  might  I  not  want  to  use  a  PaaS?
Where  are  you  
deploying/hosTng  today?
• Shared  hosTng  (i.e.  WebfacTon)
• Running  your  own  servers  (co-­‐located)?
• Using  an  IaaS  provider  (i.e.  AWS  or  Rackspace)
• Already  using  a  plaZorm-­‐as-­‐a-­‐service  (PaaS)
Meet  Dave
Configuring  a  server

         • deciding  what  size  to  get  (memory,  disk)
         • ge]ng  all  the  dependencies  installed  on  it
         • SSHing  into  the  machine  to  deploy  stuff  
           (feels  dirty,  but  he’s  under  Tme  pressure)
1  day      1  day
Maintaining  the  server




1  day   1  day   1  day
Security




1  day   1  day   1  day    1  day
Scaling




1  day   1  day   1  day   1  day   1  day
Oh  sh*t  moment.
Sysadmin $80k
te
sed


        DBA $90k
                       Train new guy

                   6
Why  touch  servers  if  
you  don’t  have  to?
PaaS
Is  it  the  promised  land?
What is a PaaS?
  Platform-as-a-service enables developers to create
innovative applications without operational overhead
 around configuration, deployment and management.
Layers of infrastructure




Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
Source: AppFog “Evolution of the Cloud: Toward a NoOps World” Jan 2012
http://gigaom.com/cloud/why-2013-is-the-year-of-noops-for-programmers-infographic/
Efficient, Elastic, Secure

• Lots of applications co-located on a few servers
 • Drastically reduces resources
 • Add/remove servers depending on load
 • All secured using SELinux or LXC
Let them do
    the boring stuff
• Patches and updates
• Migrating applications
• Backups / snapshots
• Configuring everything (web servers, load
  balancers, modules, databases)
Define  OS  dependencies

         www:
          type: python
          systempackages:
            - openoffice.org
            - mysql-client-5.1


5  min
Backups




5m 5m




        https://devcenter.heroku.com/articles/heroku-postgres-fork
SSL




5m 5m 5m
Scaling




5m 5m 5m 5m




              https://openshift.redhat.com/community/developers/scaling
Caching




5m 5m 5m 5m 5m
IaaS  vs.  PaaS
   IaaS  -­‐  days



  PaaS  -­‐  minutes
Which  PaaS?

• Hosted
• DIY
• Hybrid  (public  with  opTon  to  go  private)
Who are the players?

• CloudFoundry • Heroku
  (open source by VMWare)   (now Salesforce)
                                               • OpenShift
                                                 (Redhat’s open source PaaS)


• AppFog       • Dotcloud                      • App Engine
                                                 (Google)

• Stackato
  (ActiveState)
               • Gondor     (Python only)      • Elastic Beanstalk
                                                 (Amazon)


                                               • Azure
                                                 (Microsoft)
Who are the players?
                  We’ll look at these ones tonight.


• CloudFoundry • Heroku • OpenShift
  (open source by VMWare)    (now Salesforce)   (Redhat’s open source PaaS)


• AppFog       • Dotcloud • App Engine          (Google)

• Stackato • Gondor
  (ActiveState)           • Elastic Beanstalk
                             (Python only)
                                                (Amazon)


                          • Azure               (Microsoft)
Dotcloud
polyglot from the start, very flexible, most Python centric
Anatomy of a
     Django app
    on Dotcloud
customized settings.py for Dotcloud

createdb.py to create the database
dotcloud.yml to store config info
mkadmin.py to make the admin user
nginx.conf to config URL rewriting
postinstall to run syncdb, collectstatic

wsgi.py to serve using uWSGI
Heroku
Anatomy of a
    Django app
    on Heroku

customized settings.py for Heroku


Procfile to configure process

requirements.txt to define dependencies
Stackato
                     by ActiveState
     Python 3, Run anywhere, New Relic integration




http://appsembler.com/blog/django-deployment-using-stackato/
Anatomy of
Django app on
   Stackato

customized settings file




stackato.yml to define services
wsgi.py to serve using uWSGI
OpenShift
                       by Redhat
         Open source, Auto-scaling, Jenkins builds




http://appsembler.com/blog/django-deployment-using-openshift/
Action hooks for running commands
   during build, deploy, post-deploy, etc.



/data/ dir to store uploaded media files

     Anatomy of an
     OpenShift repo
   .htaccess to serve up static files
  application inside of wsgi dir

 setup.py instead of requirements.txt
Stackato OpenShift Dotcloud                                      Heroku
Python           2.7, 3.2 2.6 (2.7) 2.6.5, 2.7.2,                                 2.7.2
                stackato runtimes
                                                       3.1.2, 3.2.2
PostgreSQL         9.1                 8.4                 9.0                     9.1.6
MySQL              5.5                 5.1                 5.1                 (Yes, via RDS)

Persisted FS       Yes                 Yes                 Yes                  (Yes, via S3)

Redis            Yes, 2.4              No              Yes, 2.4.11            (Yes, via addon)

MongoDB          Yes, 2.0            Yes, 2.2           Yes, 2.2.1            (Yes, via addon)

Memcached        Yes, 1.4              No                  Yes                (Yes, via addon)

RabbitMQ         Yes, 2.4              No               Yes, 2.8.5            (Yes, via addon)

Solr               No                  No               Yes, 3.4.0           (Yes, via Websolr)

Cron               Yes                 Yes                 Yes                       Yes
Extensible     Yes, apt-get install Yes, DIY cartridge Yes, custom service      Yes, buildpacks

WebSockets           Yes                Yes                  Yes             Yes, via Pusher add-on
Stackato OpenShift Dotcloud                                      Heroku
Memory       Configurable            1.5GB             Unlimited
                                    RAM               sandbox



Apps         Configurable              No              Yes, 2.8.5            (Yes, via addon)


Solr              No                  No              Yes, 3.4.0           (Yes, via Websolr)


Cron              Yes                 Yes                  Yes                     Yes

Extensible   Yes, apt-get install Yes, DIY cartridge Yes, custom service      Yes, buildpacks




WebSockets        Yes                   ?                  Yes             Yes, via Pusher add-on
Why  not  PaaS?

• Already  invested  in  your  own  infrastructure.
• Need  to  run  on  servers  outside  U.S.
• Special  requirements  not  met  by  PaaS  services
OpenShid  Pricing
Dotcloud  pricing
Heroku pricing
Other resources
• Wrap-up from PaaS bake-off
  http://appsembler.com/blog/wrap-up-from-paas-bake-off/

• Django deployment using PaaS
  http://appsembler.com/blog/django-deployment-using-paas/

• django-deployer
  https://github.com/natea/django-deployer

• paasbakeoff - code examples
   https://github.com/appsembler/paasbakeoff/

More Related Content

What's hot

2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
Fabio Fumarola
 
Colleen Murphy: Puppet and OpenStack
Colleen Murphy: Puppet and OpenStackColleen Murphy: Puppet and OpenStack
Colleen Murphy: Puppet and OpenStack
Puppet
 
20121204 open technet_openstack_이틀만하면나처럼할수있다
20121204 open technet_openstack_이틀만하면나처럼할수있다20121204 open technet_openstack_이틀만하면나처럼할수있다
20121204 open technet_openstack_이틀만하면나처럼할수있다
Nalee Jang
 
3 Git
3 Git3 Git

What's hot (20)

2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
 
Chef & OpenStack: OSCON 2014
Chef & OpenStack: OSCON 2014Chef & OpenStack: OSCON 2014
Chef & OpenStack: OSCON 2014
 
Puppetconf 2015 - Puppet Reporting with Elasticsearch Logstash and Kibana
Puppetconf 2015 - Puppet Reporting with Elasticsearch Logstash and KibanaPuppetconf 2015 - Puppet Reporting with Elasticsearch Logstash and Kibana
Puppetconf 2015 - Puppet Reporting with Elasticsearch Logstash and Kibana
 
Colleen Murphy: Puppet and OpenStack
Colleen Murphy: Puppet and OpenStackColleen Murphy: Puppet and OpenStack
Colleen Murphy: Puppet and OpenStack
 
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers
제4회 한국IBM과 함께하는 난공불락 오픈소스 인프라 세미나-Ranchers
 
Chef 11 Preview/Chef for OpenStack
Chef 11 Preview/Chef for OpenStackChef 11 Preview/Chef for OpenStack
Chef 11 Preview/Chef for OpenStack
 
20121204 open technet_openstack_이틀만하면나처럼할수있다
20121204 open technet_openstack_이틀만하면나처럼할수있다20121204 open technet_openstack_이틀만하면나처럼할수있다
20121204 open technet_openstack_이틀만하면나처럼할수있다
 
Backend, app e internet das coisas com NodeJS no Google Cloud Platform
Backend, app e internet das coisas com NodeJS no Google Cloud PlatformBackend, app e internet das coisas com NodeJS no Google Cloud Platform
Backend, app e internet das coisas com NodeJS no Google Cloud Platform
 
OpenStack Deployments with Chef
OpenStack Deployments with ChefOpenStack Deployments with Chef
OpenStack Deployments with Chef
 
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
CAPS: What's best for deploying and managing OpenStack? Chef vs. Ansible vs. ...
 
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
Leonid Vasilyev  "Building, deploying and running production code at Dropbox"Leonid Vasilyev  "Building, deploying and running production code at Dropbox"
Leonid Vasilyev "Building, deploying and running production code at Dropbox"
 
3 Git
3 Git3 Git
3 Git
 
Red Hat Cloud Infrastructure Conference 2013 - Presentation about OpenStack ...
Red Hat Cloud Infrastructure Conference 2013 -  Presentation about OpenStack ...Red Hat Cloud Infrastructure Conference 2013 -  Presentation about OpenStack ...
Red Hat Cloud Infrastructure Conference 2013 - Presentation about OpenStack ...
 
SCALE12X Build a Cloud Day: Chef: The Swiss Army Knife of Cloud Infrastructure
SCALE12X Build a Cloud Day: Chef: The Swiss Army Knife of Cloud InfrastructureSCALE12X Build a Cloud Day: Chef: The Swiss Army Knife of Cloud Infrastructure
SCALE12X Build a Cloud Day: Chef: The Swiss Army Knife of Cloud Infrastructure
 
Introduction openstack-meetup-nov-28
Introduction openstack-meetup-nov-28Introduction openstack-meetup-nov-28
Introduction openstack-meetup-nov-28
 
[OpenStack Day in Korea 2015] Track 1 - Triple O를 이용한 빠르고 쉬운 OpenStack 설치
[OpenStack Day in Korea 2015] Track 1 - Triple O를 이용한 빠르고 쉬운 OpenStack 설치[OpenStack Day in Korea 2015] Track 1 - Triple O를 이용한 빠르고 쉬운 OpenStack 설치
[OpenStack Day in Korea 2015] Track 1 - Triple O를 이용한 빠르고 쉬운 OpenStack 설치
 
An introduction to maven gradle and sbt
An introduction to maven gradle and sbtAn introduction to maven gradle and sbt
An introduction to maven gradle and sbt
 
Immutable infrastructure 介紹與實做:以 kolla 為例
Immutable infrastructure 介紹與實做:以 kolla 為例Immutable infrastructure 介紹與實做:以 kolla 為例
Immutable infrastructure 介紹與實做:以 kolla 為例
 
Do you know all of Puppet?
Do you know all of Puppet?Do you know all of Puppet?
Do you know all of Puppet?
 
Working with multiple git repositories
Working with multiple git repositoriesWorking with multiple git repositories
Working with multiple git repositories
 

Viewers also liked

Corredor Norte De La Isla Hispaniola Creole
Corredor Norte De La Isla Hispaniola CreoleCorredor Norte De La Isla Hispaniola Creole
Corredor Norte De La Isla Hispaniola Creole
guesta96e92
 
Resume Shavez Hasan (1)
Resume Shavez Hasan (1)Resume Shavez Hasan (1)
Resume Shavez Hasan (1)
Shavez Mirza
 

Viewers also liked (20)

PyCon talk: Deploy Python apps in 5 min with a PaaS
PyCon talk: Deploy Python apps in 5 min with a PaaSPyCon talk: Deploy Python apps in 5 min with a PaaS
PyCon talk: Deploy Python apps in 5 min with a PaaS
 
Corredor Norte De La Isla Hispaniola Creole
Corredor Norte De La Isla Hispaniola CreoleCorredor Norte De La Isla Hispaniola Creole
Corredor Norte De La Isla Hispaniola Creole
 
Maintaining an up to date application stack (in a containerized world)
Maintaining an up to date application stack (in a containerized world)Maintaining an up to date application stack (in a containerized world)
Maintaining an up to date application stack (in a containerized world)
 
Visual Design with Data
Visual Design with DataVisual Design with Data
Visual Design with Data
 
Simplifying and Securing your OpenShift Network with Project Calico
Simplifying and Securing your OpenShift Network with Project CalicoSimplifying and Securing your OpenShift Network with Project Calico
Simplifying and Securing your OpenShift Network with Project Calico
 
Red Hat Storage Day Boston - Persistent Storage for Containers
Red Hat Storage Day Boston - Persistent Storage for Containers Red Hat Storage Day Boston - Persistent Storage for Containers
Red Hat Storage Day Boston - Persistent Storage for Containers
 
Openstack benelux 2015
Openstack benelux 2015Openstack benelux 2015
Openstack benelux 2015
 
DailyTranslate Brochure
DailyTranslate BrochureDailyTranslate Brochure
DailyTranslate Brochure
 
Dev opsmeetup sept2013-leaseweb
Dev opsmeetup sept2013-leasewebDev opsmeetup sept2013-leaseweb
Dev opsmeetup sept2013-leaseweb
 
PerfUG 3 - perfs système
PerfUG 3 - perfs systèmePerfUG 3 - perfs système
PerfUG 3 - perfs système
 
Resume Shavez Hasan (1)
Resume Shavez Hasan (1)Resume Shavez Hasan (1)
Resume Shavez Hasan (1)
 
Docker open stack
Docker open stackDocker open stack
Docker open stack
 
Developing In Python On Red Hat Platforms (Nick Coghlan & Graham Dumpleton)
Developing In Python On Red Hat Platforms (Nick Coghlan & Graham Dumpleton)Developing In Python On Red Hat Platforms (Nick Coghlan & Graham Dumpleton)
Developing In Python On Red Hat Platforms (Nick Coghlan & Graham Dumpleton)
 
Docker meetup - PaaS interoperability
Docker meetup - PaaS interoperabilityDocker meetup - PaaS interoperability
Docker meetup - PaaS interoperability
 
New Features of Kubernetes v1.2.0 beta
New Features of Kubernetes v1.2.0 betaNew Features of Kubernetes v1.2.0 beta
New Features of Kubernetes v1.2.0 beta
 
Movie recommendation system using Apache Mahout and Facebook APIs
Movie recommendation system using Apache Mahout and Facebook APIsMovie recommendation system using Apache Mahout and Facebook APIs
Movie recommendation system using Apache Mahout and Facebook APIs
 
Intro to Mahout
Intro to MahoutIntro to Mahout
Intro to Mahout
 
From legacy to modern CI/CD in tis with concourse
From legacy to modern CI/CD in tis with concourseFrom legacy to modern CI/CD in tis with concourse
From legacy to modern CI/CD in tis with concourse
 
Scalling development teams using Docker
Scalling development teams using DockerScalling development teams using Docker
Scalling development teams using Docker
 
Las redes sociales 1ro a
Las redes sociales 1ro aLas redes sociales 1ro a
Las redes sociales 1ro a
 

Similar to Deploy Python apps in 5 min with a PaaS

Webdevcon Keynote hh-2012-09-18
Webdevcon Keynote hh-2012-09-18Webdevcon Keynote hh-2012-09-18
Webdevcon Keynote hh-2012-09-18
Pierre Joye
 
Netflix oss season 2 episode 1 - meetup Lightning talks
Netflix oss   season 2 episode 1 - meetup Lightning talksNetflix oss   season 2 episode 1 - meetup Lightning talks
Netflix oss season 2 episode 1 - meetup Lightning talks
Ruslan Meshenberg
 
Cannibalising The Google App Engine
Cannibalising The  Google  App  EngineCannibalising The  Google  App  Engine
Cannibalising The Google App Engine
catherinewall
 
The future of server side JavaScript
The future of server side JavaScriptThe future of server side JavaScript
The future of server side JavaScript
Oleg Podsechin
 

Similar to Deploy Python apps in 5 min with a PaaS (20)

State of Big Data on ARM64 / AArch64 - Apache Bigtop
State of Big Data on ARM64 / AArch64 - Apache BigtopState of Big Data on ARM64 / AArch64 - Apache Bigtop
State of Big Data on ARM64 / AArch64 - Apache Bigtop
 
Webdevcon Keynote hh-2012-09-18
Webdevcon Keynote hh-2012-09-18Webdevcon Keynote hh-2012-09-18
Webdevcon Keynote hh-2012-09-18
 
Public PaaS Throwdown!
Public PaaS Throwdown!Public PaaS Throwdown!
Public PaaS Throwdown!
 
Netflix oss season 2 episode 1 - meetup Lightning talks
Netflix oss   season 2 episode 1 - meetup Lightning talksNetflix oss   season 2 episode 1 - meetup Lightning talks
Netflix oss season 2 episode 1 - meetup Lightning talks
 
Cloud Computing Bootcamp On The Google App Engine [v1.1]
Cloud Computing Bootcamp On The Google App Engine [v1.1]Cloud Computing Bootcamp On The Google App Engine [v1.1]
Cloud Computing Bootcamp On The Google App Engine [v1.1]
 
Setting up a free open source java e-commerce website
Setting up a free open source java e-commerce websiteSetting up a free open source java e-commerce website
Setting up a free open source java e-commerce website
 
Google App Engine Java, Groovy and Gaelyk
Google App Engine Java, Groovy and GaelykGoogle App Engine Java, Groovy and Gaelyk
Google App Engine Java, Groovy and Gaelyk
 
Cannibalising The Google App Engine
Cannibalising The  Google  App  EngineCannibalising The  Google  App  Engine
Cannibalising The Google App Engine
 
Intro to DefectDojo at OWASP Switzerland
Intro to DefectDojo at OWASP SwitzerlandIntro to DefectDojo at OWASP Switzerland
Intro to DefectDojo at OWASP Switzerland
 
The future of server side JavaScript
The future of server side JavaScriptThe future of server side JavaScript
The future of server side JavaScript
 
Introducing resinOS: An Operating System Tailored for Containers and Built fo...
Introducing resinOS: An Operating System Tailored for Containers and Built fo...Introducing resinOS: An Operating System Tailored for Containers and Built fo...
Introducing resinOS: An Operating System Tailored for Containers and Built fo...
 
Making sense of Apache Bigtop's role in ODPi and how it matters to Apache Apex
Making sense of Apache Bigtop's role in ODPi and how it matters to Apache ApexMaking sense of Apache Bigtop's role in ODPi and how it matters to Apache Apex
Making sense of Apache Bigtop's role in ODPi and how it matters to Apache Apex
 
node.js 실무 - node js in practice by Jesang Yoon
node.js 실무 - node js in practice by Jesang Yoonnode.js 실무 - node js in practice by Jesang Yoon
node.js 실무 - node js in practice by Jesang Yoon
 
DevOps Unleashed: Strategies that Speed Deployments
DevOps Unleashed: Strategies that Speed DeploymentsDevOps Unleashed: Strategies that Speed Deployments
DevOps Unleashed: Strategies that Speed Deployments
 
Flexible compute
Flexible computeFlexible compute
Flexible compute
 
Sanger, upcoming Openstack for Bio-informaticians
Sanger, upcoming Openstack for Bio-informaticiansSanger, upcoming Openstack for Bio-informaticians
Sanger, upcoming Openstack for Bio-informaticians
 
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
Continuous Integration and Deployment Best Practices on AWS (ARC307) | AWS re...
 
Continuous Deployment @ AWS Re:Invent
Continuous Deployment @ AWS Re:InventContinuous Deployment @ AWS Re:Invent
Continuous Deployment @ AWS Re:Invent
 
Sparklife - Life In The Trenches With Spark
Sparklife - Life In The Trenches With SparkSparklife - Life In The Trenches With Spark
Sparklife - Life In The Trenches With Spark
 
.NET7.pptx
.NET7.pptx.NET7.pptx
.NET7.pptx
 

More from Appsembler

Scaling Open edX with Kubernetes
Scaling Open edX with KubernetesScaling Open edX with Kubernetes
Scaling Open edX with Kubernetes
Appsembler
 

More from Appsembler (9)

Anatomy of Open edX at DjangoBoston October 2018
Anatomy of Open edX at DjangoBoston October 2018Anatomy of Open edX at DjangoBoston October 2018
Anatomy of Open edX at DjangoBoston October 2018
 
Eucalyptus Release of Open edX
Eucalyptus Release of Open edXEucalyptus Release of Open edX
Eucalyptus Release of Open edX
 
Open edX Conference 2016 Review
Open edX Conference 2016 ReviewOpen edX Conference 2016 Review
Open edX Conference 2016 Review
 
Open edX & Interoperability: Making Open edX play nicely with others
Open edX & Interoperability: Making Open edX play nicely with othersOpen edX & Interoperability: Making Open edX play nicely with others
Open edX & Interoperability: Making Open edX play nicely with others
 
Open edX for Corporate Learning - Open edX Conference 2016
Open edX for Corporate Learning - Open edX Conference 2016Open edX for Corporate Learning - Open edX Conference 2016
Open edX for Corporate Learning - Open edX Conference 2016
 
What's new: Open edX Dogwood release
What's new: Open edX Dogwood releaseWhat's new: Open edX Dogwood release
What's new: Open edX Dogwood release
 
Open edX & Interoperability: Making Open edX play nicely with others
Open edX & Interoperability: Making Open edX play nicely with othersOpen edX & Interoperability: Making Open edX play nicely with others
Open edX & Interoperability: Making Open edX play nicely with others
 
A Survey of XBlocks for extending Open edX
A Survey of XBlocks for extending Open edXA Survey of XBlocks for extending Open edX
A Survey of XBlocks for extending Open edX
 
Scaling Open edX with Kubernetes
Scaling Open edX with KubernetesScaling Open edX with Kubernetes
Scaling Open edX with Kubernetes
 

Recently uploaded

Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Peter Udo Diehl
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
Bhaskar Mitra
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
Safe Software
 

Recently uploaded (20)

To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
 
IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024IoT Analytics Company Presentation May 2024
IoT Analytics Company Presentation May 2024
 
Introduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG EvaluationIntroduction to Open Source RAG and RAG Evaluation
Introduction to Open Source RAG and RAG Evaluation
 
Optimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityOptimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through Observability
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
 
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
 

Deploy Python apps in 5 min with a PaaS

  • 1. Deploy  Python  apps   in  5  minutes with  a  PaaS Nate  Aune PyCon  on  the  Charles,  part  1 Feb.  25,  2013
  • 3. 2010-­‐2011 • Nothing  equivalent  to  Heroku  for  Django   developers • Built  my  own  PaaS  (“How  hard  can  it  be?”) • Shut  down  last  year.  Increased  compeTTon   from  big  corps  meant  a  race  to  the  boUom
  • 5. Agenda • Why  should  I  care?   • What  is  a  PaaS?  What  are  the  advantages? • Which  PaaS  should  I  use? • When  might  I  not  want  to  use  a  PaaS?
  • 6. Where  are  you   deploying/hosTng  today? • Shared  hosTng  (i.e.  WebfacTon) • Running  your  own  servers  (co-­‐located)? • Using  an  IaaS  provider  (i.e.  AWS  or  Rackspace) • Already  using  a  plaZorm-­‐as-­‐a-­‐service  (PaaS)
  • 8.
  • 9. Configuring  a  server • deciding  what  size  to  get  (memory,  disk) • ge]ng  all  the  dependencies  installed  on  it • SSHing  into  the  machine  to  deploy  stuff   (feels  dirty,  but  he’s  under  Tme  pressure) 1  day 1  day
  • 10. Maintaining  the  server 1  day 1  day 1  day
  • 11. Security 1  day 1  day 1  day 1  day
  • 12. Scaling 1  day 1  day 1  day 1  day 1  day
  • 14. Sysadmin $80k te sed DBA $90k Train new guy 6
  • 15. Why  touch  servers  if   you  don’t  have  to?
  • 16. PaaS Is  it  the  promised  land?
  • 17. What is a PaaS? Platform-as-a-service enables developers to create innovative applications without operational overhead around configuration, deployment and management.
  • 18. Layers of infrastructure Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
  • 19. Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
  • 20. Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
  • 21. Source: EngineYard “PaaS - State of the Market Survey” May 2012 - http://venturebeat.com/2012/07/05/engine-yard-paas-infographic/
  • 22. Source: AppFog “Evolution of the Cloud: Toward a NoOps World” Jan 2012 http://gigaom.com/cloud/why-2013-is-the-year-of-noops-for-programmers-infographic/
  • 23. Efficient, Elastic, Secure • Lots of applications co-located on a few servers • Drastically reduces resources • Add/remove servers depending on load • All secured using SELinux or LXC
  • 24. Let them do the boring stuff • Patches and updates • Migrating applications • Backups / snapshots • Configuring everything (web servers, load balancers, modules, databases)
  • 25. Define  OS  dependencies www: type: python systempackages: - openoffice.org - mysql-client-5.1 5  min
  • 26. Backups 5m 5m https://devcenter.heroku.com/articles/heroku-postgres-fork
  • 28. Scaling 5m 5m 5m 5m https://openshift.redhat.com/community/developers/scaling
  • 30. IaaS  vs.  PaaS IaaS  -­‐  days PaaS  -­‐  minutes
  • 31. Which  PaaS? • Hosted • DIY • Hybrid  (public  with  opTon  to  go  private)
  • 32. Who are the players? • CloudFoundry • Heroku (open source by VMWare) (now Salesforce) • OpenShift (Redhat’s open source PaaS) • AppFog • Dotcloud • App Engine (Google) • Stackato (ActiveState) • Gondor (Python only) • Elastic Beanstalk (Amazon) • Azure (Microsoft)
  • 33. Who are the players? We’ll look at these ones tonight. • CloudFoundry • Heroku • OpenShift (open source by VMWare) (now Salesforce) (Redhat’s open source PaaS) • AppFog • Dotcloud • App Engine (Google) • Stackato • Gondor (ActiveState) • Elastic Beanstalk (Python only) (Amazon) • Azure (Microsoft)
  • 34. Dotcloud polyglot from the start, very flexible, most Python centric
  • 35.
  • 36.
  • 37. Anatomy of a Django app on Dotcloud customized settings.py for Dotcloud createdb.py to create the database dotcloud.yml to store config info mkadmin.py to make the admin user nginx.conf to config URL rewriting postinstall to run syncdb, collectstatic wsgi.py to serve using uWSGI
  • 39.
  • 40.
  • 41. Anatomy of a Django app on Heroku customized settings.py for Heroku Procfile to configure process requirements.txt to define dependencies
  • 42. Stackato by ActiveState Python 3, Run anywhere, New Relic integration http://appsembler.com/blog/django-deployment-using-stackato/
  • 43.
  • 44.
  • 45. Anatomy of Django app on Stackato customized settings file stackato.yml to define services wsgi.py to serve using uWSGI
  • 46. OpenShift by Redhat Open source, Auto-scaling, Jenkins builds http://appsembler.com/blog/django-deployment-using-openshift/
  • 47.
  • 48. Action hooks for running commands during build, deploy, post-deploy, etc. /data/ dir to store uploaded media files Anatomy of an OpenShift repo .htaccess to serve up static files application inside of wsgi dir setup.py instead of requirements.txt
  • 49. Stackato OpenShift Dotcloud Heroku Python 2.7, 3.2 2.6 (2.7) 2.6.5, 2.7.2, 2.7.2 stackato runtimes 3.1.2, 3.2.2 PostgreSQL 9.1 8.4 9.0 9.1.6 MySQL 5.5 5.1 5.1 (Yes, via RDS) Persisted FS Yes Yes Yes (Yes, via S3) Redis Yes, 2.4 No Yes, 2.4.11 (Yes, via addon) MongoDB Yes, 2.0 Yes, 2.2 Yes, 2.2.1 (Yes, via addon) Memcached Yes, 1.4 No Yes (Yes, via addon) RabbitMQ Yes, 2.4 No Yes, 2.8.5 (Yes, via addon) Solr No No Yes, 3.4.0 (Yes, via Websolr) Cron Yes Yes Yes Yes Extensible Yes, apt-get install Yes, DIY cartridge Yes, custom service Yes, buildpacks WebSockets Yes Yes Yes Yes, via Pusher add-on
  • 50. Stackato OpenShift Dotcloud Heroku Memory Configurable 1.5GB Unlimited RAM sandbox Apps Configurable No Yes, 2.8.5 (Yes, via addon) Solr No No Yes, 3.4.0 (Yes, via Websolr) Cron Yes Yes Yes Yes Extensible Yes, apt-get install Yes, DIY cartridge Yes, custom service Yes, buildpacks WebSockets Yes ? Yes Yes, via Pusher add-on
  • 51. Why  not  PaaS? • Already  invested  in  your  own  infrastructure. • Need  to  run  on  servers  outside  U.S. • Special  requirements  not  met  by  PaaS  services
  • 55. Other resources • Wrap-up from PaaS bake-off http://appsembler.com/blog/wrap-up-from-paas-bake-off/ • Django deployment using PaaS http://appsembler.com/blog/django-deployment-using-paas/ • django-deployer https://github.com/natea/django-deployer • paasbakeoff - code examples https://github.com/appsembler/paasbakeoff/