SlideShare uma empresa Scribd logo
1 de 20
Baixar para ler offline
Deploying

                       • Corey Purcell
                       • @coreypurcell
                       • Thanks to Daniel Carper


Friday, June 3, 2011
About Me
             Penn United Technologies
            We make stuff, like things you
                   can touch!




Friday, June 3, 2011
My Environment

                       • Oracle
                       • All internal applications (currently)
                       • Low traffic
                       • Managing deployment with Moonshine

Friday, June 3, 2011
Moonshine
                 Moonshine is an opensource configuration management
                   and deployment system that follows the Rails way,
                     simplifying server configuration, dependency
                  management, and Rails application deployment, using
                                   Ruby and Puppet.




Friday, June 3, 2011
ruby script/plugin install git://github.com/railsmachine/moonshine.git

               ruby script/generate moonshine




               #Editing Moonshine.yml
               :ruby: ree187

               :application: moonshine-test
               :deploy_to: /var/applications/moonshine-test
               :repository: git@github.com:coreypurcell/moonshine-test.git

               :domain: tooling.pennunited.com
               :shared_config:
                 - config/database.yml




Friday, June 3, 2011
capify .

                       #deploy.rb
                       server "rails-box", :app, :web, :db, :primary => true

                       cap deploy:setup

                       cap deploy




Friday, June 3, 2011
The Good

                       • Capistrano Based
                       • Plugins
                       • Puppet based
                       • 15 minutes to build a server

Friday, June 3, 2011
The Ugly (to me)

                       • Capistrano Based
                       • Templates are stored in app/manifests
                       • Slow to deploy (5-10 minutes)
                       • Mixes deployment with server managment

Friday, June 3, 2011
Git Pusshuten
                   A Git-based application deployment tool that allows
                   you to define your environment by utilizing modules
                  and provision your server with basic deployment needs




Friday, June 3, 2011
gem install gitpusshuten
                       ten initialize

                       #creates .gitpusshuten/
                       pusshuten 'Hello Git Pusshu Ten', :staging, :production do

                         configure do |c|
                           c.user       =   'gitpusshuten'
                           c.ip         =   '172.16.3.142'
                           # c.password     = 'my-password'
                           # c.passphrase   = 'my-ssh-passphrase'
                           # c.port         = '22'

                           c.path       = '/var/applications/'
                         end

                         modules do |m|
                           m.add :bundler
                           m.add :active_record
                           m.add :passenger
                           # m.add :nginx
                           m.add :apache
                           # m.add :nanoc
                           m.add :rvm
                           # m.add :mysql
                           # m.add :redis
                         end

                       end




Friday, June 3, 2011
ten user install-root-ssh-key to staging
                       #enter root password
                       ten rvm install to staging
                       # 1.9.2
                       ten passenger install to staging

                       #errors!!!!!!!

                       ten rvm install to staging
                       ten passenger install to staging
                       # select apache

                       ten user add to staging
                       #choose password




Friday, June 3, 2011
#edit vhost on your local machine, .gitpusshuten/apache/staging.vhost
                <VirtualHost *:80>
                  ServerName pusshuten.local
                  ServerAlias www.pusshuten.local
                  DocumentRoot /var/applications/hello_git_pusshu_ten.staging/public
                  <Directory /var/applications/hello_git_pusshu_ten.staging/public>
                    AllowOverride all
                    Options -MultiViews
                  </Directory>
                  SetEnv LD_LIBRARY_PATH /opt/oracle/instantclient_11_2
                  SetEnv TNS_ADMIN /opt/oracle/instantclient_11_2/network
                </VirtualHost>




Friday, June 3, 2011
ten push branch master to staging



                       Done!


                       ten active_record upload_config to staging
                       ten apache upload-vhost to staging




