dapp 0.31.3 → 0.31.4

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: 1afd2b369ed8ab7aa8911fdc85cc152490ac4824dee599a4d9c4703124c69646
4
- data.tar.gz: 524410a1caa1e9cb74c94b4ae054d707b7d08e5a5e17b0823d3856c9f5e9f259
3
+ metadata.gz: 92cbd45585608c2b3424c4db1e59b504beb8c1c90eced82f7b27a70eba995e3e
4
+ data.tar.gz: 8e5c680b2a63f6cf7869f72c35efac3dc19f32bce3afddfe64f13f2f96614563
5
5
  SHA512:
6
- metadata.gz: 9e070869ffeee6790917554c796927136316862a47eec701cc445b3bc0aa77a6be3d6c5d5620a3a83221de4bc8216e7d6bb9ba30f1d0f96495bf6d8a1ff7c2fc
7
- data.tar.gz: 2b0a31e22ffa7135ae2edeb63c2400bce67eb38667f1c878ab42ecfd5bc91f545ffe855e1853eb234bb800c616a4a44c4ce223250a434b33d9810aed81313bfd
6
+ metadata.gz: 0d307250a9a3cd29bc80528213685b55bed30cd4bd35c6925a78e8cd2187d3c4bebf00865d33acccf3240f834dd4eaf46baae408f0ba4c348a01aaf5cc167aa5
7
+ data.tar.gz: fff8cc2b739262c7f14a7684d56824295d9b4e4e99597d80450b7a6382cf4aaf8b64dba3802979a5807e1ddbd69cf0bda38753ebf39ba5f95a85b2efc8d33938
@@ -23,7 +23,6 @@ module Dapp
23
23
  @artifacts ||= begin
24
24
  dimg.config.public_send("_#{name}").map do |artifact|
25
25
  artifact_dimg = dimg.dapp.artifact_dimg(config: artifact._config,
26
- ignore_git_fetch: dimg.ignore_git_fetch,
27
26
  ignore_signature_auto_calculation: dimg.ignore_signature_auto_calculation)
28
27
  { options: artifact._artifact_options, dimg: artifact_dimg }
29
28
  end
@@ -26,9 +26,9 @@ module Dapp
26
26
  def from_dimg
27
27
  @from_dimg ||= begin
28
28
  if !dimg.config._from_dimg.nil?
29
- dimg.dapp.dimg_layer(config: dimg.config._from_dimg, ignore_git_fetch: dimg.ignore_git_fetch)
29
+ dimg.dapp.dimg_layer(config: dimg.config._from_dimg)
30
30
  elsif !dimg.config._from_dimg_artifact.nil?
31
- dimg.dapp.artifact_dimg_layer(config: dimg.config._from_dimg_artifact, ignore_git_fetch: dimg.ignore_git_fetch)
31
+ dimg.dapp.artifact_dimg_layer(config: dimg.config._from_dimg_artifact)
32
32
  end
33
33
  end
34
34
  end
@@ -14,7 +14,7 @@ module Dapp
14
14
  def export_build_context_image_tar
15
15
  lock("#{name}.images", readonly: true) do
16
16
  context_images_names = build_configs.map do |config|
17
- dimg(config: config, ignore_git_fetch: true).all_tagged_images.map(&:name)
17
+ dimg(config: config).all_tagged_images.map(&:name)
18
18
  end.flatten
19
19
 
20
20
  log_secondary_process(:images, short: true) do
@@ -153,7 +153,7 @@ module Dapp
153
153
  validate_repo_name!(repo)
154
154
  build_configs.each do |config|
155
155
  log_dimg_name_with_indent(config) do
156
- yield dimg(config: config, ignore_git_fetch: true, should_be_built: should_be_built)
156
+ yield dimg(config: config, should_be_built: should_be_built)
157
157
  end
158
158
  end
159
159
  end
@@ -6,7 +6,7 @@ module Dapp
6
6
  def run(stage_name, docker_options, command)
7
7
  one_dimg!
8
8
  setup_ssh_agent
9
- dimg(config: build_configs.first, ignore_git_fetch: true, should_be_built: stage_name.nil?, ignore_signature_auto_calculation: true)
9
+ dimg(config: build_configs.first, should_be_built: stage_name.nil?, ignore_signature_auto_calculation: true)
10
10
  .run_stage(stage_name, docker_options, command)
11
11
  end
12
12
  end
@@ -5,7 +5,7 @@ module Dapp
5
5
  module StageImage
6
6
  def stage_image
7
7
  one_dimg!
8
- puts dimg(config: build_configs.first, ignore_git_fetch: true).stage_image_name(options[:stage])
8
+ puts dimg(config: build_configs.first).stage_image_name(options[:stage])
9
9
  end
