harbr 0.1.45 → 0.1.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/exe/harbr +5 -16
- data/lib/harbr/job.rb +2 -2
- data/lib/harbr/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e30ca645f50357661159b9fa98d2399df44ec9ee226319e3e3b282dfaffc9257
|
|
4
|
+
data.tar.gz: 312660acc631c1abef17c966c52acc7fc386f990c86dabdfddaaf304348e0b14
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8aad4ccb58ed38c42bdf5c9a6f9decd19721cd902f3fa6b24362e8148449c87aabd4a16b9352ef561ceab0b8f70b2ca53e4803908c494dbe5f33ebc47efee090
|
|
7
|
+
data.tar.gz: ed9cda3e02ecd191aac8df3a2fd883ad974ef6f9c8b91d3793507c2a965e44495b27c7d7e3da75ea7c4b9aa5de1d4a4c72043e7ccee4ecee80cddefa5d55e5d4
|
data/exe/harbr
CHANGED
|
@@ -82,25 +82,14 @@ class HarbrCLI < Thor
|
|
|
82
82
|
end
|
|
83
83
|
|
|
84
84
|
def run_jobs(container, version)
|
|
85
|
-
|
|
86
85
|
puts "Running tasks for container: #{container}, version: #{version}"
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
puts "Waiting for container #{container} manifest to be available..."
|
|
91
|
-
Dir.exist?("/var/harbr/containers/#{container}/versions/#{version}/config/manifest.yml")
|
|
92
|
-
end
|
|
93
|
-
|
|
94
|
-
Harbr::Job.perform_async(container, version,"current")
|
|
95
|
-
puts "deploy current version #{version} of #{container}"
|
|
86
|
+
if version.to_i == 0
|
|
87
|
+
Harbr::Job.perform_async(container, version, "current")
|
|
88
|
+
puts "deploy current version #{version} of #{container}"
|
|
96
89
|
else
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
puts "deploy next version #{version} of #{container}"
|
|
90
|
+
Harbr::Job.perform_async(container, version, "next")
|
|
91
|
+
puts "deploy next version #{version} of #{container}"
|
|
100
92
|
end
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
93
|
end
|
|
105
94
|
|
|
106
95
|
def create_traefik_config(containers)
|
data/lib/harbr/job.rb
CHANGED
|
@@ -99,12 +99,12 @@ module Harbr
|
|
|
99
99
|
|
|
100
100
|
def process_container(name, version, port, env, manifest)
|
|
101
101
|
env_path = "/var/harbr/containers/#{name}/#{env}"
|
|
102
|
-
system "sv stop #{env}.#{name}" if env ==
|
|
102
|
+
system "sv stop #{env}.#{name}" if env == "next"
|
|
103
103
|
|
|
104
104
|
bundle_install_if_needed(env_path)
|
|
105
105
|
create_runit_scripts(name, port, env)
|
|
106
106
|
link_directories(name, version, env)
|
|
107
|
-
sync_live_data_if_next(name) if env ==
|
|
107
|
+
sync_live_data_if_next(name) if env == "next"
|
|
108
108
|
|
|
109
109
|
containers = collate_containers("#{env}.#{name}", "#{env}.#{manifest.host}", port)
|
|
110
110
|
create_traefik_config(containers)
|
data/lib/harbr/version.rb
CHANGED