Skip to content

Commit

Permalink
fix merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
Stat Turlo committed Aug 22, 2012
2 parents 1153256 + 28d998b commit b971075
Show file tree
Hide file tree
Showing 40 changed files with 75 additions and 202 deletions.
7 changes: 6 additions & 1 deletion Gemfile
@@ -1,9 +1,11 @@
source 'http://s3.amazonaws.com/rightscale_rightlink_gems_dev'
source :rubygems

gemspec

gem "rubyforge", "1.0.4"
gem "rake", "0.8.7"
gem "encryptor", "1.1.3"

gem "right_support", :git => 'git://github.com/rightscale/right_support.git',
:branch => "master"
gem "right_agent", :git => 'git://github.com/rightscale/right_agent.git',
Expand Down Expand Up @@ -32,6 +34,9 @@ end
# DO NOT CHANGE VERSIONS of these gems until you have built a precompiled
# mswin-platform gem for every one of the gems below AND published it to
# the rightscale custom gem repository.
#
# TODO figure out how to encode these into the gemspec ... very hard to do plat-specific gem dependencies!
# @see http://stackoverflow.com/questions/4596606/rubygems-how-do-i-add-platform-specific-dependency
group :not_windows_friendly do
gem "json", "1.4.6"

Expand Down
17 changes: 13 additions & 4 deletions Gemfile.lock
Expand Up @@ -28,6 +28,18 @@ GIT
specs:
right_support (2.3.1)

PATH
remote: .
specs:
right_link (5.9.0)
chef (>= 0.10.10)
encryptor (~> 1.1)
right_agent (~> 0.10)
right_http_connection (~> 1.3)
right_popen (~> 1.0)
right_scraper (~> 3.0)
right_support (~> 2.0)

GEM
remote: http://s3.amazonaws.com/rightscale_rightlink_gems_dev/
remote: http://rubygems.org/
Expand Down Expand Up @@ -173,7 +185,6 @@ DEPENDENCIES
abstract (= 1.0.0)
bunny (= 0.6.0)
chef (= 0.10.10.2)
encryptor (= 1.1.3)
erubis (= 2.6.5)
eventmachine (= 0.12.11.6)
extlib (= 0.9.14)
Expand All @@ -194,9 +205,7 @@ DEPENDENCIES
rest-client (= 1.6.7)
right_agent!
right_amqp!
right_http_connection (~> 1.3)
right_popen (~> 1.0)
right_scraper (= 3.0.1)
right_link!
right_support!
rspec (~> 1.3)
ruby-debug
Expand Down
3 changes: 1 addition & 2 deletions INSTALL.rdoc
Expand Up @@ -218,7 +218,7 @@ and relaunching.

=== Configure RightLink Agent

bin/enroll --root-dir /opt/rightscale/right_link --url $RS_RN_URL --host $RS_RN_HOST --id $RS_RN_ID --token $RS_RN_AUTH
bin/enroll --root-dir /var/lib/rightscale/right_link --url $RS_RN_URL --host $RS_RN_HOST --id $RS_RN_ID --token $RS_RN_AUTH
bin/deploy

=== Launch RightLink Agent
Expand Down Expand Up @@ -255,7 +255,6 @@ When the system is terminating, you should allow RightLink to run its decommissi
/usr/bin | Public CLI: rs_tag, rs_debug, ...
/opt/rightscale/bin | Private CLI: rnac, rad, cook, ...
/opt/rightscale/sandbox | Private sandbox (Ruby, RubyGems, monit, ...)
/opt/rightscale/right_link | Application logic & support files

=== Windows Systems

Expand Down
9 changes: 9 additions & 0 deletions Rakefile
@@ -1,6 +1,8 @@
# Activate gem dependencies
require 'rubygems'
require 'bundler/setup'
require 'rubygems/package_task'
require 'rake/clean'

# Ruby standard library dependencies
require 'fileutils'
Expand All @@ -15,6 +17,13 @@ require File.join(RIGHT_LINK_ROOT, 'lib', 'run_shell')

include RunShell

desc "Build right_link gem"
Gem::PackageTask.new(Gem::Specification.load("right_link.gemspec")) do |package|
package.need_zip = true
package.need_tar = true
end

CLEAN.include('pkg')

def windows?
return !!(RUBY_PLATFORM =~ /mswin/)
Expand Down
0 bin/cloud.rb → bin/cloud 100644 → 100755
File renamed without changes.
File renamed without changes.
8 changes: 6 additions & 2 deletions bin/deploy.rb → bin/deploy 100644 → 100755
Expand Up @@ -84,8 +84,12 @@ def invoke_rad
host = "#{url.host}#{host}"
end

os_root_dir = '/var/lib/rightscale/right_link'
gem_root_dir = Dir.glob(File.join(AgentConfig.parent_dir, 'right_link-*')).sort.first