10
10
  end
11
11
  end
@@ -69,7 +69,7 @@ module Dapp
69
69
  def dapp_git_repositories
70
70
  @dapp_git_repositories ||= begin
71
71
  {}.tap do |repositories|
72
- dimgs = build_configs.map { |config| dimg(config: config, ignore_git_fetch: true, ignore_signature_auto_calculation: true) }
72
+ dimgs = build_configs.map { |config| dimg(config: config, ignore_signature_auto_calculation: true) }
73
73
  dimgs.each do |dimg|
74
74
  [dimg, dimg.artifacts]
75
75
  .flatten
@@ -9,16 +9,14 @@ module Dapp
9
9
  include Helper::Trivia
10
10
 
11
11
  attr_reader :config
12
- attr_reader :ignore_git_fetch
13
12
  attr_reader :ignore_signature_auto_calculation
14
13
  attr_reader :should_be_built
15
14
  attr_reader :dapp
16
15
 
17
- def initialize(config:, dapp:, should_be_built: false, ignore_git_fetch: false, ignore_signature_auto_calculation: false)
16
+ def initialize(config:, dapp:, should_be_built: false, ignore_signature_auto_calculation: false)
18
17
  @config = config
19
18
  @dapp = dapp
20
19
 
21
- @ignore_git_fetch = ignore_git_fetch
22
20
  @ignore_signature_auto_calculation = ignore_signature_auto_calculation
23
21
 
24
22
  @dapp._terminate_dimg_on_terminate(self)
@@ -19,7 +19,7 @@ module Dapp
19
19
  def remote_git_artifacts(omit_empty: true)
20
20
  @remote_git_artifact_list ||= [].tap do |artifacts|
21
21
  Array(config._git_artifact._remote).each do |ga_config|
22
- repo = GitRepo::Remote.get_or_create(dapp, ga_config._name, url: ga_config._url, ignore_git_fetch: ignore_git_fetch)
22
+ repo = GitRepo::Remote.get_or_create(dapp, ga_config._name, url: ga_config._url)
23
23
  artifacts.concat(generate_git_artifacts(repo, omit_empty: omit_empty, **ga_config._artifact_options)) unless repo.empty?
24
24
  end
25
25
  end
@@ -72,7 +72,7 @@ module Dapp
72
72
  embedded_rel_path = embedded_params[:path]
73
73
  embedded_repo = begin
74
74
  if embedded_params[:type] == :remote
75
- GitRepo::Remote.get_or_create(repo.dapp, embedded_rel_path, url: embedded_params[:url], ignore_git_fetch: dimg.ignore_git_fetch)
75
+ GitRepo::Remote.get_or_create(repo.dapp, embedded_rel_path, url: embedded_params[:url])
76
76
  elsif embedded_params[:type] == :local
77
77
  embedded_path = File.join(repo.workdir_path, embedded_params[:path])
78
78
  GitRepo::Local.new(repo.dapp, embedded_rel_path, embedded_path)
@@ -7,19 +7,8 @@ module Dapp
7
7
  attr_reader :url
8
8
 
9
9
  class << self
10
- def get_or_create(dapp, name, url:, ignore_git_fetch: false)
11
- key = [url, ignore_git_fetch]
12
- inverse_key = [url, !ignore_git_fetch]
13
-
14
- repositories[key] ||= begin
15
- if repositories.key?(inverse_key)
16
- repositories[inverse_key]
17
- else
18
- new(dapp, name, url: url)
19
- end.tap do |repo|
20
- repo.fetch! unless ignore_git_fetch
21
- end
22
- end
10
+ def get_or_create(dapp, name, url:)
11
+ repositories[url] ||= new(dapp, name, url: url).tap(&:fetch!)
23
12
  end
24
13
 
25
14
  def repositories
@@ -65,7 +65,7 @@ module Dapp
65
65
  end
66
66
 
67
67
  dimgs = dapp.build_configs.map do |config|
68
- dapp.dimg(config: config, ignore_git_fetch: true, ignore_signature_auto_calculation: true)
68
+ dapp.dimg(config: config, ignore_signature_auto_calculation: true)
69
69
  end.uniq do |dimg|
70
70
  dimg.name
71
71
  end
@@ -1,4 +1,4 @@
1
1
  module Dapp
2
- VERSION = "0.31.3"
2
+ VERSION = "0.31.4"
3
3
  BUILD_CACHE_VERSION = 30
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dapp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.31.3
4
+ version: 0.31.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dmitry Stolyarov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-04 00:00:00.000000000 Z
11
+ date: 2018-07-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mixlib-shellout