Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Adventurer in the Land of Production Environment

Adventurer in the Land of Production Environment

If your background is software development, the first time you need to run code on a server and serve it to the world can be pretty intimidating. Just as if you suddenly found yourself in a strange land, full of magic and composed of dungeons…

Maciej Pasternacki

May 17, 2013
Tweet

More Decks by Maciej Pasternacki

Other Decks in Technology

Transcript

  1. e weather is mild and comfortable. A slight wind is

    blowing. A server. $ sudo su - # _
  2. e weather is mild and comfortable. A slight wind is

    blowing. A server. $ sudo su - # screen # _
  3. e weather is mild and comfortable. A slight wind is

    blowing. A server. $ sudo su - # screen # ./manage.py runserver 80 _
  4. e weather is mild and comfortable. A slight wind is

    blowing. A server. $ sudo su - # screen # ./manage.py runserver 80 [detached] $ _
  5. Congratulations! You advance to level 1. $ sudo su -

    # screen # ./manage.py runserver 80 [detached] $ _
  6. Examine inventory # ./manage.py runserver 80 Runs as root: -33

    Strength Single-threaded: -10 Dexterity Static files served by Django: -15 Speed
  7. Use XP to upgrade: gunicorn fcgi uwsgi mod_wsgi nginx lighttpd

    apache +5 Mana +8 Dexterity http://raingna.deviantart.com/art/FiM-style-Django-pony-318540512 Static les Not root, high port #
  8. Put on some armor – Isolate your code in virtualenv

    – Get Immune to Surprise Upgrades: pip freeze or vendor libraries
  9. Amulet of Life Saving – runit – supervisord – daemontools

    – upstart – systemd – monit – god – bluepill
  10. Acquire skill: Alchemy – Plain Old Shell ScrollsScripts –    

    devstructure/blueprint – Chef, Puppet – Ansible
  11. e Final Boss: Gear Up! – Chef/Puppet – MCollective/Salt –

    Rundeck – Nagios Icinga – Graphite – Statsd – Logstash
  12. Beyond the map – High Availability – Resiliency – Autoscaling

    – Self-healing Need a guide, sir? http://3ofcoins.net/ [email protected]