Skip to content

Instantly share code, notes, and snippets.

@bklang
Created July 21, 2014 22:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bklang/288c58cfe67aba7f296a to your computer and use it in GitHub Desktop.
Save bklang/288c58cfe67aba7f296a to your computer and use it in GitHub Desktop.
- force ownership of /srv/pe to pe:pe * application_nginx_nginx_load_balancer[pe] action before_restart (up to date)
Recipe: <Dynamically Defined Resource>
* rbenv_execute[app_ahn_dependencies] action run
* execute[eval "$(rbenv init -)"] action run
- execute eval "$(rbenv init -)"
* execute[app_ahn_dependencies] action run
================================================================================
Error executing action `run` on resource 'execute[app_ahn_dependencies]'
================================================================================
Mixlib::ShellOut::ShellCommandFailed
------------------------------------
Expected process to exit with [0], but received '7'
---- Begin output of bundle install --deployment --path vendor/ruby ----
STDOUT: Some gems seem to be missing from your vendor/cache directory.
Could not find slop-3.6.0 in any of the sources
STDERR:
---- End output of bundle install --deployment --path vendor/ruby ----
Ran bundle install --deployment --path vendor/ruby returned 7
Cookbook Trace:
---------------
/var/chef/cache/cookbooks/application/libraries/default.rb:189:in `safe_recipe_eval'
/var/chef/cache/cookbooks/application/libraries/default.rb:165:in `callback'
/var/chef/cache/cookbooks/application/providers/default.rb:182:in `run_actions_with_context'
/var/chef/cache/cookbooks/application/providers/default.rb:167:in `block (2 levels) in run_deploy'
Resource Declaration:
---------------------
# In /var/chef/cache/cookbooks/rbenv/providers/execute.rb
25: execute new_resource.name do
26: command new_resource.command
27: creates new_resource.creates
28: cwd new_resource.cwd
29: environment new_resource.environment
30: group new_resource.group
31: returns new_resource.returns
32: timeout new_resource.timeout
33: user new_resource.user
34: umask new_resource.umask
35: end
36:
Compiled Resource:
------------------
# Declared in /var/chef/cache/cookbooks/rbenv/providers/execute.rb:25:in `block in class_from_file'
execute("app_ahn_dependencies") do
action "run"
retries 0
retry_delay 2
command "bundle install --deployment --path vendor/ruby"
backup 5
cwd "/srv/pe/current/ahn"
environment {"PATH"=>"/opt/rbenv/shims:/opt/rbenv/bin:/opt/rbenv/shims:/opt/rbenv/bin:/opt/rbenv/plugins/ruby_build/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/bklang/bin:/opt/chef/embedded/bin:/opt/chef/embedded/bin", "RBENV_ROOT"=>"/opt/rbenv"}
returns 0
user "pe"
cookbook_name "psychic_elements_telephony"
end
[2014-07-21T18:30:13-04:00] WARN: Error on deploying /srv/pe/releases/0b7f3e20810aea7effab3e60db1dedf89a9060e7: execute[app_ahn_dependencies] (/var/chef/cache/cookbooks/rbenv/providers/execute.rb line 25) had an error: Mixlib::ShellOut::ShellCommandFailed: Expected process to exit with [0], but received '7'
---- Begin output of bundle install --deployment --path vendor/ruby ----
STDOUT: Some gems seem to be missing from your vendor/cache directory.
Could not find slop-3.6.0 in any of the sources
STDERR:
---- End output of bundle install --deployment --path vendor/ruby ----
Ran bundle install --deployment --path vendor/ruby returned 7
- purge directories in checkout
================================================================================
Error executing action `deploy` on resource 'deploy_revision[pe]'
================================================================================
Chef::Exceptions::FileNotFound
------------------------------
Cannot symlink shared data /srv/pe/shared/ahn/vendor/ruby to /srv/pe/releases/0b7f3e20810aea7effab3e60db1dedf89a9060e7/ahn/vendor/ruby: File exists - (/srv/pe/shared/ahn/vendor/ruby, /srv/pe/releases/0b7f3e20810aea7effab3e60db1dedf89a9060e7/ahn/vendor/ruby/ruby)
Resource Declaration:
---------------------
# In /var/chef/cache/cookbooks/application/providers/default.rb
123: @deploy_resource = send(new_resource.strategy.to_sym, new_resource.name) do
124: action force ? :force_deploy : :deploy
125: scm_provider new_resource.scm_provider
126: revision new_resource.revision
127: repository new_resource.repository
128: enable_submodules new_resource.enable_submodules
129: user new_resource.owner
130: group new_resource.group
131: deploy_to new_resource.path
132: ssh_wrapper "#{new_resource.path}/deploy-ssh-wrapper" if new_resource.deploy_key
133: shallow_clone new_resource.shallow_clone
134: rollback_on_error new_resource.rollback_on_error
135: all_environments = ([new_resource.environment]+new_resource.sub_resources.map{|res| res.environment}).inject({}){|acc, val| acc.merge(val)}
136: environment all_environments
137: migrate new_resource.migrate
138: all_migration_commands = ([new_resource.migration_command]+new_resource.sub_resources.map{|res| res.migration_command}).select{|cmd| cmd && !cmd.empty?}
139: migration_command all_migration_commands.join(' && ')
140: restart_command do
141: ([new_resource]+new_resource.sub_resources).each do |res|
142: cmd = res.restart_command
143: if cmd.is_a? Proc
144: app_provider.deploy_provider.instance_eval(&cmd) # @see libraries/default.rb
145: elsif cmd && !cmd.empty?
146: execute cmd do
147: user new_resource.owner
148: group new_resource.group
149: environment all_environments
150: end
151: end
152: end
153: end
154: purge_before_symlink (new_resource.purge_before_symlink + new_resource.sub_resources.map(&:purge_before_symlink)).flatten
Compiled Resource:
------------------
# Declared in /var/chef/cache/cookbooks/application/providers/default.rb:123:in `run_deploy'
deploy_revision("pe") do
provider Chef::Provider::Deploy::Revision
action [:deploy]
retries 0
retry_delay 2
deploy_to "/srv/pe"
repository_cache "cached-copy"
symlinks {"ahn/vendor/ruby"=>"ahn/vendor/ruby", "polycom"=>"polycom"}
revision "master"
rollback_on_error true
remote "origin"
shallow_clone true
scm_provider Chef::Provider::Git
keep_releases 5
enable_checkout true
checkout_branch "deploy"
cookbook_name "psychic_elements_telephony"
repo "git@github.com:mojolingo/psychic_elements_telephony.git"
user "pe"
group "pe"
git_ssh_wrapper "/srv/pe/deploy-ssh-wrapper"
restart_command #<Proc:0x00000005628130@/var/chef/cache/cookbooks/application/providers/default.rb:140>
before_migrate #<Proc:0x00000005626588@/var/chef/cache/cookbooks/application/providers/default.rb:160>
before_symlink #<Proc:0x00000005626380@/var/chef/cache/cookbooks/application/providers/default.rb:163>
before_restart #<Proc:0x00000005626178@/var/chef/cache/cookbooks/application/providers/default.rb:166>
after_restart #<Proc:0x00000005625f98@/var/chef/cache/cookbooks/application/providers/default.rb:169>
shared_path "/srv/pe/shared"
destination "/srv/pe/shared/cached-copy"
current_path "/srv/pe/current"
end
Recipe: iptables-ng::manage
* ruby_block[create_rules] action createRecipe: <Dynamically Defined Resource>
* file[/etc/iptables/rules.v4] action create (up to date)
* file[/etc/iptables/rules.v6] action create (up to date)
- execute the ruby block create_rules
Recipe: iptables-ng::manage
* ruby_block[restart_iptables] action createRecipe: <Dynamically Defined Resource>
* service[iptables-persistent] action enable (up to date)
* service[iptables-persistent] action restart
- restart service service[iptables-persistent]
- execute the ruby block restart_iptables
Recipe: nginx::default
* service[nginx] action reload
- reload service service[nginx]
Running handlers:
[2014-07-21T18:30:13-04:00] ERROR: Running exception handlers
Running handlers complete
[2014-07-21T18:30:13-04:00] ERROR: Exception handlers complete
[2014-07-21T18:30:13-04:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
Chef Client failed. 48 resources updated in 28.651923412 seconds
[2014-07-21T18:30:14-04:00] ERROR: deploy_revision[pe] (/var/chef/cache/cookbooks/application/providers/default.rb line 123) had an error: Chef::Exceptions::FileNotFound: Cannot symlink shared data /srv/pe/shared/ahn/vendor/ruby to /srv/pe/releases/0b7f3e20810aea7effab3e60db1dedf89a9060e7/ahn/vendor/ruby: File exists - (/srv/pe/shared/ahn/vendor/ruby, /srv/pe/releases/0b7f3e20810aea7effab3e60db1dedf89a9060e7/ahn/vendor/ruby/ruby)
[2014-07-21T18:30:14-04:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment