Skip to content

Commit 42158ff

Browse files
fernandofloresgrichp405rexeminAndreMarcel99ketankelkar
authored
Merge staging v1.8.0 into main branch (#1093)
* [v1.8.0][Backport] Clean temporary data sets created during XMIT unarchive operation (#1054) * Clean temporary data sets created during XMIT unarchive operation (#1049) * Added a temp cleanup * Added changelog * Modified changelog * Added removal of src if remote_src is False Signed-off-by: Fernando Flores <[email protected]> * Modified changelog fragments --------- Signed-off-by: Fernando Flores <[email protected]> * Update 1049-xmit-temporary-data-sets.yml modified PR number --------- Signed-off-by: Fernando Flores <[email protected]> * Cherry picked v1.8.0 (#1063) * Bug 1041 zos submit job honor return output literally (#1058) * initial commit to pass return_output to job_output. * corrected fragment name to match branch * tweaked data set test to show result values if positive test fails * removed trace in zos_data_set, and added trace output to job_submit * removed extra text from functional testing. * put in correct PR number in changelog fragment. * changed trivial to minor_changes, added documentation to dd_scan in job:job_output. * 1043 bug title zos operator is passing wrong value to zoauopercmd (#1044) * corrected kwarg index value from 'wait_arg' to 'wait' Also corrected true/false issue in zoaq * Added and updated changelog. * update PR number in changelog fragment * changed test from \$ to \\$ to eliminate warning * added blocking test to maks sure minimum wait is reached in zoau>1.2.4.5 * removed the else condition from the blocking test, since it is not needed. * corrected tense grammer in changelog fragment * corrected capitalization of ZOAU in changelog fragment. * updated changelog to point to the backport PR * [v1.8.0] [Backport] [zos_script] remote_tmp for zos_script (#1068) * Enabler/1024/remote_tmp for zos_script (#1060) * Changed tmp_path for Ansible's remote_tmp * Remove tmp_path from module's options * Update module documentation * Remove tmp_path test case * Update zos_script's RST file * Add changelog fragment * Updated module examples * Update changelog fragment * [v1.8.0][zos_job_submit] Removes tmp files left behind by zos_job_submit (#1070) * Ensure proper cleanup for ansiballz * Added proper removal of AnsiballZ * [v1.8.0][zos_copy][backport] File wrongly modified after second copy (#1069) * [zos_copy] Files corrupted after second copy (#1064) * Initial change to replace shutil.copy * Added fix for corrupted directory copies * Added changelog fragment * Modified docstring and fixed copy_tree * Added punctiation * Added copystat * Added set mode for dirs * Update 1064-corruped-second-copy.yml * Updated changelog * [v1.8.0] [backport] [Documentation] [zos_tso_command] Add REXX exec example (#1072) * [Documentation] [zos_tso_command] Add REXX exec example (#1065) * Add REXX exec example * Add fragment * Update module documentation * Fix PR link * Reword example task name * Updated REXX example * Update changelog fragment * Update RST file --------- Co-authored-by: Fernando Flores <[email protected]> * [v1.8.0] [Backport] [zos_copy] mvs to non existent mvs copy verify destination attrs match (#1067) * Add changes * Add fragment * Modify fragment * Modify fragment * [zos_copy] fix for executables copied from local fail with iconv error (#1079) * Added fix for executables copied from local and test * Added changelog * update link in managed_node doc (#1089) * update link in managed_node doc Signed-off-by: Ketan Kelkar <[email protected]> * Updated docs regarding managed node Signed-off-by: ddimatos <[email protected]> * Doc fragment Signed-off-by: ddimatos <[email protected]> --------- Signed-off-by: Ketan Kelkar <[email protected]> Signed-off-by: ddimatos <[email protected]> Co-authored-by: ddimatos <[email protected]> * Merge staging-v1.8.0-tasks into staging-v1.8.0 (#1090) * Modified galaxy version * mofidied meta * Update copyright year * Generated module docs * Created changelog * Removed changelog fragments * Updated changelog and release notes * Fixed newline sequences * Update CHANGELOG.rst * Update CHANGELOG.rst * Corrected release notes --------- Signed-off-by: Fernando Flores <[email protected]> Signed-off-by: Ketan Kelkar <[email protected]> Signed-off-by: ddimatos <[email protected]> Co-authored-by: Rich Parker <[email protected]> Co-authored-by: Ivan Moreno <[email protected]> Co-authored-by: André Marcel Gutiérrez Benítez <[email protected]> Co-authored-by: ketankelkar <[email protected]> Co-authored-by: ddimatos <[email protected]>
1 parent b83fa60 commit 42158ff

30 files changed

+508
-333
lines changed

CHANGELOG.rst

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ ibm.ibm_zos_core Release Notes
55
.. contents:: Topics
66

77

8-
v1.8.0-beta.1
9-
=============
8+
v1.8.0
9+
======
1010

1111
Release Summary
1212
---------------
1313

14-
Release Date: '2023-10-24'
14+
Release Date: '2023-12-08'
1515
This changelog describes all changes made to the modules and plugins included
1616
in this collection. The release date is the date the changelog is created.
1717
For additional details such as required dependencies and availability review
@@ -31,18 +31,31 @@ Minor Changes
3131
- zos_job_submit - Change action plugin call from copy to zos_copy. (https://github.com/ansible-collections/ibm_zos_core/pull/951)
3232
- zos_operator - Changed system to call 'wait=true' parameter to zoau call. Requires zoau 1.2.5 or later. (https://github.com/ansible-collections/ibm_zos_core/pull/976)
3333
- zos_operator_action_query - Add a max delay of 5 seconds on each part of the operator_action_query. Requires zoau 1.2.5 or later. (https://github.com/ansible-collections/ibm_zos_core/pull/976)
34+
- zos_script - add support for remote_tmp from the Ansible configuration to setup where temporary files will be created, replacing the module option tmp_path. (https://github.com/ansible-collections/ibm_zos_core/pull/1068).
35+
- zos_submit_job - Previous code did not return output, but still requested job data from the target system. This changes to honor return_output=false by not querying the job dd segments at all. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
36+
- zos_tso_command - add example for executing explicitly a REXX script from a data set. (https://github.com/ansible-collections/ibm_zos_core/pull/1072).
3437
- zos_unarchive - Add validation into path joins to detect unauthorized path traversals. (https://github.com/ansible-collections/ibm_zos_core/pull/1029)
3538
- zos_unarchive - Enhanced test cases to use test lines the same length of the record length. (https://github.com/ansible-collections/ibm_zos_core/pull/965)
36-
- zos_copy - add support in zos_copy for text files and data sets containing ASA control characters. (https://github.com/ansible-collections/ibm_zos_core/pull/1028)
39+
40+
Deprecated Features
41+
-------------------
42+
43+
- zos_blockinfile - debug is deprecated in favor of 'as_json' (https://github.com/ansible-collections/ibm_zos_core/pull/904).
3744

3845
Bugfixes
3946
--------
4047

4148
- zos_copy - Update option limit to include LIBRARY as dest_dataset/suboption value. Documentation updated to reflect this change. (https://github.com/ansible-collections/ibm_zos_core/pull/968).
49+
- zos_copy - When copying an executable data set from controller to managed node, copy operation failed with an encoding error. Fix now avoids encoding when executable option is selected. (https://github.com/ansible-collections/ibm_zos_core/pull/1079).
50+
- zos_copy - When copying an executable data set with aliases and destination did not exist, destination data set was created with wrong attributes. Fix now creates destination data set with the same attributes as the source. (https://github.com/ansible-collections/ibm_zos_core/pull/1067).
51+
- zos_copy - When performing a copy operation to an existing file, the copied file resulted in having corrupted contents. Fix now implements a workaround to not use the specific copy routine that corrupts the file contents. (https://github.com/ansible-collections/ibm_zos_core/pull/1069).
4252
- zos_job_submit - Temporary files were created in tmp directory. Fix now ensures the deletion of files every time the module run. (https://github.com/ansible-collections/ibm_zos_core/pull/951)
4353
- zos_job_submit - The last line of the jcl was missing in the input. Fix now ensures the presence of the full input in job_submit. (https://github.com/ansible-collections/ibm_zos_core/pull/952)
4454
- zos_lineinfile - A duplicate entry was made even if line was already present in the target file. Fix now prevents a duplicate entry if the line already exists in the target file. (https://github.com/ansible-collections/ibm_zos_core/pull/916)
4555
- zos_operator - The last line of the operator was missing in the response of the module. The fix now ensures the presence of the full output of the operator. https://github.com/ansible-collections/ibm_zos_core/pull/918)
56+
- zos_operator - The module was ignoring the wait time argument. The module now passes the wait time argument to ZOAU. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
57+
- zos_operator_action_query - The module was ignoring the wait time argument. The module now passes the wait time argument to ZOAU. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
58+
- zos_unarchive - When zos_unarchive fails during unpack either with xmit or terse it does not clean the temporary data sets created. Fix now removes the temporary data sets. (https://github.com/ansible-collections/ibm_zos_core/pull/1054).
4659

4760
Known Issues
4861
------------

changelogs/changelog.yaml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1023,6 +1023,55 @@ releases:
10231023
- 930-archive-post-beta.yml
10241024
- v1.7.0-beta.2_summary.yml
10251025
release_date: '2023-08-21'
1026+
1.8.0:
1027+
changes:
1028+
bugfixes:
1029+
- zos_copy - When copying an executable data set from controller to managed
1030+
node, copy operation failed with an encoding error. Fix now avoids encoding
1031+
when executable option is selected. (https://github.com/ansible-collections/ibm_zos_core/pull/1079).
1032+
- zos_copy - When copying an executable data set with aliases and destination
1033+
did not exist, destination data set was created with wrong attributes. Fix
1034+
now creates destination data set with the same attributes as the source. (https://github.com/ansible-collections/ibm_zos_core/pull/1067).
1035+
- zos_copy - When performing a copy operation to an existing file, the copied
1036+
file resulted in having corrupted contents. Fix now implements a workaround
1037+
to not use the specific copy routine that corrupts the file contents. (https://github.com/ansible-collections/ibm_zos_core/pull/1069).
1038+
- zos_operator - The module was ignoring the wait time argument. The module
1039+
now passes the wait time argument to ZOAU. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
1040+
- zos_operator_action_query - The module was ignoring the wait time argument.
1041+
The module now passes the wait time argument to ZOAU. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
1042+
- zos_unarchive - When zos_unarchive fails during unpack either with xmit or
1043+
terse it does not clean the temporary data sets created. Fix now removes the
1044+
temporary data sets. (https://github.com/ansible-collections/ibm_zos_core/pull/1054).
1045+
minor_changes:
1046+
- zos_script - Add support for remote_tmp from the Ansible configuration to
1047+
setup where temporary files will be created, replacing the module option tmp_path.
1048+
(https://github.com/ansible-collections/ibm_zos_core/pull/1068).
1049+
- zos_job_submit - Previous code did not return output, but still requested
1050+
job data from the target system. This changes to honor return_output=false
1051+
by not querying the job dd segments at all. (https://github.com/ansible-collections/ibm_zos_core/pull/1063).
1052+
- zos_tso_command - Add example for executing explicitly a REXX script from
1053+
a data set. (https://github.com/ansible-collections/ibm_zos_core/pull/1072).
1054+
release_summary: 'Release Date: ''2023-12-08''
1055+
1056+
This changelog describes all changes made to the modules and plugins included
1057+
1058+
in this collection. The release date is the date the changelog is created.
1059+
1060+
For additional details such as required dependencies and availability review
1061+
1062+
the collections `release notes <https://ibm.github.io/z_ansible_collections_doc/ibm_zos_core/docs/source/release_notes.html>`__'
1063+
fragments:
1064+
- 1041-bug-zos-submit-job-honor-return-output-literally.yml
1065+
- 1043-bug-title-zos_operator-is-passing-wrong-value-to-zoauopercmd.yml
1066+
- 1049-xmit-temporary-data-sets.yml
1067+
- 1060-remote_tmp_zos_script.yml
1068+
- 1067-mvs_to_non_existent_mvs_copy_verify_destination_attrs_match.yml
1069+
- 1069-corrupted-second-copy.yml
1070+
- 1072-rexx-exec-tso_command.yml
1071+
- 1079-zos-copy-local-executable.yml
1072+
- 1089-update-managed_node_doc.yml
1073+
- v1.8.0-summary.yml
1074+
release_date: '2023-12-08'
10261075
1.8.0-beta.1:
10271076
changes:
10281077
bugfixes:

docs/source/modules/zos_copy.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,7 @@ template_parameters
554554
| **choices**: \\n, \\r, \\r\\n
555555
556556

557+
557558
auto_reload
558559
Whether to reload a template file when it has changed after the task has started.
559560

docs/source/modules/zos_job_submit.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,7 @@ template_parameters
259259
| **choices**: \\n, \\r, \\r\\n
260260
261261

262+
262263
auto_reload
263264
Whether to reload a template file when it has changed after the task has started.
264265

docs/source/modules/zos_script.rst

Lines changed: 6 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -102,19 +102,6 @@ removes
102102
| **type**: str
103103
104104

105-
tmp_path
106-
Directory path in the remote machine where local scripts will be temporarily copied to.
107-
108-
When not specified, the module will copy local scripts to the default temporary path for the user.
109-
110-
If ``tmp_path`` does not exist in the remote machine, the module will not create it.
111-
112-
All scripts copied to ``tmp_path`` will be removed from the managed node before the module finishes executing.
113-
114-
| **required**: False
115-
| **type**: str
116-
117-
118105
use_template
119106
Whether the module should treat ``src`` as a Jinja2 template and render it before continuing with the rest of the module.
120107

@@ -234,6 +221,7 @@ template_parameters
234221
| **choices**: \\n, \\r, \\r\\n
235222
236223

224+
237225
auto_reload
238226
Whether to reload a template file when it has changed after the task has started.
239227

@@ -264,11 +252,10 @@ Examples
264252
remote_src: true
265253
chdir: /u/user/output_dir
266254

267-
- name: Run a local Python script that uses a custom tmp_path.
255+
- name: Run a local Python script in the temporary directory specified in the Ansible environment variable 'remote_tmp'.
268256
zos_script:
269257
cmd: ./scripts/program.py
270258
executable: /usr/bin/python3
271-
tmp_path: /usr/tmp/ibm_zos_core
272259

273260
- name: Run a local script made from a template.
274261
zos_script:
@@ -294,6 +281,10 @@ Notes
294281
.. note::
295282
When executing local scripts, temporary storage will be used on the remote z/OS system. The size of the temporary storage will correspond to the size of the file being copied.
296283

284+
The location in the z/OS system where local scripts will be copied to can be configured through Ansible's ``remote_tmp`` option. Refer to `Ansible's documentation <https://docs.ansible.com/ansible/latest/collections/ansible/builtin/sh_shell.html#parameter-remote_tmp>`_ for more information.
285+
286+
All local scripts copied to a remote z/OS system will be removed from the managed node before the module finishes executing.
287+
297288
Execution permissions for the group assigned to the script will be added to remote scripts. The original permissions for remote scripts will be restored by the module before the task ends.
298289

299290
The module will only add execution permissions for the file owner.

docs/source/modules/zos_tso_command.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ Examples
7171
- LISTDSD DATASET('HLQ.DATA.SET') ALL GENERIC
7272
max_rc: 4
7373

74+
- name: Execute TSO command to run a REXX script explicitly from a data set.
75+
zos_tso_command:
76+
commands:
77+
- EXEC HLQ.DATASET.REXX exec
7478

7579

7680

docs/source/release_notes.rst

Lines changed: 31 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
Releases
77
========
88

9-
Version 1.8.0-beta.1
10-
====================
9+
Version 1.8.0
10+
=============
1111

1212
New Modules
1313
-----------
@@ -22,29 +22,46 @@ Minor Changes
2222
- Enhanced test cases to use test lines the same length of the record length.
2323
- ``zos_copy``
2424

25-
- Add validation into path joins to detect unauthorized path traversals.
25+
- Add validation into path joins to detect unauthorized path traversals.
2626
- Add new option `force_lock` that can copy into data sets that are already in use by other processes (DISP=SHR). User needs to use with caution because this is subject to race conditions and can lead to data loss.
27-
- includes a new option `executable` that enables copying of executables such as load modules or program objects to both USS and partitioned data sets. When the `dest` option contains a non-existent data set, `zos_copy` will create a data set with the appropriate attributes for an executable.
28-
- introduces a new option 'aliases' to enable preservation of member aliases when copying data to partitioned data sets (PDS) destinations from USS or other PDS sources. Copying aliases of text based members to/from USS is not supported.
29-
- add support in zos_copy for text files and data sets containing ASA control characters.
27+
- Includes a new option `executable` that enables copying of executables such as load modules or program objects to both USS and partitioned data sets. When the `dest` option contains a non-existent data set, `zos_copy` will create a data set with the appropriate attributes for an executable.
28+
- Introduces a new option 'aliases' to enable preservation of member aliases when copying data to partitioned data sets (PDS) destinations from USS or other PDS sources. Copying aliases of text based members to/from USS is not supported.
29+
- Add support in zos_copy for text files and data sets containing ASA control characters.
3030
- ``zos_fetch`` - Add validation into path joins to detect unauthorized path traversals.
31-
- ``zos_job_submit`` - Change action plugin call from copy to zos_copy.
32-
- ``zos_operator`` - Changed system to call 'wait=true' parameter to zoau call. Requires zoau 1.2.5 or later.
31+
- ``zos_job_submit``
32+
33+
- Change action plugin call from copy to zos_copy.
34+
- Previous code did not return output, but still requested job data from the target system. This changes to honor `return_output=false` by not querying the job dd segments at all.
35+
- ``zos_operator`` - Changed system to call `wait=true` parameter to zoau call. Requires zoau 1.2.5 or later.
3336
- ``zos_operator_action_query`` - Add a max delay of 5 seconds on each part of the operator_action_query. Requires zoau 1.2.5 or later.
3437
- ``zos_unarchive``
3538

36-
- Add validation into path joins to detect unauthorized path traversals.
39+
- Add validation into path joins to detect unauthorized path traversals.
3740
- Enhanced test cases to use test lines the same length of the record length.
3841
- ``module_utils/template`` - Add validation into path joins to detect unauthorized path traversals.
42+
- ``zos_tso_command`` - Add example for executing explicitly a REXX script from a data set.
43+
- ``zos_script`` - Add support for remote_tmp from the Ansible configuration to setup where temporary files will be created, replacing the module option tmp_path.
3944

4045
Bugfixes
4146
--------
4247

43-
- ``zos_copy`` - Update option limit to include LIBRARY as dest_dataset/suboption value. Documentation updated to reflect this change.
44-
- ``zos_job_submit`` - Temporary files were created in tmp directory. Fix now ensures the deletion of files every time the module run.
45-
- ``zos_job_submit`` - The last line of the jcl was missing in the input. Fix now ensures the presence of the full input in job_submit.
48+
- ``zos_copy``
49+
50+
- Update option to include `LIBRARY` as dest_dataset/suboption value. Documentation updated to reflect this change.
51+
- When copying an executable data set from controller to managed node, copy operation failed with an encoding error. Fix now avoids encoding when `executable` option is selected.
52+
- When copying an executable data set with aliases and destination did not exist, destination data set was created with wrong attributes. Fix now creates destination data set with the same attributes as the source.
53+
- When performing a copy operation to an existing file, the copied file resulted in having corrupted contents. Fix now implements a workaround to not use the specific copy routine that corrupts the file contents.
54+
- ``zos_job_submit``
55+
56+
- Temporary files were created in tmp directory. Fix now ensures the deletion of files every time the module run.
57+
- The last line of the jcl was missing in the input. Fix now ensures the presence of the full input in job_submit.
4658
- ``zos_lineinfile`` - A duplicate entry was made even if line was already present in the target file. Fix now prevents a duplicate entry if the line already exists in the target file.
47-
- ``zos_operator`` - The last line of the operator was missing in the response of the module. The fix now ensures the presence of the full output of the operator.
59+
- ``zos_operator``
60+
61+
- The last line of the operator was missing in the response of the module. The fix now ensures the presence of the full output of the operator.
62+
- The module was ignoring the wait time argument. The module now passes the wait time argument to ZOAU.
63+
- ``zos_operator_action_query`` - The module was ignoring the wait time argument. The module now passes the wait time argument to ZOAU.
64+
- ``zos_unarchive`` - When zos_unarchive fails during unpack either with xmit or terse it does not clean the temporary data sets created. Fix now removes the temporary data sets.
4865

4966
Known Issues
5067
------------
@@ -55,6 +72,7 @@ Known Issues
5572
Availability
5673
------------
5774

75+
* `Automation Hub`_
5876
* `Galaxy`_
5977
* `GitHub`_
6078

0 commit comments

Comments
 (0)