Skip to content

Commit

Permalink
Replace shell call for zos_mount call
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreMarcel99 committed Jan 13, 2025
1 parent a9f3698 commit 36e451b
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ This playbook uses:
- ibm.ibm_zos_core
- modules:
- zos_data_set
- zos_mount
- zos_zfs_resize
- zos_fetch

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@
# ##########################################################################
# +-------------------------------------------------------------------------
# | - Using zos_data_set, create zfs data set {{ zfs_data_set }}.
# | - Using zos_mount, mount zfs {{ zfs_data_set }} on {{ mount_point }}.
# | - Using zos_data_set, create pds data set to generate a member.
# | - Using zos_data_set, create a member to get the full trace back.
# | - Using zos_zfs_resize, resize data set {{ zfs_data_set }}.
Expand All @@ -78,7 +79,11 @@
state: directory

- name: "Mount ZFS data set."
command: /usr/sbin/mount -t zfs -f {{ zfs_data_set | upper }} {{ mount_point }}
zos_mount:
src: "{{ zfs_data_set | upper }}"
path: "{{ mount_point }}"
fs_type: zfs
state: mounted

- name: "Confirm mount point."
command: "df /{{ mount_point }}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ This playbook uses:
- ibm.ibm_zos_core
- modules:
- zos_data_set
- zos_mount
- zos_zfs_resize

It is a good practice to review the playbook contents before executing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@
# ##########################################################################
# +-------------------------------------------------------------------------
# | - Using zos_data_set, create zfs data set {{ zfs_data_set }}.
# | - Using zos_zfs_resize, resize data set {{ zfs_data_set }} on trk size.
# | - Using zos_mount, mount zfs {{ zfs_data_set }} on {{ mount_point }}.
# | - Using zos_zfs_resize, resize data set {{ zfs_data_set }} on m size.
# | - Using zos_zfs_resize, resize data set {{ zfs_data_set }}.
# +-------------------------------------------------------------------------

Expand All @@ -71,7 +72,11 @@
state: directory

- name: "Mount ZFS data set."
command: /usr/sbin/mount -t zfs -f {{ zfs_data_set | upper }} {{ mount_point }}
zos_mount:
src: "{{ zfs_data_set | upper }}"
path: "{{ mount_point }}"
fs_type: zfs
state: mounted

- name: "Confirm mount point."
command: "df /{{ mount_point }}"
Expand Down

0 comments on commit 36e451b

Please sign in to comment.