harbr 0.0.80 → 0.0.81
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/lib/harbr/job.rb +1 -15
- data/lib/harbr/next/job.rb +1 -20
- 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: 3b35165cb2f91631af1af3f62bb4d32308d0ca1ca10b1325e984cb77d5685bc5
|
4
|
+
data.tar.gz: cd1214d2cf6c2ecb58592e90bc6de7f5e762f9b5a33da318549186ebbd9e5d7e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d9b79e33d8fc19698fc6b11b10c0e0f2796d709c9fdf4f7d41cfc1eeb8fc3430b47d90cd998bcbe73856dc7d63a6969488d7ec7a7c39814800a69ecaecc954d7
|
7
|
+
data.tar.gz: 682ebf832dc4649f42e60f1cc128df9dd1903ee6c2e435d125754f1026ac3c918d15fba1c2ac75d38811c7116e3928043c807163a6e4f4f4fea32e7945af702b
|
data/lib/harbr/job.rb
CHANGED
@@ -12,21 +12,7 @@ module Harbr
|
|
12
12
|
File.basename(path)
|
13
13
|
end
|
14
14
|
|
15
|
-
|
16
|
-
file_path = '/var/harbr/.data/processed_next.txt' # replace with your file path
|
17
|
-
`touch #{file_path}`
|
18
|
-
container_version = "#{name},#{version}"
|
19
|
-
|
20
|
-
File.open(file_path, 'r') do |file|
|
21
|
-
if file.any? { |line| line.chomp == container_version }
|
22
|
-
puts 'containerised'
|
23
|
-
else
|
24
|
-
result = yield name, version
|
25
|
-
File.write(file_path, "#{container_version}\n", mode: 'a') unless result == false
|
26
|
-
end
|
27
|
-
end
|
28
|
-
end
|
29
|
-
|
15
|
+
|
30
16
|
def create_traefik_config(containers)
|
31
17
|
config = {
|
32
18
|
"http" => {
|
data/lib/harbr/next/job.rb
CHANGED
@@ -17,20 +17,6 @@ module Harbr
|
|
17
17
|
File.basename(path)
|
18
18
|
end
|
19
19
|
|
20
|
-
def check_container_version(name, version)
|
21
|
-
file_path = '/var/harbr/.data/processed_next.txt' # replace with your file path
|
22
|
-
`touch #{file_path}`
|
23
|
-
container_version = "#{name},#{version}"
|
24
|
-
|
25
|
-
File.open(file_path, 'r') do |file|
|
26
|
-
if file.any? { |line| line.chomp == container_version }
|
27
|
-
puts 'containerised'
|
28
|
-
else
|
29
|
-
result = yield name, version
|
30
|
-
File.write(file_path, "#{container_version}\n", mode: 'a') unless result == false
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
20
|
|
35
21
|
def create_traefik_config(containers)
|
36
22
|
config = {
|
@@ -184,12 +170,7 @@ module Harbr
|
|
184
170
|
|
185
171
|
def perform(name, version)
|
186
172
|
`bundle config set --local path 'vendor/bundle'`
|
187
|
-
|
188
|
-
container_path = "/var/harbr/containers/#{name}/versions/#{version}"
|
189
|
-
latest_version = highest_numbered_directory("#{container_path}/versions")
|
190
|
-
|
191
|
-
version = get_container_name(latest_version)
|
192
|
-
name = get_container_name(container_path)
|
173
|
+
|
193
174
|
manifest = load_manifest(name,version)
|
194
175
|
current_path = "/var/harbr/containers/#{name}/versions/#{version}"
|
195
176
|
|
data/lib/harbr/version.rb
CHANGED