cmd_opts = [ 'instance',
'-r', File.join(AgentConfig.parent_dir, 'right_link'),
'-r', os_root_dir,
'-r', gem_root_dir,
'-i', ENV['RS_RN_ID'],
'-t', ENV['RS_RN_AUTH'],
'-h', host,
Expand Down Expand Up @@ -121,4 +125,4 @@ def invoke_rad
# The $0 argument is -e in windows because of how we wrap the call to get live
# console output. we don't need to worry about symlinks in Windows, so always
# run the deployer on that platform
RightScale::AgentDeployerRunner.run if (__FILE__ == $0 || RightScale::Platform.windows?)
RightScale::AgentDeployerRunner.run
0 bin/enroll.rb → bin/enroll 100644 → 100755
File renamed without changes.
0 bin/rad.rb → bin/rad 100644 → 100755
File renamed without changes.
0 bin/rchk.rb → bin/rchk 100644 → 100755
File renamed without changes.
0 bin/rnac.rb → bin/rnac 100644 → 100755
File renamed without changes.
File renamed without changes.
File renamed without changes.
0 bin/rs_ohai.rb → bin/rs_ohai 100644 → 100755
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
0 bin/rs_tag.rb → bin/rs_tag 100644 → 100755
File renamed without changes.
0 bin/rs_thunk.rb → bin/rs_thunk 100644 → 100755
File renamed without changes.
0 bin/rstat.rb → bin/rstat 100644 → 100755
File renamed without changes.
168 changes: 0 additions & 168 deletions bin/setup.sh

This file was deleted.

0 bin/system.rb → bin/system 100644 → 100755
File renamed without changes.
2 changes: 1 addition & 1 deletion lib/clouds/clouds/ec2.rb
Expand Up @@ -34,7 +34,7 @@
# Assembles the command line needed to regenerate cloud metadata on demand.
def cloud_metadata_generation_command
ruby_path = File.normalize_path(AgentConfig.sandbox_ruby_cmd)
rs_cloud_path = File.normalize_path(File.join(AgentConfig.parent_dir, 'right_link', 'bin', 'cloud.rb'))
rs_cloud_path = File.normalize_path(File.join(AgentConfig.parent_dir, 'right_link', 'bin', 'cloud'))
return "#{ruby_path} #{rs_cloud_path} --quiet --action write_cloud_metadata"
end

Expand Down
4 changes: 3 additions & 1 deletion lib/gem_dependencies.rb
Expand Up @@ -21,7 +21,7 @@

require 'rubygems'

# N.B. we can't use File#normalize_path yet because gems haven't been activated
# N.B. we can't use File#normalize_path yet because gems haven't been activated - Windows safety!
basedir = File.expand_path(File.join(File.dirname(__FILE__), '..'))
Dir.chdir(basedir) do
if File.exist?('Gemfile')
Expand All @@ -36,6 +36,8 @@
end
end

gem 'right_link'

gem 'eventmachine'

gem 'right_support'
Expand Down
2 changes: 1 addition & 1 deletion lib/instance/executable_sequence_proxy.rb
Expand Up @@ -155,7 +155,7 @@ def run
# === Return
# path(String):: Path to ruby script used to run Chef
def cook_path
relative_path = File.join(File.dirname(__FILE__), '..', '..', 'bin', 'cook_runner.rb')
relative_path = File.join(File.dirname(__FILE__), '..', '..', 'bin', 'cook_runner')
return File.normalize_path(relative_path)
end

Expand Down
31 changes: 22 additions & 9 deletions right_link.gemspec
@@ -1,26 +1,39 @@
# -*- mode: ruby; encoding: utf-8 -*-

Gem::Specification.new do |s|
s.name = "right_link"
s.version = '0.3'
require 'rubygems'

spec = Gem::Specification.new do |s|
s.name = 'right_link'
s.version = '5.9.0'
s.platform = Gem::Platform::RUBY

s.authors = ['RightScale']
s.email = 'support@rightscale.com'
s.homepage = 'https://github.com/rightscale/right_link'
s.summary = %q{Reusable foundation code.}
s.description = %q{A toolkit of useful, reusable foundation code created by RightScale.}

s.required_rubygems_version = ">= 1.3.7"

s.summary = %q{RightScale management agent.}
s.description = %q{A daemon that connects systems to the RightScale cloud management platform.}

s.required_rubygems_version = '>= 1.3.7'

s.add_runtime_dependency('right_agent', ['~> 0.10'])
s.add_runtime_dependency('right_scraper', ['~> 3.0'])
s.add_runtime_dependency('right_popen', ['~> 1.0'])
s.add_runtime_dependency('right_http_connection', ['~> 1.3'])
s.add_runtime_dependency('right_support', ['~> 2.0'])

s.add_runtime_dependency('chef', ['>= 0.10.10'])
s.add_runtime_dependency('encryptor', ['~> 1.1'])

s.files = Dir.glob('Gemfile') +
Dir.glob('Gemfile.lock') +
Dir.glob('init/*') +
Dir.glob('actors/*.rb') +
Dir.glob('bin/*.rb') +
Dir.glob('bin/*.sh') +
Dir.glob('bin/*') +
Dir.glob('lib/**/*.rb') +
Dir.glob('lib/**/*.pub') +
Dir.glob('scripts/*') +
Dir.glob('lib/instance/cook/*.crt')

s.executables = Dir.glob('bin/*').map { |f| File.basename(f) }
end
2 changes: 1 addition & 1 deletion scripts/windows/rad.cmd
Expand Up @@ -27,4 +27,4 @@ if %ERRORLEVEL% neq 0 (
exit /B %ERRORLEVEL%
)

%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rad.rb %*
%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rad %*
2 changes: 1 addition & 1 deletion scripts/windows/rchk.cmd
Expand Up @@ -27,4 +27,4 @@ if %ERRORLEVEL% neq 0 (
exit /B %ERRORLEVEL%
)

%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rchk.rb %*
%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rchk %*
2 changes: 1 addition & 1 deletion scripts/windows/rnac.cmd
Expand Up @@ -27,4 +27,4 @@ if %ERRORLEVEL% neq 0 (
exit /B %ERRORLEVEL%
)

%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rnac.rb %*
%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rnac %*
2 changes: 1 addition & 1 deletion scripts/windows/rs_connect.cmd
Expand Up @@ -37,4 +37,4 @@ if %ERRORLEVEL% neq 0 (
)

rem # connect
%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rs_connect.rb %*
%RS_RUBY_EXE% %RS_RIGHT_LINK_HOME%\right_link\bin\rs_connect %*

0 comments on commit b971075

Please sign in to comment.