Module: Dapp::Dimg::Config::Directive::Dimg::InstanceMethods
- Defined in:
- lib/dapp/dimg/config/directive/dimg/instance_methods.rb
Defined Under Namespace
Classes: GitArtifact
Instance Attribute Summary collapse
-
#_artifact ⇒ Object
readonly
Returns the value of attribute _artifact.
-
#_artifact_groups ⇒ Object
readonly
Returns the value of attribute _artifact_groups.
-
#_builder ⇒ Object
readonly
Returns the value of attribute _builder.
-
#_chef ⇒ Object
readonly
Returns the value of attribute _chef.
-
#_docker ⇒ Object
readonly
Returns the value of attribute _docker.
-
#_git_artifact ⇒ Object
readonly
Returns the value of attribute _git_artifact.
-
#_mount ⇒ Object
readonly
Returns the value of attribute _mount.
-
#_shell ⇒ Object
readonly
Returns the value of attribute _shell.
Instance Method Summary collapse
- #_import_artifact ⇒ Object
- #artifact(&blk) ⇒ Object
- #artifacts_after_parsing! ⇒ Object
- #chef(&blk) ⇒ Object
- #docker(&blk) ⇒ Object
- #git(url = nil, &blk) ⇒ Object
- #mount(to, &blk) ⇒ Object
- #shell(&blk) ⇒ Object
Instance Attribute Details
#_artifact ⇒ Object (readonly)
Returns the value of attribute _artifact.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _artifact @_artifact end |
#_artifact_groups ⇒ Object (readonly)
Returns the value of attribute _artifact_groups.
9 10 11 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 9 def _artifact_groups @_artifact_groups end |
#_builder ⇒ Object (readonly)
Returns the value of attribute _builder.
7 8 9 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 7 def _builder @_builder end |
#_chef ⇒ Object (readonly)
Returns the value of attribute _chef.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _chef @_chef end |
#_docker ⇒ Object (readonly)
Returns the value of attribute _docker.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _docker @_docker end |
#_git_artifact ⇒ Object (readonly)
Returns the value of attribute _git_artifact.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _git_artifact @_git_artifact end |
#_mount ⇒ Object (readonly)
Returns the value of attribute _mount.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _mount @_mount end |
#_shell ⇒ Object (readonly)
Returns the value of attribute _shell.
8 9 10 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 8 def _shell @_shell end |
Instance Method Details
#_import_artifact ⇒ Object
90 91 92 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 90 def _import_artifact _artifact.select(&:not_associated?) end |
#artifact(&blk) ⇒ Object
25 26 27 28 29 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 25 def artifact(&blk) pass_to(ArtifactGroup.new(dapp: dapp), :clone_to_artifact).tap do |artifact_group| _artifact_groups << directive_eval(artifact_group, &blk) end end |
#artifacts_after_parsing! ⇒ Object
133 134 135 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 133 def artifacts_after_parsing! _artifacts_auto_excluding! end |
#chef(&blk) ⇒ Object
11 12 13 14 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 11 def chef(&blk) builder(:chef) directive_eval(_chef, &blk) end |
#docker(&blk) ⇒ Object
21 22 23 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 21 def docker(&blk) directive_eval(_docker, &blk) end |
#git(url = nil, &blk) ⇒ Object
31 32 33 34 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 31 def git(url = nil, &blk) type = url.nil? ? :local : :remote _git_artifact.public_send(type, url.to_s, &blk) end |
#mount(to, &blk) ⇒ Object
36 37 38 39 40 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 36 def mount(to, &blk) Mount.new(to, dapp: dapp, &blk).tap do |mount| _mount << mount end end |
#shell(&blk) ⇒ Object
16 17 18 19 |
# File 'lib/dapp/dimg/config/directive/dimg/instance_methods.rb', line 16 def shell(&blk) builder(:shell) directive_eval(_shell, &blk) end |