Sha256: d8104b18e178a0f77d670d6a7ab3e44978c6b085b1f2c76b086bc1ad1822b614
Contents?: true
Size: 1.15 KB
Versions: 2
Compression:
Stored size: 1.15 KB
Contents
require 'securerandom' require_relative 'services/init' require_relative 'services/mongodb' require_relative 'services/mysql' module DanarchyDeploy module Services def self.new(deployment, options) return deployment if ! deployment[:services] puts "\n" + self.name deployment[:services].each do |service, params| next if service == :init puts "\nConfiguring service: #{service}" if params[:archives] && !params[:archives].empty? puts "\n" + self.name puts " > Deploying archives for #{service}" DanarchyDeploy::Archiver.new(params[:archives], options) end if params[:templates] && !params[:templates].empty? puts " > Configuring templates for #{service}" DanarchyDeploy::Templater.new(params[:templates], options) end if %w[mysql mariadb].include?(service.to_s) DanarchyDeploy::Services::MySQL.new(deployment[:os], params, options) end if %[mongodb].include?(service.to_s) DanarchyDeploy::Services::MongoDB.new(deployment[:os], params, options) end end deployment end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
danarchy_deploy-0.2.7 | lib/danarchy_deploy/services.rb |
danarchy_deploy-0.2.6 | lib/danarchy_deploy/services.rb |