Friday, June 3, 2011
Git Pusshu Ten


 [Aliases]

     gitpusshuten, heavenly, ten

 [Commands]

   active_record [Module] Active Record commands.
   apache [Module] Apache commands.
   bundler [Module] Bundler commands.
   delete Deletes the application of the specified environment.
   help    Displays the command list, or the help screen for a specific command.
   initialize Initializes Git Pusshu Ten with the working directory.
   passenger [Module] Phusion Passenger commands.
   push    Pushes a branch, tag or ref to the specified environment.
   remote Performs a command on the remote server for the specified environment from
 the application root.
   rvm   [Module] Ruby Version Manager (RVM) commands.
   user    Interacts with users, based on the <app_root>/.gitpusshuten/config.rb file.
   version Displays the current version of Git Pusshu Ten
 [Command Specific Help]

     heavenly help <command>




Friday, June 3, 2011
The Good

                       • separation of deployment from code
                       • deploy from any branch, ref, tag
                       • server setup in 15-30 mins
                       • deploys take around 30 seconds

Friday, June 3, 2011
The Ugly


                       • Not that many modules
                       • Not very active


Friday, June 3, 2011
Friday, June 3, 2011
Friday, June 3, 2011
Thanks


                       • https://github.com/railsmachine/moonshine
                       • http://gitpusshuten.com


Friday, June 3, 2011
Shameless Plug
                                http://bit.ly/ep-runwalk

                       5K Run for Epilepsy Foundation - June 25

                                    Please Donate.




Friday, June 3, 2011

Mais conteúdo relacionado

Mais procurados

Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...Puppet
 
A Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy SystemA Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy Systemadrian_nye
 
Automated reproducible images on openstack using vagrant and packer
Automated reproducible images on openstack using vagrant and packerAutomated reproducible images on openstack using vagrant and packer
Automated reproducible images on openstack using vagrant and packerJan Collijs
 
DevOps Hackathon - Session 1: Vagrant
DevOps Hackathon - Session 1: VagrantDevOps Hackathon - Session 1: Vagrant
DevOps Hackathon - Session 1: VagrantAntons Kranga
 
Automated Deployment with Fabric
Automated Deployment with FabricAutomated Deployment with Fabric
Automated Deployment with Fabrictanihito
 
FPM at the Ruby Drink-up of Sophia, September 2011
FPM at the Ruby Drink-up of Sophia, September 2011FPM at the Ruby Drink-up of Sophia, September 2011
FPM at the Ruby Drink-up of Sophia, September 2011rivierarb
 
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...Puppet
 
Chef, Vagrant, and VirtualBox
Chef, Vagrant, and VirtualBoxChef, Vagrant, and VirtualBox
Chef, Vagrant, and VirtualBoxJason Vanderhoof
 
Thinking through puppet code layout
Thinking through puppet code layoutThinking through puppet code layout
Thinking through puppet code layoutTomas Doran
 
Machine learning in Apache Zeppelin
Machine learning in Apache ZeppelinMachine learning in Apache Zeppelin
Machine learning in Apache ZeppelinGary Sieling
 
Python eggs (RO)
Python eggs (RO)Python eggs (RO)
Python eggs (RO)Alin Voinea
 
Killer R10K Workflow - PuppetConf 2014
Killer R10K Workflow - PuppetConf 2014Killer R10K Workflow - PuppetConf 2014
Killer R10K Workflow - PuppetConf 2014Puppet
 
Dev ninja -> vagrant + virtualbox + chef-solo + git + ec2
Dev ninja  -> vagrant + virtualbox + chef-solo + git + ec2Dev ninja  -> vagrant + virtualbox + chef-solo + git + ec2
Dev ninja -> vagrant + virtualbox + chef-solo + git + ec2Yros
 
Deploying Rails Applications with Capistrano
Deploying Rails Applications with CapistranoDeploying Rails Applications with Capistrano
Deploying Rails Applications with CapistranoAlmir Mendes
 
A quick intro to Ansible
A quick intro to AnsibleA quick intro to Ansible
A quick intro to AnsibleDan Vaida
 
Deploying Rails applications with Moonshine
Deploying Rails applications with MoonshineDeploying Rails applications with Moonshine
Deploying Rails applications with MoonshineRobot Mode
 
Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Yury Pliashkou
 

Mais procurados (20)

Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
Continuous Infrastructure: Modern Puppet for the Jenkins Project - PuppetConf...
 
A Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy SystemA Fabric/Puppet Build/Deploy System
A Fabric/Puppet Build/Deploy System
 
Ansible 202
Ansible 202Ansible 202
Ansible 202
 
Automated reproducible images on openstack using vagrant and packer
Automated reproducible images on openstack using vagrant and packerAutomated reproducible images on openstack using vagrant and packer
Automated reproducible images on openstack using vagrant and packer
 
DevOps Hackathon - Session 1: Vagrant
DevOps Hackathon - Session 1: VagrantDevOps Hackathon - Session 1: Vagrant
DevOps Hackathon - Session 1: Vagrant
 
Capistrano
CapistranoCapistrano
Capistrano
 
Automated Deployment with Fabric
Automated Deployment with FabricAutomated Deployment with Fabric
Automated Deployment with Fabric
 
FPM at the Ruby Drink-up of Sophia, September 2011
FPM at the Ruby Drink-up of Sophia, September 2011FPM at the Ruby Drink-up of Sophia, September 2011
FPM at the Ruby Drink-up of Sophia, September 2011
 
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
 
Chef, Vagrant, and VirtualBox
Chef, Vagrant, and VirtualBoxChef, Vagrant, and VirtualBox
Chef, Vagrant, and VirtualBox
 
Thinking through puppet code layout
Thinking through puppet code layoutThinking through puppet code layout
Thinking through puppet code layout
 
Machine learning in Apache Zeppelin
Machine learning in Apache ZeppelinMachine learning in Apache Zeppelin
Machine learning in Apache Zeppelin
 
Chef
ChefChef
Chef
 
Python eggs (RO)
Python eggs (RO)Python eggs (RO)
Python eggs (RO)
 
Killer R10K Workflow - PuppetConf 2014
Killer R10K Workflow - PuppetConf 2014Killer R10K Workflow - PuppetConf 2014
Killer R10K Workflow - PuppetConf 2014
 
Dev ninja -> vagrant + virtualbox + chef-solo + git + ec2
Dev ninja  -> vagrant + virtualbox + chef-solo + git + ec2Dev ninja  -> vagrant + virtualbox + chef-solo + git + ec2
Dev ninja -> vagrant + virtualbox + chef-solo + git + ec2
 
Deploying Rails Applications with Capistrano
Deploying Rails Applications with CapistranoDeploying Rails Applications with Capistrano
Deploying Rails Applications with Capistrano
 
A quick intro to Ansible
A quick intro to AnsibleA quick intro to Ansible
A quick intro to Ansible
 
Deploying Rails applications with Moonshine
Deploying Rails applications with MoonshineDeploying Rails applications with Moonshine
Deploying Rails applications with Moonshine
 
Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11Capifony. Minsk PHP MeetUp #11
Capifony. Minsk PHP MeetUp #11
 

Destaque

LeanOps as part of Devops
LeanOps as part of DevopsLeanOps as part of Devops
LeanOps as part of DevopsJohn Willis
 
CompatibleOne bringing cloud as a commodity
CompatibleOne bringing cloud as a commodityCompatibleOne bringing cloud as a commodity
CompatibleOne bringing cloud as a commodityCompatibleOne
 
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017Bish Chanda
 
1. introducción a la Ingeniería de Software (UTM 2071)
1. introducción a la Ingeniería de Software (UTM 2071)1. introducción a la Ingeniería de Software (UTM 2071)
1. introducción a la Ingeniería de Software (UTM 2071)Mario A Moreno Rocha
 
How can you measure the productivity in your company?
How can you measure the productivity in your company?How can you measure the productivity in your company?
How can you measure the productivity in your company?Nexus Electronics
 
Cloud Computing and the Datacenter of the Future
Cloud Computing and the Datacenter of the FutureCloud Computing and the Datacenter of the Future
Cloud Computing and the Datacenter of the FutureAppistry
 
Corporate Risk Mngmnt-commodity Hedging
Corporate Risk Mngmnt-commodity HedgingCorporate Risk Mngmnt-commodity Hedging
Corporate Risk Mngmnt-commodity Hedgingkirankhandelwal
 
Modern Software Productivity Measurement: The Pragmatic Guide
Modern Software Productivity Measurement: The Pragmatic GuideModern Software Productivity Measurement: The Pragmatic Guide
Modern Software Productivity Measurement: The Pragmatic GuideCAST
 
Understanding and improving software productivity
Understanding and improving software productivityUnderstanding and improving software productivity
Understanding and improving software productivityGeorge Valiyaveetil
 
Investing Intelligently In The IT Function
Investing Intelligently In The IT FunctionInvesting Intelligently In The IT Function
Investing Intelligently In The IT FunctionAlan McSweeney
 
Trends in the commoditisation of information technology and the need for stra...
Trends in the commoditisation of information technology and the need for stra...Trends in the commoditisation of information technology and the need for stra...
Trends in the commoditisation of information technology and the need for stra...Alan McSweeney
 
Value Stream Mapping Process
Value Stream Mapping ProcessValue Stream Mapping Process
Value Stream Mapping ProcessAnand Subramaniam
 
Value Stream Transformation: 10 Keys to Success
Value Stream Transformation: 10 Keys to SuccessValue Stream Transformation: 10 Keys to Success
Value Stream Transformation: 10 Keys to SuccessTKMG, Inc.
 
value stream mapping and metrics based process mapping
value stream mapping and metrics based process mappingvalue stream mapping and metrics based process mapping
value stream mapping and metrics based process mappingTKMG, Inc.
 
Translating Big Raw Data Into Small Actionable Information
Translating Big Raw Data Into Small Actionable InformationTranslating Big Raw Data Into Small Actionable Information
Translating Big Raw Data Into Small Actionable InformationAlan McSweeney
 
General Motors 2005: Crisis and Way Out
General Motors 2005: Crisis and Way OutGeneral Motors 2005: Crisis and Way Out
General Motors 2005: Crisis and Way OutPiyorot Piyachan
 

Destaque (17)

LeanOps as part of Devops
LeanOps as part of DevopsLeanOps as part of Devops
LeanOps as part of Devops
 
CompatibleOne bringing cloud as a commodity
CompatibleOne bringing cloud as a commodityCompatibleOne bringing cloud as a commodity
CompatibleOne bringing cloud as a commodity
 
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017
Continuous Cost Reduction to Manage Commodity Cycles delivery version 20161017
 
1. introducción a la Ingeniería de Software (UTM 2071)
1. introducción a la Ingeniería de Software (UTM 2071)1. introducción a la Ingeniería de Software (UTM 2071)
1. introducción a la Ingeniería de Software (UTM 2071)
 
How can you measure the productivity in your company?
How can you measure the productivity in your company?How can you measure the productivity in your company?
How can you measure the productivity in your company?
 
Cloud Computing and the Datacenter of the Future
Cloud Computing and the Datacenter of the FutureCloud Computing and the Datacenter of the Future
Cloud Computing and the Datacenter of the Future
 
Corporate Risk Mngmnt-commodity Hedging
Corporate Risk Mngmnt-commodity HedgingCorporate Risk Mngmnt-commodity Hedging
Corporate Risk Mngmnt-commodity Hedging
 
Modern Software Productivity Measurement: The Pragmatic Guide
Modern Software Productivity Measurement: The Pragmatic GuideModern Software Productivity Measurement: The Pragmatic Guide
Modern Software Productivity Measurement: The Pragmatic Guide
 
Understanding and improving software productivity
Understanding and improving software productivityUnderstanding and improving software productivity
Understanding and improving software productivity
 
Investing Intelligently In The IT Function
Investing Intelligently In The IT FunctionInvesting Intelligently In The IT Function
Investing Intelligently In The IT Function
 
Trends in the commoditisation of information technology and the need for stra...
Trends in the commoditisation of information technology and the need for stra...Trends in the commoditisation of information technology and the need for stra...
Trends in the commoditisation of information technology and the need for stra...
 
Enterprise software delivery
Enterprise software deliveryEnterprise software delivery
Enterprise software delivery
 
Value Stream Mapping Process
Value Stream Mapping ProcessValue Stream Mapping Process
Value Stream Mapping Process
 
Value Stream Transformation: 10 Keys to Success
Value Stream Transformation: 10 Keys to SuccessValue Stream Transformation: 10 Keys to Success
Value Stream Transformation: 10 Keys to Success
 
value stream mapping and metrics based process mapping
value stream mapping and metrics based process mappingvalue stream mapping and metrics based process mapping
value stream mapping and metrics based process mapping
 
Translating Big Raw Data Into Small Actionable Information
Translating Big Raw Data Into Small Actionable InformationTranslating Big Raw Data Into Small Actionable Information
Translating Big Raw Data Into Small Actionable Information
 
General Motors 2005: Crisis and Way Out
General Motors 2005: Crisis and Way OutGeneral Motors 2005: Crisis and Way Out
General Motors 2005: Crisis and Way Out
 

Semelhante a Deployment presentation

Deploying on the cutting edge
Deploying on the cutting edgeDeploying on the cutting edge
Deploying on the cutting edgeericholscher
 
Red Dirt Ruby Conference
Red Dirt Ruby ConferenceRed Dirt Ruby Conference
Red Dirt Ruby ConferenceJohn Woodell
 
Puppet Development Workflow
Puppet Development WorkflowPuppet Development Workflow
Puppet Development WorkflowJeffery Smith
 
Provisioning with Puppet
Provisioning with PuppetProvisioning with Puppet
Provisioning with PuppetJoe Ray
 
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)Robert Nelson
 
Puppet At Twitter - Puppet Camp Silicon Valley
Puppet At Twitter - Puppet Camp Silicon ValleyPuppet At Twitter - Puppet Camp Silicon Valley
Puppet At Twitter - Puppet Camp Silicon ValleyPuppet
 
Frozen Rails Slides
Frozen Rails SlidesFrozen Rails Slides
Frozen Rails Slidescarllerche
 
Writing & Sharing Great Modules on the Puppet Forge
Writing & Sharing Great Modules on the Puppet ForgeWriting & Sharing Great Modules on the Puppet Forge
Writing & Sharing Great Modules on the Puppet ForgePuppet
 
Scalable Systems Management with Puppet
Scalable Systems Management with PuppetScalable Systems Management with Puppet
Scalable Systems Management with PuppetPuppet
 
Scalable systems management with puppet
Scalable systems management with puppetScalable systems management with puppet
Scalable systems management with puppetPuppet
 
Getting to push_button_deploys
Getting to push_button_deploysGetting to push_button_deploys
Getting to push_button_deploysChristian Mague
 
Puppet getting started by Dirk Götz
Puppet getting started by Dirk GötzPuppet getting started by Dirk Götz
Puppet getting started by Dirk GötzNETWAYS
 
Treat your servers like your Ruby App: Infrastructure as Code
Treat your servers like your Ruby App: Infrastructure as CodeTreat your servers like your Ruby App: Infrastructure as Code
Treat your servers like your Ruby App: Infrastructure as CodeRakuten Group, Inc.
 
Writing & Sharing Great Modules - Puppet Camp Boston
Writing & Sharing Great Modules - Puppet Camp BostonWriting & Sharing Great Modules - Puppet Camp Boston
Writing & Sharing Great Modules - Puppet Camp BostonPuppet
 
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T Puppet
 
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014Performance Tuning Your Puppet Infrastructure - PuppetConf 2014
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014Puppet
 
