Skip to content
This repository was archived by the owner on Oct 21, 2021. It is now read-only.

Get the deploy nodes for capistrano from cobbler based upon the management class

Notifications You must be signed in to change notification settings

proffalken/capistrano-cobbler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CapistranoCobbler

This recipe for cobbler enables you to use the management classes in cobbler to automatically determine the nodes you will deploy your code to.

Installation is simple:

  • Copy capistranoCobbler.rb from 'lib' to the config directory in your pre-capified project
  • Update your CapFile as follows:
    set :mgmt_class, "www"    
    set :mgmt_server, "localhost"
  • Update config/deploy.rb (or the appropriate staging file!) with the following:
    load 'config/capistranoCobbler'  
    capcob = CapistranoCobbler.new(mgmt_class,cobbler_server=mgmt_server)  
    role(:web) do  
        capcob.get_servers  
    end
  • Run capistrano as you usually would.

NB: This assumes that you are deploying to a single server. If you wanted to deplot to multiple servers, simply create additional connections and execute them as part of a "role" block:

    # deploy.rb
    load 'config/capistranoCobbler'
    dbcc = CapistranoCobbler.new('database_servers','cobbler')
    webcc = CapistranoCobbler.new('web_servers','cobbler')
    appcc = CapistranoCobbler.new('app_servers','cobbler')

    role(:db) do
       dbcc.get_servers
    end
    role(:web) do
	webcc.get_servers
    end
    role(:app) do
	appcc.get_servers
    end

Please log tickets as necessary in github.

About

Get the deploy nodes for capistrano from cobbler based upon the management class

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages