lib/harbr/next/job.rb in harbr-0.1.28 vs lib/harbr/next/job.rb in harbr-0.1.29

- old
+ new

@@ -162,20 +162,22 @@ manifest_data = YAML.load_file(manifest_path) OpenStruct.new(manifest_data) end def perform(name, version) - `bundle config set --local path 'vendor/bundle'` - + manifest = load_manifest(name, version) current_path = "/var/harbr/containers/#{name}/versions/#{version}" port = `port assign next.#{manifest.port}`.strip Dir.chdir current_path do system "sv stop next.#{name}" - system "bundle install" if File.exist?("Gemfile") + if File.exist?("Gemfile") + `bundle config set --local path 'vendor/bundle'` + system "bundle install" + end `mkdir -p /etc/sv/harbr/#{name}/next` `mkdir -p /etc/sv/harbr/#{name}/next/log` `mkdir -p /var/log/harbr/#{name}/next/log` @@ -200,11 +202,10 @@ system "sv restart next.#{name}" end containers = collate_containers("next.#{name}", "next.#{manifest.host}", port) create_traefik_config(containers) - - puts "process #{version} of #{name}" + puts "harbr: #{version} of #{name}" end end end end