Getting Started with Ansible - Jake.pdf
Getting Started with Ansible - Jake.pdfGetting Started with Ansible - Jake.pdf
Getting Started with Ansible - Jake.pdfssuserd254491
 

Semelhante a Deployment presentation (20)

Deploying on the cutting edge
Deploying on the cutting edgeDeploying on the cutting edge
Deploying on the cutting edge
 
Red Dirt Ruby Conference
Red Dirt Ruby ConferenceRed Dirt Ruby Conference
Red Dirt Ruby Conference
 
Ant, Maven and Jenkins
Ant, Maven and JenkinsAnt, Maven and Jenkins
Ant, Maven and Jenkins
 
App Engine Meetup
App Engine MeetupApp Engine Meetup
App Engine Meetup
 
Puppet Development Workflow
Puppet Development WorkflowPuppet Development Workflow
Puppet Development Workflow
 
Provisioning with Puppet
Provisioning with PuppetProvisioning with Puppet
Provisioning with Puppet
 
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
Enjoying the Journey from Puppet 3.x to Puppet 4.x (PuppetConf 2016)
 
Puppet At Twitter - Puppet Camp Silicon Valley
Puppet At Twitter - Puppet Camp Silicon ValleyPuppet At Twitter - Puppet Camp Silicon Valley
Puppet At Twitter - Puppet Camp Silicon Valley
 
Frozen Rails Slides
Frozen Rails SlidesFrozen Rails Slides
Frozen Rails Slides
 
Writing & Sharing Great Modules on the Puppet Forge
Writing & Sharing Great Modules on the Puppet ForgeWriting & Sharing Great Modules on the Puppet Forge
Writing & Sharing Great Modules on the Puppet Forge
 
Scalable Systems Management with Puppet
Scalable Systems Management with PuppetScalable Systems Management with Puppet
Scalable Systems Management with Puppet
 
Scalable systems management with puppet
Scalable systems management with puppetScalable systems management with puppet
Scalable systems management with puppet
 
Getting to push_button_deploys
Getting to push_button_deploysGetting to push_button_deploys
Getting to push_button_deploys
 
Puppet getting started by Dirk Götz
Puppet getting started by Dirk GötzPuppet getting started by Dirk Götz
Puppet getting started by Dirk Götz
 
Treat your servers like your Ruby App: Infrastructure as Code
Treat your servers like your Ruby App: Infrastructure as CodeTreat your servers like your Ruby App: Infrastructure as Code
Treat your servers like your Ruby App: Infrastructure as Code
 
Writing & Sharing Great Modules - Puppet Camp Boston
Writing & Sharing Great Modules - Puppet Camp BostonWriting & Sharing Great Modules - Puppet Camp Boston
Writing & Sharing Great Modules - Puppet Camp Boston
 
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T
PuppetConf 2016: Enjoying the Journey from Puppet 3.x to 4.x – Rob Nelson, AT&T
 
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014Performance Tuning Your Puppet Infrastructure - PuppetConf 2014
Performance Tuning Your Puppet Infrastructure - PuppetConf 2014
 
Getting Started with Ansible - Jake.pdf
Getting Started with Ansible - Jake.pdfGetting Started with Ansible - Jake.pdf
Getting Started with Ansible - Jake.pdf
 
RunDeck
RunDeckRunDeck
RunDeck
 

Deployment presentation

  • 1. Deploying • Corey Purcell • @coreypurcell • Thanks to Daniel Carper Friday, June 3, 2011
  • 2. About Me Penn United Technologies We make stuff, like things you can touch! Friday, June 3, 2011
  • 3. My Environment • Oracle • All internal applications (currently) • Low traffic • Managing deployment with Moonshine Friday, June 3, 2011
  • 4. Moonshine Moonshine is an opensource configuration management and deployment system that follows the Rails way, simplifying server configuration, dependency management, and Rails application deployment, using Ruby and Puppet. Friday, June 3, 2011
  • 5. ruby script/plugin install git://github.com/railsmachine/moonshine.git ruby script/generate moonshine #Editing Moonshine.yml :ruby: ree187 :application: moonshine-test :deploy_to: /var/applications/moonshine-test :repository: git@github.com:coreypurcell/moonshine-test.git :domain: tooling.pennunited.com :shared_config: - config/database.yml Friday, June 3, 2011
  • 6. capify . #deploy.rb server "rails-box", :app, :web, :db, :primary => true cap deploy:setup cap deploy Friday, June 3, 2011
  • 7. The Good • Capistrano Based • Plugins • Puppet based • 15 minutes to build a server Friday, June 3, 2011
  • 8. The Ugly (to me) • Capistrano Based • Templates are stored in app/manifests • Slow to deploy (5-10 minutes) • Mixes deployment with server managment Friday, June 3, 2011
  • 9. Git Pusshuten A Git-based application deployment tool that allows you to define your environment by utilizing modules and provision your server with basic deployment needs Friday, June 3, 2011
  • 10. gem install gitpusshuten ten initialize #creates .gitpusshuten/ pusshuten 'Hello Git Pusshu Ten', :staging, :production do configure do |c| c.user = 'gitpusshuten' c.ip = '172.16.3.142' # c.password = 'my-password' # c.passphrase = 'my-ssh-passphrase' # c.port = '22' c.path = '/var/applications/' end modules do |m| m.add :bundler m.add :active_record m.add :passenger # m.add :nginx m.add :apache # m.add :nanoc m.add :rvm # m.add :mysql # m.add :redis end end Friday, June 3, 2011
  • 11. ten user install-root-ssh-key to staging #enter root password ten rvm install to staging # 1.9.2 ten passenger install to staging #errors!!!!!!! ten rvm install to staging ten passenger install to staging # select apache ten user add to staging #choose password Friday, June 3, 2011
  • 12. #edit vhost on your local machine, .gitpusshuten/apache/staging.vhost <VirtualHost *:80> ServerName pusshuten.local ServerAlias www.pusshuten.local DocumentRoot /var/applications/hello_git_pusshu_ten.staging/public <Directory /var/applications/hello_git_pusshu_ten.staging/public> AllowOverride all Options -MultiViews </Directory> SetEnv LD_LIBRARY_PATH /opt/oracle/instantclient_11_2 SetEnv TNS_ADMIN /opt/oracle/instantclient_11_2/network </VirtualHost> Friday, June 3, 2011
  • 13. ten push branch master to staging Done! ten active_record upload_config to staging ten apache upload-vhost to staging Friday, June 3, 2011
  • 14. Git Pusshu Ten [Aliases] gitpusshuten, heavenly, ten [Commands] active_record [Module] Active Record commands. apache [Module] Apache commands. bundler [Module] Bundler commands. delete Deletes the application of the specified environment. help Displays the command list, or the help screen for a specific command. initialize Initializes Git Pusshu Ten with the working directory. passenger [Module] Phusion Passenger commands. push Pushes a branch, tag or ref to the specified environment. remote Performs a command on the remote server for the specified environment from the application root. rvm [Module] Ruby Version Manager (RVM) commands. user Interacts with users, based on the <app_root>/.gitpusshuten/config.rb file. version Displays the current version of Git Pusshu Ten [Command Specific Help] heavenly help <command> Friday, June 3, 2011
  • 15. The Good • separation of deployment from code • deploy from any branch, ref, tag • server setup in 15-30 mins • deploys take around 30 seconds Friday, June 3, 2011
  • 16. The Ugly • Not that many modules • Not very active Friday, June 3, 2011
  • 19. Thanks • https://github.com/railsmachine/moonshine • http://gitpusshuten.com Friday, June 3, 2011
  • 20. Shameless Plug http://bit.ly/ep-runwalk 5K Run for Epilepsy Foundation - June 25 Please Donate. Friday, June 3, 2011