Class: Ansible::Ruby::DslBuilders::Unit
- Inherits:
-
Base
- Object
- Base
- Ansible::Ruby::DslBuilders::Unit
show all
- Defined in:
- lib/ansible/ruby/dsl_builders/unit.rb
Instance Method Summary
collapse
Methods inherited from Base
#_result, #jinja, #method_missing, #respond_to_missing?
Constructor Details
#initialize ⇒ Unit
Returns a new instance of Unit.
8
9
10
11
12
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 8
def initialize
super()
@temp_counter = 0
@task_args = {}
end
|
Instance Method Details
#ansible_when(clause) ⇒ Object
23
24
25
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 23
def ansible_when(clause)
@task_args[:when] = clause
end
|
#become(*args) ⇒ Object
14
15
16
17
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 14
def become(*args)
value = _implicit_bool args
@task_args[:become] = value
end
|
#become_user(value) ⇒ Object
19
20
21
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 19
def become_user(value)
@task_args[:become_user] = value
end
|
#ignore_errors(*args) ⇒ Object
27
28
29
30
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 27
def ignore_errors(*args)
value = _implicit_bool args
@task_args[:ignore_errors] = value
end
|
#vars(hash) ⇒ Object
32
33
34
|
# File 'lib/ansible/ruby/dsl_builders/unit.rb', line 32
def vars(hash)
@task_args[:vars] = hash
end
|