Skip to content

Commit 5ea115c

Browse files
committed
doc changes
1 parent 6f6baa4 commit 5ea115c

File tree

1 file changed

+18
-36
lines changed

1 file changed

+18
-36
lines changed

content/modules/ROOT/pages/06-vm-backup.adoc

Lines changed: 18 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Three (3) OpenShift API's are available to manage Virtual Machine Snapshots
2929

3030
The VM snapshot controller binds a VirtualMachineSnapshotContent object with the VirtualMachineSnapshot object for which it was created, with a one-to-one mapping.
3131

32-
We can use Ansible and Ansible Automation Platform to manage the creation of these OpenShift API's at scale so that we can snapshot a single VM or a fleet of VM's.
32+
We can use Ansible Automation Platform to manage the creation of these OpenShift API's at scale so that we can snapshot a single VM or a fleet of VM's.
3333

3434
== Automating taking Snapshots of Virtual Machines
3535

@@ -39,19 +39,11 @@ When using Ansible, the *loop* directive can be used to execute a task or a seri
3939

4040
=== Create the `snapshot_vms.yml` File
4141

42-
. Navigate to the Tasks Folder:
42+
. Within your VSCode editor, right click `tasks` of the `vm_management` collection and create a New File labeled `snapshot_vms.yml`
4343
+
44-
----
45-
cd collections/ansible_collections/redhatone/vm_management/roles/vm_management/tasks/
46-
----
44+
image::new_file.png[title='New File Creation', link=self, window=blank]
4745
+
48-
. Create the `snapshot_vms.yml` File:
49-
+
50-
----
51-
touch snapshot_vms.yml
52-
----
53-
+
54-
. Open the `snapshot_vms.yml` File in Your Favorite Editor and Add the Following Task:
46+
. Add the following content to the `snapshot_vms.yml`:
5547
+
5648
----
5749
---
@@ -78,15 +70,13 @@ This is a fairly complex task, so let's break it down:
7870

7971
=== Create the `_snapshot_vm.yml` File
8072

81-
A task file beginning with an underscore (`_`) indicates that it is included within another task file. While still within the _tasks_ folder, perform the following steps:
73+
A task file beginning with an underscore (`_`) indicates that it is included within another task file. While still within the _tasks_ folder, perform the following steps.
8274

83-
. Create the `_snapshot_vm.yml` File:
75+
. Within your VSCode editor, right click `tasks` of the `vm_management` collection and create a New File labeled `_snapshot_vm.yml`
8476
+
85-
----
86-
touch _snapshot_vm.yml
87-
----
77+
image::new_file.png[title='New File Creation', link=self, window=blank]
8878
+
89-
. Open the `_snapshot_vm.yml` File in Your Favorite Editor and Add the Following Tasks:
79+
. Add the following content to the `_snapshot_vm.yml`:
9080
+
9181
----
9282
---
@@ -161,7 +151,7 @@ Lets break down this task in further detail:
161151

162152
== Create and Run the Snapshot VMs Job Template
163153

164-
. Navigate to *Automation Execution → Templates*.
154+
. Head to the AAP UI Dashboard, navigate to *Automation Execution → Templates*.
165155
. Click *Create Template* and select *Create job template*.
166156
. Fill in the following details:
167157

@@ -229,19 +219,11 @@ Follow a similar approach that was used for taking a snapshot where a single pla
229219

230220
=== Create the `restore_vm_snapshots.yml` File
231221

232-
. Navigate to the Tasks Folder:
222+
. Within your VSCode editor, right click `tasks` of the `vm_management` collection and create a New File labeled `restore_vm_snapshots.yml`
233223
+
234-
----
235-
cd collections/ansible_collections/redhatone/vm_management/roles/vm_management/tasks/
236-
----
237-
+
238-
. Create the `restore_vm_snapshots.yml` File:
239-
+
240-
----
241-
touch restore_vm_snapshots.yml
242-
----
224+
image::new_file.png[title='New File Creation', link=self, window=blank]
243225
+
244-
. Open the `restore_vm_snapshots.yml` File in Your Favorite Editor and Add the Following Task:
226+
. Add the following content to the `restore_vm_snapshots.yml`:
245227
+
246228
----
247229
---
@@ -269,13 +251,11 @@ Once the variable has been verified, the following are the steps that will be us
269251
. Create the `VirtualMachineRestore` resource and wait until the restoration completes successfully
270252
. Start the Virtual Machine
271253

272-
. Create the `_restore_vm_snapshot.yml` File:
254+
. Within your VSCode editor, right click `tasks` of the `vm_management` collection and create a New File labeled `_restore_vm_snapshot.yml`
273255
+
274-
----
275-
touch _restore_vm_snapshot.yml
276-
----
256+
image::new_file.png[title='New File Creation', link=self, window=blank]
277257
+
278-
. Open the `_restore_vm_snapshot.yml` File in Your Favorite Editor and Add the Following Tasks:
258+
. Add the following content to the `_restore_vm_snapshot.yml`:
279259
+
280260
----
281261
---
@@ -356,7 +336,7 @@ One key difference during the creation of the `VirtualMachineRestore` using the
356336

357337
== Create and Run the Restore VM Snapshots Job Template
358338

359-
. Navigate to *Automation Execution → Templates*.
339+
. Head to the AAP UI Dashboard, navigate to *Automation Execution → Templates*.
360340
. Click *Create Template* and select *Create job template*.
361341
. Fill in the following details making sure to include the name of the snapshot created previously for the `rhel9-vm1` Virtual Machine:
362342

@@ -377,6 +357,8 @@ One key difference during the creation of the `VirtualMachineRestore` using the
377357

378358
WARNING: Replace <snapshot_name> with the name of your snapthot created previously.
379359

360+
Launch the template.
361+
380362
Once the Job completes successfully, confirm the restoration of the Snapshot was applied to the `rhel9-vm1` by navigating to the OpenShift UI, Virtualization -> VirtualMachines within the `vms-aap-day2` project.
381363

382364
Select the `rhel9-vm1` instance and then select the *Snapshots* tab. Locate the Snapshot created previously and notice the date and time within the _Last restored_ column indicating that the Snapshot was successfully restored against the Virtual Machine instance.

0 commit comments

Comments
 (0)