ey-deploy 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -103,12 +103,12 @@ module EY
103
103
  when "nginx_unicorn"
104
104
  pidfile = "/var/run/engineyard/unicorn_#{c.app}.pid"
105
105
  condition = "[ -e #{pidfile} ] && [ ! -d /proc/`cat #{pidfile}` ]"
106
- sudo("if #{condition}; then rm -f #{pidfile}; fi")
107
- sudo("/etc/init.d/unicorn_#{c.app} deploy")
106
+ run("if #{condition}; then rm -f #{pidfile}; fi")
107
+ run("/engineyard/bin/app_#{c.app} deploy")
108
108
  when "nginx_mongrel"
109
109
  sudo("monit restart all -g #{c.app}")
110
110
  when "nginx_passenger"
111
- sudo("touch #{c.current_path}/tmp/restart.txt")
111
+ run("touch #{c.current_path}/tmp/restart.txt")
112
112
  else
113
113
  raise "Unknown stack #{c.stack}; restart failed!"
114
114
  end
@@ -126,7 +126,7 @@ module EY
126
126
  get_bundler_installer(lockfile)
127
127
  else
128
128
  warn_about_missing_lockfile
129
- DEFAULT_09_BUNDLER
129
+ BundleInstaller.new(DEFAULT_09_BUNDLER, "--without=development --without=test")
130
130
  end
131
131
 
132
132
  sudo "#{$0} _#{VERSION}_ install_bundler #{bundler_installer.version}"
@@ -176,7 +176,7 @@ module EY
176
176
  # task
177
177
  def copy_repository_cache
178
178
  info "~> Copying to #{c.release_path}"
179
- sudo("mkdir -p #{c.release_path} && rsync -aq #{c.exclusions} #{c.repository_cache}/ #{c.release_path}")
179
+ run("mkdir -p #{c.release_path} && rsync -aq #{c.exclusions} #{c.repository_cache}/ #{c.release_path}")
180
180
 
181
181
  info "~> Ensuring proper ownership"
182
182
  sudo("chown -R #{c.user}:#{c.group} #{c.deploy_to}")
@@ -198,18 +198,18 @@ module EY
198
198
  "ln -nfs #{c.shared_path}/pids #{release_to_link}/tmp/pids",
199
199
  "ln -nfs #{c.shared_path}/config/database.yml #{release_to_link}/config/database.yml",
200
200
  "ln -nfs #{c.shared_path}/config/mongrel_cluster.yml #{release_to_link}/config/mongrel_cluster.yml",
201
- "chown -R #{c.user}:#{c.group} #{release_to_link}",
202
- "if [ -f \"#{c.shared_path}/config/newrelic.yml\" ]; then ln -nfs #{c.shared_path}/config/newrelic.yml #{release_to_link}/config/newrelic.yml; fi",
203
-
204
201
  ].each do |cmd|
205
- sudo cmd
202
+ run cmd
206
203
  end
204
+
205
+ sudo "chown -R #{c.user}:#{c.group} #{release_to_link}"
206
+ run "if [ -f \"#{c.shared_path}/config/newrelic.yml\" ]; then ln -nfs #{c.shared_path}/config/newrelic.yml #{release_to_link}/config/newrelic.yml; fi"
207
207
  end
208
208
 
209
209
  # task
210
210
  def symlink(release_to_link=c.release_path)
211
211
  info "~> Symlinking code"
212
- sudo "rm -f #{c.current_path} && ln -nfs #{release_to_link} #{c.current_path} && chown -R #{c.user}:#{c.group} #{c.current_path}"
212
+ run "rm -f #{c.current_path} && ln -nfs #{release_to_link} #{c.current_path} && chown -R #{c.user}:#{c.group} #{c.current_path}"
213
213
  @symlink_changed = true
214
214
  rescue Exception
215
215
  sudo "rm -f #{c.current_path} && ln -nfs #{c.previous_release(release_to_link)} #{c.current_path} && chown -R #{c.user}:#{c.group} #{c.current_path}"
@@ -1,3 +1,3 @@
1
1
  module EY
2
- VERSION = '1.1.2'
2
+ VERSION = '1.1.3'
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ey-deploy
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 2
10
- version: 1.1.2
9
+ - 3
10
+ version: 1.1.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - EY Cloud Team
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-08-11 00:00:00 -07:00
18
+ date: 2010-08-13 00:00:00 -07:00
19
19
  default_executable: ey-deploy
20
20
  dependencies: []
21
21