mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Removing some leftover debug prints and cleaning up test sample
This commit is contained in:
parent
cf96c7719e
commit
93c9803818
8 changed files with 2 additions and 12 deletions
|
@ -147,7 +147,6 @@ class Block(Base, Become, Conditional, Taggable):
|
||||||
new_me.block = _dupe_task_list(self.block or [], new_me)
|
new_me.block = _dupe_task_list(self.block or [], new_me)
|
||||||
new_me.rescue = _dupe_task_list(self.rescue or [], new_me)
|
new_me.rescue = _dupe_task_list(self.rescue or [], new_me)
|
||||||
new_me.always = _dupe_task_list(self.always or [], new_me)
|
new_me.always = _dupe_task_list(self.always or [], new_me)
|
||||||
print("new block tasks are: %s" % new_me.block)
|
|
||||||
|
|
||||||
new_me._parent_block = None
|
new_me._parent_block = None
|
||||||
if self._parent_block:
|
if self._parent_block:
|
||||||
|
|
|
@ -37,7 +37,6 @@ def load_list_of_blocks(ds, parent_block=None, role=None, task_include=None, use
|
||||||
assert type(ds) in (list, NoneType)
|
assert type(ds) in (list, NoneType)
|
||||||
|
|
||||||
block_list = []
|
block_list = []
|
||||||
print("in load list of blocks, ds is: %s" % ds)
|
|
||||||
if ds:
|
if ds:
|
||||||
for block in ds:
|
for block in ds:
|
||||||
b = Block.load(
|
b = Block.load(
|
||||||
|
@ -51,7 +50,6 @@ def load_list_of_blocks(ds, parent_block=None, role=None, task_include=None, use
|
||||||
)
|
)
|
||||||
block_list.append(b)
|
block_list.append(b)
|
||||||
|
|
||||||
print("-> returning block list: %s" % block_list)
|
|
||||||
return block_list
|
return block_list
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -219,7 +219,6 @@ class Play(Base, Taggable, Become):
|
||||||
block_list.extend(self.tasks)
|
block_list.extend(self.tasks)
|
||||||
block_list.extend(self.post_tasks)
|
block_list.extend(self.post_tasks)
|
||||||
|
|
||||||
print("block list is: %s" % block_list)
|
|
||||||
return block_list
|
return block_list
|
||||||
|
|
||||||
def get_vars(self):
|
def get_vars(self):
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
allow_duplicates: yes
|
#allow_duplicates: yes
|
||||||
|
|
|
@ -1,2 +1 @@
|
||||||
- debug: msg="this is test_become_r1"
|
|
||||||
- command: whoami
|
- command: whoami
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
allow_duplicates: yes
|
#allow_duplicates: yes
|
||||||
dependencies:
|
dependencies:
|
||||||
- test_become_r1
|
- test_become_r1
|
||||||
|
|
|
@ -1,2 +1 @@
|
||||||
- debug: msg="this is test_become_r2"
|
|
||||||
- command: whoami
|
- command: whoami
|
||||||
|
|
|
@ -1,14 +1,10 @@
|
||||||
- hosts: all
|
- hosts: all
|
||||||
gather_facts: no
|
gather_facts: no
|
||||||
roles:
|
roles:
|
||||||
- { role: test_become_r2 }
|
|
||||||
- { role: test_become_r2, sudo_user: testing }
|
- { role: test_become_r2, sudo_user: testing }
|
||||||
tasks:
|
tasks:
|
||||||
- command: whoami
|
|
||||||
- command: whoami
|
- command: whoami
|
||||||
become_user: testing
|
become_user: testing
|
||||||
- block:
|
|
||||||
- command: whoami
|
|
||||||
- block:
|
- block:
|
||||||
- command: whoami
|
- command: whoami
|
||||||
become_user: testing
|
become_user: testing
|
||||||
|
|
Loading…
Reference in a new issue