harbr 0.0.80 → 0.0.82

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: faf169d8747490a5212c404ba4ae0ccf82009544bb5d0b6b0e888d425cba64a4
4
- data.tar.gz: 35b2f2767321282d31d24bd37b6e6d811c235dde939eed1c50e4ae2fad8e3f98
3
+ metadata.gz: d1e6917d2f26c5e1bbecbccf6fae440750a6aa6122add836527318cd4dd76d30
4
+ data.tar.gz: 72a41fc3e526b57ce6fa029b0fd46a6821c6608f880f070971a0092038666c3f
5
5
  SHA512:
6
- metadata.gz: d61e0272279a4c362d282771e0b155022b47dc40ef514a760b51e4d5c90e1785891e02e806da5261c1845d411d5a5ab8abce4e2bf5af24ee6b7db6fc6aef8a3d
7
- data.tar.gz: cedb23c1d39e632d24d4cfbeb377474a763b5bfdcc2d7430ee49c120c672fb70e6704d954f8bf724b506289f051fd3f30a842f887db326156f52712c083a1feb
6
+ metadata.gz: f7010e30a615b6b876630875744c3b56f4aafceb31506c86ff20e9a07c1593d75fd5e4ad07cce0543ae1c068aafccc9db3848572a50a0ad5db7d1b9f15c684ed
7
+ data.tar.gz: 5ce94ff7548ccd37336bf2626499810d9fde3b581df7bcf2fa54d372d7e4a1748337021eeb5c12aa7e447cfff809ad666e371edd40a34233cc03f662db6d8094
data/lib/harbr/job.rb CHANGED
@@ -12,21 +12,7 @@ module Harbr
12
12
  File.basename(path)
13
13
  end
14
14
 
15
- def check_container_version(name, version)
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" => {
@@ -181,7 +167,7 @@ module Harbr
181
167
  Dir.chdir "/var/harbr/containers/#{name}/versions/#{version}" do
182
168
  `bundle config set --local path 'vendor/bundle'`
183
169
  manifest = load_manifest(name, version)
184
- port = `port assign next.#{manifest.port}`.strip
170
+ port = `port assign #{manifest.port}`.strip
185
171
  system "sv stop #{name}"
186
172
  system 'bundle install'
187
173
  `mkdir -p /etc/sv/harbr/#{name}`
@@ -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
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Harbr
4
- VERSION = "0.0.80"
4
+ VERSION = "0.0.82"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: harbr
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.80
4
+ version: 0.0.82
5
5
  platform: ruby
6
6
  authors:
7
7
  - Delaney Kuldvee Burke