diff options
Diffstat (limited to 'doc/book-enea-edge-system-test-specification/doc')
4 files changed, 1993 insertions, 0 deletions
diff --git a/doc/book-enea-edge-system-test-specification/doc/book.xml b/doc/book-enea-edge-system-test-specification/doc/book.xml new file mode 100644 index 0000000..bcc2dcd --- /dev/null +++ b/doc/book-enea-edge-system-test-specification/doc/book.xml | |||
@@ -0,0 +1,27 @@ | |||
1 | <?xml version="1.0" encoding="ISO-8859-1"?> | ||
2 | <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" | ||
3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [ | ||
4 | <!ENTITY % local.common.attrib "xml:base CDATA #IMPLIED"> | ||
5 | ]> | ||
6 | <book id="book_enea_edge_system_test_specification"> | ||
7 | <title><trademark class="registered">Enea</trademark> Edge System Test Specification</title> | ||
8 | |||
9 | <subtitle>Release Version | ||
10 | <xi:include href="../../s_doceneacommon/doc/eltf_params_updated.xml" xpointer="element(EneaLinux_REL_VER/1)" | ||
11 | xmlns:xi="http://www.w3.org/2001/XInclude" /></subtitle> | ||
12 | |||
13 | <!-- OLINKDBPATH_USED_BY_XMLMIND ../../s_docbuild/olinkdb --> | ||
14 | |||
15 | <xi:include href="../../s_docbuild/template/docsrc_common/bookinfo_userdoc.xml" | ||
16 | xmlns:xi="http://www.w3.org/2001/XInclude" /> | ||
17 | |||
18 | <xi:include href="overview.xml" | ||
19 | xmlns:xi="http://www.w3.org/2001/XInclude" /> | ||
20 | |||
21 | <xi:include href="configuration.xml" | ||
22 | xmlns:xi="http://www.w3.org/2001/XInclude" /> | ||
23 | |||
24 | <xi:include href="sample_test_cases.xml" | ||
25 | xmlns:xi="http://www.w3.org/2001/XInclude" /> | ||
26 | |||
27 | </book> | ||
diff --git a/doc/book-enea-edge-system-test-specification/doc/configuration.xml b/doc/book-enea-edge-system-test-specification/doc/configuration.xml new file mode 100644 index 0000000..28a9756 --- /dev/null +++ b/doc/book-enea-edge-system-test-specification/doc/configuration.xml | |||
@@ -0,0 +1,53 @@ | |||
1 | <?xml version="1.0" encoding="ISO-8859-1"?> | ||
2 | <chapter id="config_sts"> | ||
3 | <title>Configuration</title> | ||
4 | |||
5 | <section id="test_objects"> | ||
6 | <title>Test Objects</title> | ||
7 | |||
8 | <para>The test objects for the Test Harness are the Enea Edge Runtime and | ||
9 | the Enea Edge Management installations performed as indicated in the <olink | ||
10 | targetdoc="book_enea_edge_auto_fw_th_user_guide" | ||
11 | targetptr="components">Components chapter of the <xi:include | ||
12 | href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
13 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
14 | xpointer="element(book_enea_edge_auto_fw_th_user_guide/1)" /></olink>.</para> | ||
15 | </section> | ||
16 | |||
17 | <section id="test_env"> | ||
18 | <title>Test Environment</title> | ||
19 | |||
20 | <para>To set up the required Test Harness environment please refer to | ||
21 | <olink targetdoc="book_enea_edge_auto_fw_th_user_guide" | ||
22 | targetptr="getting_started">Getting Started with the Automation Framework | ||
23 | and Test Harness in the <xi:include | ||
24 | href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
25 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
26 | xpointer="element(book_enea_edge_auto_fw_th_user_guide/1)" /></olink>.</para> | ||
27 | </section> | ||
28 | |||
29 | <section id="precon_exe_steps"> | ||
30 | <title>Preconditions and Execution</title> | ||
31 | |||
32 | <para>Please refer to section <olink | ||
33 | targetdoc="book_enea_edge_auto_fw_th_user_guide" | ||
34 | targetptr="prerequisites">Prerequisites in the <xi:include | ||
35 | href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
36 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
37 | xpointer="element(book_enea_edge_auto_fw_th_user_guide/1)" /></olink> | ||
38 | and section <olink targetdoc="book_enea_edge_auto_fw_th_user_guide" | ||
39 | targetptr="initial_setup">Installation and Initial Setup in the | ||
40 | <xi:include href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
41 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
42 | xpointer="element(book_enea_edge_auto_fw_th_user_guide/1)" /></olink> | ||
43 | for more details.</para> | ||
44 | |||
45 | <note> | ||
46 | <para>Before running any test case, make sure the uCPE device(s) needed | ||
47 | have been added to the Enea Edge Management.</para> | ||
48 | </note> | ||
49 | |||
50 | <para>For detailed execution steps of the sample test cases included with | ||
51 | the Test Harness please see the following chapter.</para> | ||
52 | </section> | ||
53 | </chapter> \ No newline at end of file | ||
diff --git a/doc/book-enea-edge-system-test-specification/doc/overview.xml b/doc/book-enea-edge-system-test-specification/doc/overview.xml new file mode 100644 index 0000000..bcdbc53 --- /dev/null +++ b/doc/book-enea-edge-system-test-specification/doc/overview.xml | |||
@@ -0,0 +1,109 @@ | |||
1 | <?xml version="1.0" encoding="ISO-8859-1"?> | ||
2 | <chapter id="overview_sts"> | ||
3 | <title>Overview</title> | ||
4 | |||
5 | <para>This document describes the Test Harness (TH) sample test cases for | ||
6 | the System Testing of Enea Edge, and the necessary environment setup | ||
7 | to run these tests successfully.</para> | ||
8 | |||
9 | <section id="def_acro_sts"> | ||
10 | <title>Definitions and Acronyms</title> | ||
11 | |||
12 | <table> | ||
13 | <title>Definitions</title> | ||
14 | |||
15 | <tgroup cols="2"> | ||
16 | <colspec align="left" /> | ||
17 | |||
18 | <thead> | ||
19 | <row> | ||
20 | <entry align="center">Component</entry> | ||
21 | |||
22 | <entry align="center">Description</entry> | ||
23 | </row> | ||
24 | </thead> | ||
25 | |||
26 | <tbody> | ||
27 | <row> | ||
28 | <entry>Enea Edge</entry> | ||
29 | |||
30 | <entry>The Enea Edge Runtime and the | ||
31 | Enea Edge Management.</entry> | ||
32 | </row> | ||
33 | </tbody> | ||
34 | </tgroup> | ||
35 | </table> | ||
36 | |||
37 | <table> | ||
38 | <title>Acronyms</title> | ||
39 | |||
40 | <tgroup cols="2"> | ||
41 | <colspec align="left" /> | ||
42 | |||
43 | <thead> | ||
44 | <row> | ||
45 | <entry align="center">Component</entry> | ||
46 | |||
47 | <entry align="center">Description</entry> | ||
48 | </row> | ||
49 | </thead> | ||
50 | |||
51 | <tbody> | ||
52 | <row> | ||
53 | <entry>AF</entry> | ||
54 | |||
55 | <entry>Automation Framework for Enea Edge.</entry> | ||
56 | </row> | ||
57 | |||
58 | <row> | ||
59 | <entry>JSON</entry> | ||
60 | |||
61 | <entry>JavaScript Object Notation.</entry> | ||
62 | </row> | ||
63 | |||
64 | <row> | ||
65 | <entry>NIC</entry> | ||
66 | |||
67 | <entry>Network Interface Card.</entry> | ||
68 | </row> | ||
69 | |||
70 | <row> | ||
71 | <entry>NFV</entry> | ||
72 | |||
73 | <entry>Network Functions Virtualization.</entry> | ||
74 | </row> | ||
75 | |||
76 | <row> | ||
77 | <entry>ODM</entry> | ||
78 | |||
79 | <entry>Enea Element On Device Management.</entry> | ||
80 | </row> | ||
81 | |||
82 | <row> | ||
83 | <entry>OVS</entry> | ||
84 | |||
85 | <entry>Open vSwitch.</entry> | ||
86 | </row> | ||
87 | |||
88 | <row> | ||
89 | <entry>TH</entry> | ||
90 | |||
91 | <entry>Test Harness for Enea Edge.</entry> | ||
92 | </row> | ||
93 | |||
94 | <row> | ||
95 | <entry>Enea Edge Management</entry> | ||
96 | |||
97 | <entry>Enea Universal Customer Premises Equipment Manager.</entry> | ||
98 | </row> | ||
99 | |||
100 | <row> | ||
101 | <entry>VNF</entry> | ||
102 | |||
103 | <entry>Virtualized Network Function.</entry> | ||
104 | </row> | ||
105 | </tbody> | ||
106 | </tgroup> | ||
107 | </table> | ||
108 | </section> | ||
109 | </chapter> \ No newline at end of file | ||
diff --git a/doc/book-enea-edge-system-test-specification/doc/sample_test_cases.xml b/doc/book-enea-edge-system-test-specification/doc/sample_test_cases.xml new file mode 100644 index 0000000..9fa6bda --- /dev/null +++ b/doc/book-enea-edge-system-test-specification/doc/sample_test_cases.xml | |||
@@ -0,0 +1,1804 @@ | |||
1 | <?xml version="1.0" encoding="ISO-8859-1"?> | ||
2 | <chapter id="sample_testcases"> | ||
3 | <title>Sample Test Cases</title> | ||
4 | |||
5 | <para>The test cases specified in this chapter are implemented as a Sample | ||
6 | Test Suite included in the TH.</para> | ||
7 | |||
8 | <section id="vnf_dev_net_smoke"> | ||
9 | <title>VNF, Device and Network Smoke Test Cases</title> | ||
10 | |||
11 | <para>The following is an automated test suite that acts as basic smoke | ||
12 | tests for Enea Edge, and as a sanity-check test suite for the AF and | ||
13 | TH.</para> | ||
14 | |||
15 | <section id="onb_vnf_image"> | ||
16 | <title>VNF - Onboard a VNF Image</title> | ||
17 | |||
18 | <para><emphasis role="bold">Description: </emphasis>Onboarding a VNF | ||
19 | Image into the Enea Edge Management. For details please refer to:</para> | ||
20 | |||
21 | <itemizedlist> | ||
22 | <listitem> | ||
23 | <para><filename><AF-TH-install-dir>/playbooks/onboardVNFImage.yml</filename></para> | ||
24 | </listitem> | ||
25 | |||
26 | <listitem> | ||
27 | <para><filename><AF-TH-install-dir>/automation_framework/vnf/onboardVNFRaw.py</filename></para> | ||
28 | </listitem> | ||
29 | </itemizedlist> | ||
30 | |||
31 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
32 | |||
33 | <itemizedlist> | ||
34 | <listitem> | ||
35 | <para>Add the VNF Image in the <literal>vnf_image</literal> folder | ||
36 | in the QCOW2 format: <programlisting><AF-TH-install-dir>/vnf_image/<VNF-Image-name>.qcow2</programlisting></para> | ||
37 | </listitem> | ||
38 | |||
39 | <listitem> | ||
40 | <para>A VNF Image JSON configuration file is created: | ||
41 | <programlisting><AF-TH-install-dir>/vnf_config/<VNF-Descriptor-name>/<VNF-Descriptor-name>.json</programlisting><emphasis | ||
42 | role="bold">Example:</emphasis><programlisting><AF-TH-install-dir>/vnf_config/fortigateImage/fortigateImage.json</programlisting></para> | ||
43 | </listitem> | ||
44 | </itemizedlist> | ||
45 | |||
46 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
47 | <filename>onboardVNFImage.yml</filename> Ansible Playbook with the | ||
48 | <literal><VNF-Image-name></literal> and the | ||
49 | <literal><VNF-Descriptor-name></literal> as extra-vars: | ||
50 | <programlisting>ansible-playbook playbooks/onboardVNFImage.yml -e "vnfb=<VNF-Image-name> \ | ||
51 | vnfd=<VNF-Descriptor-name>"</programlisting></para> | ||
52 | |||
53 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
54 | run using the Test Harness:<programlisting># Onboard VNF Image task result | ||
55 | <VNF-Descriptor-name> successfully onboarded!</programlisting><emphasis | ||
56 | role="bold">Note:</emphasis> The test will not fail if the VNF Image is | ||
57 | already onboarded. The output will instead contain: <programlisting># debug <VNF-Descriptor-name> already onboarded!</programlisting></para> | ||
58 | </section> | ||
59 | |||
60 | <section id="offb_vnf"> | ||
61 | <title>VNF - Offboard a VNF</title> | ||
62 | |||
63 | <para><emphasis role="bold">Description:</emphasis> Removing a VNF | ||
64 | Descriptor from the Enea Edge Management. For details please refer to:</para> | ||
65 | |||
66 | <itemizedlist> | ||
67 | <listitem> | ||
68 | <para><filename><AF-TH-install-dir>/playbooks/offboardVNF.yml</filename></para> | ||
69 | </listitem> | ||
70 | |||
71 | <listitem> | ||
72 | <para><filename><AF-TH-install-dir>/automation_framework/vnf/offboardVNF.py</filename></para> | ||
73 | </listitem> | ||
74 | </itemizedlist> | ||
75 | |||
76 | <para><emphasis role="bold">Precondition:</emphasis> The VNF has been | ||
77 | previously onboarded in the Enea Edge Management instance.</para> | ||
78 | |||
79 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
80 | <filename>offboardVNF.yml</filename> Ansible Playbook with the | ||
81 | <literal><VNF-Descriptor-name></literal> as extra-vars: | ||
82 | <programlisting>ansible-playbook playbooks/offboardVNF.yml -e "vnfd=<VNF-Descriptor-name>"</programlisting></para> | ||
83 | |||
84 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
85 | run using the Test Harness: <programlisting># Remove Descriptor task result | ||
86 | <VNF-Descriptor-name> was removed!</programlisting><emphasis | ||
87 | role="bold">Note:</emphasis> The test will not fail if the VNF | ||
88 | Descriptor does not exist. The output will instead contain: | ||
89 | <programlisting># debug No Descriptor with name <VNF-Descriptor-name>!</programlisting></para> | ||
90 | </section> | ||
91 | |||
92 | <section id="add_device"> | ||
93 | <title>Device - Add a device</title> | ||
94 | |||
95 | <para><emphasis role="bold">Description:</emphasis> Adding a uCPE device | ||
96 | to the Enea Edge Management. For details please refer to:</para> | ||
97 | |||
98 | <itemizedlist> | ||
99 | <listitem> | ||
100 | <para><filename><AF-TH-install-dir>/playbooks/addDevice.yml</filename></para> | ||
101 | </listitem> | ||
102 | |||
103 | <listitem> | ||
104 | <para><filename><AF-TH-install-dir>/automation_framework/device/addDevice.py</filename></para> | ||
105 | </listitem> | ||
106 | </itemizedlist> | ||
107 | |||
108 | <para><emphasis role="bold">Precondition:</emphasis> A device JSON | ||
109 | configuration file must be created: <programlisting><filename><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</filename></programlisting></para> | ||
110 | |||
111 | <para><emphasis role="bold">Example:</emphasis> <programlisting><AF-TH-install-dir>/lab_config/intelc3850-2/intelc3850-2.json</programlisting></para> | ||
112 | |||
113 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
114 | <filename>addDevice.yml</filename> Ansible playbook with the | ||
115 | <filename><Device-name></filename> as extra-vars: <programlisting>ansible-playbook playbooks/addDevice.yml -e "device=<Device-name>"</programlisting></para> | ||
116 | |||
117 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
118 | run using the Test Harness: <programlisting># Add Device task result | ||
119 | <Device-name> device was added!</programlisting><emphasis | ||
120 | role="bold">Note:</emphasis> The test will not fail if the device | ||
121 | already exists. The output will instead contain: <programlisting># debug | ||
122 | <Device-name> device already exists!</programlisting></para> | ||
123 | </section> | ||
124 | |||
125 | <section id="device_upload_image"> | ||
126 | <title>Device - Upload a Edge image</title> | ||
127 | |||
128 | <para><emphasis role="bold">Description:</emphasis> Upload a Edge | ||
129 | image file onto the Enea Edge Management. For details please refer to:</para> | ||
130 | |||
131 | <itemizedlist> | ||
132 | <listitem> | ||
133 | <para><filename><AF-TH-install-dir>/playbooks/uploadImage.yml</filename></para> | ||
134 | </listitem> | ||
135 | |||
136 | <listitem> | ||
137 | <para><filename><AF-TH-install-dir>/automation_framework/device/uploadImage.py</filename></para> | ||
138 | </listitem> | ||
139 | </itemizedlist> | ||
140 | |||
141 | <para><emphasis role="bold">Precondition:</emphasis> The image path must | ||
142 | already exist.</para> | ||
143 | |||
144 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
145 | <filename>uploadImage.yml</filename> Ansible playbook with the | ||
146 | <filename><Image-path></filename> and | ||
147 | <filename><Upgrade-type></filename> as extra-vars:</para> | ||
148 | |||
149 | <para><programlisting>ansible-playbook playbooks/deleteUpgradeFile.yml -e \ | ||
150 | image_path="<Image-path>" -e upgrade_type="<Upgrade-type>"</programlisting></para> | ||
151 | |||
152 | <para><emphasis role="bold">Example:</emphasis> <programlisting>ansible-playbook playbooks/uploadImage.yml -e \ | ||
153 | image_path="/tmp/enea-nfv-access-xeon-d6.rootfs.ostree.tar.bz2" -e \ | ||
154 | upgrade_type="xeon_d"</programlisting></para> | ||
155 | |||
156 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
157 | run using the Test Harness:</para> | ||
158 | |||
159 | <para><programlisting>TASK [Upload NFVA image -- Run uploadImage.py module from automation_framework] | ||
160 | localhost : ok=1 changed=1 unreachable=0 failed=0</programlisting><emphasis | ||
161 | role="bold">Note:</emphasis> The test will fail if the image file has | ||
162 | already been uploaded.</para> | ||
163 | |||
164 | <para><programlisting>TASK [Upload NFVA image -- Run uploadImage.py module from automation_framework] | ||
165 | ok=0 changed=0 unreachable=0 failed=1 | ||
166 | |||
167 | # debug | ||
168 | A file with the same name is already uploaded.</programlisting></para> | ||
169 | </section> | ||
170 | |||
171 | <section id="dev_del_upgrade"> | ||
172 | <title>Device - Delete Upgraded File</title> | ||
173 | |||
174 | <para><emphasis role="bold">Description:</emphasis> Deleting an uploaded | ||
175 | Edge image file from the Enea Edge Management. For details please refer | ||
176 | to:</para> | ||
177 | |||
178 | <itemizedlist> | ||
179 | <listitem> | ||
180 | <para><filename><AF-TH-install-dir>/playbooks/deleteUpgradeFile.yml</filename></para> | ||
181 | </listitem> | ||
182 | |||
183 | <listitem> | ||
184 | <para><filename><AF-TH-install-dir>/automation_framework/device/deleteUpgradeFile.py</filename></para> | ||
185 | </listitem> | ||
186 | </itemizedlist> | ||
187 | |||
188 | <para><emphasis role="bold">Preconditions:</emphasis> The image file | ||
189 | must already be uploaded onto the Enea Edge Management.</para> | ||
190 | |||
191 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
192 | <filename>deleteUpgradeFile.yml</filename> Ansible Playbook with the | ||
193 | <literal><Image-name></literal> as extra-vars:<programlisting>ansible-playbook playbooks/deleteUpgradeFile.yml -e \ | ||
194 | image_name="<Image-name>"</programlisting></para> | ||
195 | |||
196 | <para><emphasis role="bold">Example:</emphasis> <programlisting>ansible-playbook playbooks/deleteUpgradeFile.yml -e \ | ||
197 | image_name="enea-nfv-access-xeon-d.rootfs.ostree.tar.bz2"</programlisting></para> | ||
198 | |||
199 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
200 | run using the Test Harness:<programlisting>TASK [Remove NFVA image -- Run deleteUpgradeFile.py module from automation_framework] | ||
201 | localhost : ok=1 changed=1 unreachable=0 failed=0</programlisting> | ||
202 | <emphasis role="bold">Note:</emphasis> The test will fail if the image | ||
203 | file does not exist: <programlisting>TASK [Remove NFVA image -- Run deleteUpgradeFile.py module from automation_framework] | ||
204 | ok=0 changed=0 unreachable=0 failed=1 | ||
205 | |||
206 | # debug | ||
207 | No oid found for '<image_name>' image name</programlisting></para> | ||
208 | </section> | ||
209 | |||
210 | <section id="dev_clear_info"> | ||
211 | <title>Device - Clear information about upgrades of uCPE devices</title> | ||
212 | |||
213 | <para><emphasis role="bold">Description:</emphasis> Clear information | ||
214 | about upgrades of uCPE devices. For details please refer to:</para> | ||
215 | |||
216 | <itemizedlist> | ||
217 | <listitem> | ||
218 | <para><filename><AF-TH-install-dir>/playbooks/clearCompletedUpgradesInfo.yml</filename></para> | ||
219 | </listitem> | ||
220 | |||
221 | <listitem> | ||
222 | <para><filename><AF-TH-install-dir>/automation_framework/device/clearCompletedUpgradesInfo.py</filename></para> | ||
223 | </listitem> | ||
224 | </itemizedlist> | ||
225 | |||
226 | <para><emphasis role="bold">Preconditions:</emphasis> No preconditions | ||
227 | needed.</para> | ||
228 | |||
229 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
230 | <filename>clearCompletedUpgradesInfo.yml</filename> Ansible | ||
231 | Playbook:<programlisting>ansible-playbook playbooks/clearCompletedUpgradesInfo.yml</programlisting></para> | ||
232 | |||
233 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
234 | run using the Test Harness:<programlisting>TASK [Clear completed info about upgrading -- Run \ | ||
235 | clearCompletedUpgradesInfo.py module from automation framework]] | ||
236 | localhost : ok=1 changed=1 unreachable=0 failed=0</programlisting></para> | ||
237 | </section> | ||
238 | |||
239 | <section id="dev_inst_activ"> | ||
240 | <title>Device - Install and Activate a Edge image</title> | ||
241 | |||
242 | <para><emphasis role="bold">Description:</emphasis> Installing and | ||
243 | Activating a Edge image on a uCPE device from the Enea Edge Management. | ||
244 | For details please refer to:</para> | ||
245 | |||
246 | <itemizedlist> | ||
247 | <listitem> | ||
248 | <para><filename><AF-TH-install-dir>/playbooks/installAndActivate.yml</filename></para> | ||
249 | </listitem> | ||
250 | |||
251 | <listitem> | ||
252 | <para><filename><AF-TH-install-dir>/automation_framework/device/installAndActivate.py</filename></para> | ||
253 | </listitem> | ||
254 | </itemizedlist> | ||
255 | |||
256 | <para><emphasis role="bold">Preconditions:</emphasis> <itemizedlist> | ||
257 | <listitem> | ||
258 | <para>The device must be previously added to the Enea Edge Management | ||
259 | instance.</para> | ||
260 | </listitem> | ||
261 | |||
262 | <listitem> | ||
263 | <para>The image file must already be uploaded onto the Enea Edge | ||
264 | Management.</para> | ||
265 | </listitem> | ||
266 | </itemizedlist></para> | ||
267 | |||
268 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
269 | <filename>installAndActivate.yml</filename> Ansible Playbook with the | ||
270 | <literal><Image-name></literal>, | ||
271 | <literal><Upgrade-type></literal>, and the | ||
272 | <literal><Device-name></literal> as extra-vars:<programlisting>ansible-playbook playbooks/installAndActivate.yml -e \ | ||
273 | image_name="<Image_name>" -e upgrade_type="<Upgrade_type>" -e \ | ||
274 | device="<Device-name>"</programlisting></para> | ||
275 | |||
276 | <para><emphasis role="bold">Example:</emphasis> <programlisting>ansible-playbook playbooks/installAndActivate.yml -e \ | ||
277 | image_name="enea-nfv-access-xeon-d6.rootfs.ostree.tar.bz2" -e \ | ||
278 | upgrade_type=xeon_d -e device=inteld1521-16"</programlisting></para> | ||
279 | |||
280 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
281 | run using the Test Harness:<programlisting>TASK \ | ||
282 | [Install And Activate -- Run installAndActivate.py module from automation_framework] | ||
283 | localhost : ok=1 changed=1 unreachable=0 failed=0</programlisting> | ||
284 | <emphasis role="bold">Note:</emphasis> The test will fail if the image | ||
285 | has already been installed on the uCPE device:<programlisting>TASK \ | ||
286 | [Install And Activate -- Run installAndActivate.py module from automation_framework] | ||
287 | ok=0 changed=0 unreachable=0 failed=1 | ||
288 | |||
289 | # debug | ||
290 | Duplicate entry - Release already installed</programlisting></para> | ||
291 | </section> | ||
292 | |||
293 | <section id="dev_upload_inst_activ"> | ||
294 | <title>Device - Upload, Install and Activate a Edge image on a | ||
295 | uCPE device</title> | ||
296 | |||
297 | <para><emphasis role="bold">Description:</emphasis> Upload, install and | ||
298 | activate a Edge image on a uCPE device from the Enea Edge Management. For | ||
299 | details please refer to:</para> | ||
300 | |||
301 | <itemizedlist> | ||
302 | <listitem> | ||
303 | <para><filename><AF-TH-install-dir>/playbooks/installNFVAImage.yml</filename></para> | ||
304 | </listitem> | ||
305 | |||
306 | <listitem> | ||
307 | <para>The playbook imports the previously described | ||
308 | playbooks:</para> | ||
309 | |||
310 | <itemizedlist spacing="compact"> | ||
311 | <listitem> | ||
312 | <para><filename>playbooks/waitDeviceUp.yml</filename></para> | ||
313 | </listitem> | ||
314 | |||
315 | <listitem> | ||
316 | <para><filename>playbook/uploadImage.yml</filename></para> | ||
317 | </listitem> | ||
318 | |||
319 | <listitem> | ||
320 | <para><filename>playbook/installAndActivate.yml</filename></para> | ||
321 | </listitem> | ||
322 | |||
323 | <listitem> | ||
324 | <para><filename>playbook/deleteUpgradeFile.yml</filename></para> | ||
325 | </listitem> | ||
326 | |||
327 | <listitem> | ||
328 | <para><filename>playbook/clearCompletedUpgradesInfo.yml</filename></para> | ||
329 | </listitem> | ||
330 | </itemizedlist> | ||
331 | </listitem> | ||
332 | </itemizedlist> | ||
333 | |||
334 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
335 | |||
336 | <itemizedlist> | ||
337 | <listitem> | ||
338 | <para>The device has to be previously added to the Enea Edge Management | ||
339 | instance.</para> | ||
340 | </listitem> | ||
341 | |||
342 | <listitem> | ||
343 | <para>A device JSON configuration file must be created:</para> | ||
344 | |||
345 | <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</programlisting> | ||
346 | </listitem> | ||
347 | </itemizedlist> | ||
348 | |||
349 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
350 | <filename>installNFVAImage.yml</filename> Ansible Playbook with the | ||
351 | <literal><Image-path></literal>, | ||
352 | <literal><Image-name></literal>, | ||
353 | <literal><Upgrade-type></literal>, and the | ||
354 | <literal><Device-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/installNFVAImage.yml -e \ | ||
355 | device="<Device-name>" -e image_path="<Image-path>" -e \ | ||
356 | image_name="<Image-name>" -e upgrade_type="<Upgrade-type>"</programlisting></para> | ||
357 | |||
358 | <para><emphasis role="bold">Example:</emphasis> <programlisting>ansible-playbook playbooks/installNFVAImage.yml -e \ | ||
359 | device="inteld1521-16" -e \ | ||
360 | image_path=/tmp/enea-nfv-access-xeon-d5.rootfs.ostree.tar.bz2 -e \ | ||
361 | image_name=enea-nfv-access-xeon-d5.rootfs.ostree.tar.bz2 -e \ | ||
362 | upgrade_type=xeon_d</programlisting></para> | ||
363 | |||
364 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
365 | run using the Test Harness:<programlisting>localhost : ok=1 changed=1 unreachable=0 failed=0</programlisting> | ||
366 | <emphasis role="bold">Note:</emphasis> The test will fail if the one | ||
367 | imported playbook fails:<programlisting>ok=0 changed=0 unreachable=0 failed=1</programlisting></para> | ||
368 | </section> | ||
369 | |||
370 | <section id="wait_dev"> | ||
371 | <title>Device - Wait a Device</title> | ||
372 | |||
373 | <para><emphasis role="bold">Description:</emphasis> Wait for a uCPE | ||
374 | device to connect to the Enea Edge Management. For details please refer | ||
375 | to:</para> | ||
376 | |||
377 | <itemizedlist> | ||
378 | <listitem> | ||
379 | <para><filename><AF-TH-install-dir>/playbooks/waitDeviceUp.yml</filename></para> | ||
380 | </listitem> | ||
381 | |||
382 | <listitem> | ||
383 | <para><filename><AF-TH-install-dir>/automation_framework/device/waitDeviceUp.py</filename></para> | ||
384 | </listitem> | ||
385 | </itemizedlist> | ||
386 | |||
387 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
388 | |||
389 | <itemizedlist> | ||
390 | <listitem> | ||
391 | <para>The device has to be previously added to the Enea Edge Management | ||
392 | instance.</para> | ||
393 | </listitem> | ||
394 | |||
395 | <listitem> | ||
396 | <para>The device JSON configuration file must exist: | ||
397 | <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</programlisting></para> | ||
398 | </listitem> | ||
399 | </itemizedlist> | ||
400 | |||
401 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
402 | <filename>waitDeviceUp.yml</filename> Ansible Playbook with the | ||
403 | <literal><Device-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/waitDeviceUp.yml -e "device=<Device-name>"</programlisting></para> | ||
404 | |||
405 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
406 | run using the Test Harness:<programlisting># Wait Device task result | ||
407 | <Device-name> device is connected!</programlisting> <emphasis | ||
408 | role="bold">Note:</emphasis> The test will fail if the device does not | ||
409 | exist or it is not connected.</para> | ||
410 | </section> | ||
411 | |||
412 | <section id="remv_dev"> | ||
413 | <title>Device - Remove a Device</title> | ||
414 | |||
415 | <para><emphasis role="bold">Description:</emphasis> Removing a uCPE | ||
416 | device from the Enea Edge Management. For details please refer to:</para> | ||
417 | |||
418 | <itemizedlist> | ||
419 | <listitem> | ||
420 | <para><filename><AF-TH-install-dir>/playbooks/removeDevice.yml</filename></para> | ||
421 | </listitem> | ||
422 | |||
423 | <listitem> | ||
424 | <para><filename><AF-TH-install-dir>/automation_framework/device/removeDevice.py</filename></para> | ||
425 | </listitem> | ||
426 | </itemizedlist> | ||
427 | |||
428 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
429 | |||
430 | <itemizedlist> | ||
431 | <listitem> | ||
432 | <para>The device has to be previously added to the Enea Edge Management | ||
433 | instance.</para> | ||
434 | </listitem> | ||
435 | |||
436 | <listitem> | ||
437 | <para>The device JSON configuration file must exist: | ||
438 | <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</programlisting></para> | ||
439 | </listitem> | ||
440 | </itemizedlist> | ||
441 | |||
442 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
443 | <filename>removeDevice.yml</filename> Ansible Playbook with the | ||
444 | <literal><Device-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/removeDevice.yml -e "device=<Device-name>"</programlisting></para> | ||
445 | |||
446 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
447 | run using the Test Harness:<programlisting># Remove Device task result | ||
448 | <Device-name> device was removed!</programlisting> <emphasis | ||
449 | role="bold">Note:</emphasis> The test will not fail if the device does | ||
450 | not exist. The output will contain: <programlisting># debug | ||
451 | <Device-name> device was not found!</programlisting></para> | ||
452 | </section> | ||
453 | |||
454 | <section id="bind_nic"> | ||
455 | <title>Network - Bind a NIC</title> | ||
456 | |||
457 | <para><emphasis role="bold">Description:</emphasis> Binding a physical | ||
458 | network interface (NIC) to a device. For details please refer to:</para> | ||
459 | |||
460 | <itemizedlist> | ||
461 | <listitem> | ||
462 | <para><filename><AF-TH-install-dir>/playbooks/bindNIC.yml</filename></para> | ||
463 | </listitem> | ||
464 | |||
465 | <listitem> | ||
466 | <para><filename><AF-TH-install-dir>/automation_framework/network/bindNetworkInterface.py</filename></para> | ||
467 | </listitem> | ||
468 | </itemizedlist> | ||
469 | |||
470 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
471 | |||
472 | <itemizedlist> | ||
473 | <listitem> | ||
474 | <para>A device must have been previously added and connected to the | ||
475 | Enea Edge Management instance.</para> | ||
476 | </listitem> | ||
477 | |||
478 | <listitem> | ||
479 | <para>A NIC JSON configuration file must exist: <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<NIC>.json</programlisting></para> | ||
480 | |||
481 | <para><emphasis role="bold">Example:</emphasis> <programlisting><AF-TH-install-dir>/lab_config/intelc3850-2/wan_nic.json | ||
482 | <AF-TH-install-dir>/lab_config/intelc3850-2/lan_nic.json</programlisting></para> | ||
483 | </listitem> | ||
484 | </itemizedlist> | ||
485 | |||
486 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
487 | <filename>bindNIC.yml</filename> Ansible Playbook with the | ||
488 | <literal><Device-name></literal> and | ||
489 | <literal><NIC></literal> as extra-vars: <programlisting>ansible-playbook playbooks/bindNIC.yml -e "device=<Device-name> nic=<NIC>"</programlisting></para> | ||
490 | |||
491 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
492 | run using the Test Harness:<programlisting># Bind NIC task result | ||
493 | <NIC> binded successfully!</programlisting> <emphasis | ||
494 | role="bold">Note:</emphasis> The test will not fail if the NIC is | ||
495 | already bound, it will be unbound and bound again with the provided | ||
496 | configuration.</para> | ||
497 | </section> | ||
498 | |||
499 | <section id="unbind_nic"> | ||
500 | <title>Network - Unbind a NIC</title> | ||
501 | |||
502 | <para><emphasis role="bold">Description:</emphasis> Unbinding a physical | ||
503 | network interface (NIC) from a device. For details please refer | ||
504 | to:</para> | ||
505 | |||
506 | <itemizedlist> | ||
507 | <listitem> | ||
508 | <para><filename><AF-TH-install-dir>/playbooks/unbindNIC.yml</filename></para> | ||
509 | </listitem> | ||
510 | |||
511 | <listitem> | ||
512 | <para><filename><AF-TH-install-dir>/automation_framework/network/unbindNetworkInterface.py</filename></para> | ||
513 | </listitem> | ||
514 | </itemizedlist> | ||
515 | |||
516 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
517 | |||
518 | <itemizedlist> | ||
519 | <listitem> | ||
520 | <para>A NIC is bound to a device in a Enea Edge Management instance.</para> | ||
521 | </listitem> | ||
522 | |||
523 | <listitem> | ||
524 | <para>A NIC JSON configuration file exists: <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<NIC>.json</programlisting></para> | ||
525 | </listitem> | ||
526 | </itemizedlist> | ||
527 | |||
528 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
529 | <filename>unbindNIC.yml</filename> Ansible Playbook with the | ||
530 | <literal><Device-name></literal> and | ||
531 | <literal><NIC></literal> as extra-vars: <programlisting>ansible-playbook playbooks/unbindNIC.yml -e "device=<Device-name> nic=<NIC>"</programlisting></para> | ||
532 | |||
533 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
534 | run using the Test Harness: <programlisting># Unbind NIC task result | ||
535 | <NIC> unbinded!</programlisting> <emphasis role="bold">Note:</emphasis> | ||
536 | The test will not fail if the NIC is not bound. The output will instead | ||
537 | contain:<programlisting># debug | ||
538 | <NIC> is not binded!</programlisting></para> | ||
539 | </section> | ||
540 | |||
541 | <section id="create_bri"> | ||
542 | <title>Network - Create a Bridge</title> | ||
543 | |||
544 | <para><emphasis role="bold">Description:</emphasis> Creating an OVS | ||
545 | network bridge on a uCPE device. For details please refer to:</para> | ||
546 | |||
547 | <itemizedlist> | ||
548 | <listitem> | ||
549 | <para><filename><AF-TH-install-dir>/playbooks/addBridge.yml</filename></para> | ||
550 | </listitem> | ||
551 | |||
552 | <listitem> | ||
553 | <para><filename><AF-TH-install-dir>/automation_framework/network/newNetworkBridge.py</filename></para> | ||
554 | </listitem> | ||
555 | </itemizedlist> | ||
556 | |||
557 | <para><emphasis role="bold">Preconditions:</emphasis><itemizedlist> | ||
558 | <listitem> | ||
559 | <para>A NIC is bound to a device in a Enea Edge Management | ||
560 | instance.</para> | ||
561 | </listitem> | ||
562 | |||
563 | <listitem> | ||
564 | <para>A Bridge JSON configuration file exists:<programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<Bridge-name>.json</programlisting></para> | ||
565 | |||
566 | <para><emphasis role="bold">Example:</emphasis><programlisting><AF-TH-install-dir>/lab_config/intelc3850-2/wan_br.json | ||
567 | <AF-TH-install-dir>/lab_config/intelc3850-2/lan_br.json</programlisting></para> | ||
568 | </listitem> | ||
569 | </itemizedlist></para> | ||
570 | |||
571 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
572 | <filename>addBridge.yml</filename> Ansible Playbook with the | ||
573 | <literal><Device-name></literal> and the | ||
574 | <literal><Bridge-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/addBridge.yml -e "device=<Device-name> bridge=<Bridge-name>"</programlisting></para> | ||
575 | |||
576 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
577 | run using the Test Harness: <programlisting># Add Bridge task result | ||
578 | <Bridge-name> network bridge was added!</programlisting><emphasis | ||
579 | role="bold">Note:</emphasis> The test will not fail if there already | ||
580 | exists a bridge with the same name. It will be deleted and the bridge | ||
581 | will be created again with the provided configuration.</para> | ||
582 | </section> | ||
583 | |||
584 | <section id="remov_bri"> | ||
585 | <title>Network - Remove a Bridge</title> | ||
586 | |||
587 | <para><emphasis role="bold">Description:</emphasis> Removing an OVS | ||
588 | network bridge from a uCPE device. For details please refer to:</para> | ||
589 | |||
590 | <itemizedlist> | ||
591 | <listitem> | ||
592 | <para><filename><AF-TH-install-dir>/playbooks/deleteBridge.yml</filename></para> | ||
593 | </listitem> | ||
594 | |||
595 | <listitem> | ||
596 | <para><filename><AF-TH-install-dir>/automation_framework/network/delNetworkBridge.py</filename></para> | ||
597 | </listitem> | ||
598 | </itemizedlist> | ||
599 | |||
600 | <para><emphasis role="bold">Preconditions:</emphasis><itemizedlist> | ||
601 | <listitem> | ||
602 | <para>A Bridge exists for a device in a Enea Edge Management | ||
603 | instance.</para> | ||
604 | </listitem> | ||
605 | |||
606 | <listitem> | ||
607 | <para>A Bridge JSON configuration file exists: <programlisting><AF-TH-install-dir>/lab_config/<Device-name>/<Bridge-name>.json</programlisting></para> | ||
608 | </listitem> | ||
609 | </itemizedlist><emphasis role="bold">Action:</emphasis> Run the | ||
610 | <filename>deleteBridge.yml</filename> Ansible Playbook with the | ||
611 | <literal><Device-name></literal> and the | ||
612 | <literal><Bridge-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/deleteBridge.yml -e "device=<Device-name> \ | ||
613 | bridge=<Bridge-name>"</programlisting></para> | ||
614 | |||
615 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
616 | run using the Test Harness: <programlisting># Delete Bridge task result | ||
617 | <Bridge-name> network bridge was deleted!</programlisting><emphasis | ||
618 | role="bold">Note:</emphasis> The test will not fail if the bridge does | ||
619 | not exist: <programlisting># debug | ||
620 | <Bridge-name> bridge not found!</programlisting></para> | ||
621 | </section> | ||
622 | |||
623 | <section id="config_dpdk"> | ||
624 | <title>Network - Configure a DPDK</title> | ||
625 | |||
626 | <para><emphasis role="bold">Description:</emphasis> Enabling or | ||
627 | Disabling the DPDK support in OVS. For details please refer to:</para> | ||
628 | |||
629 | <itemizedlist> | ||
630 | <listitem> | ||
631 | <para><filename><AF-TH-install-dir>/playbooks/configDPDK.yml</filename>.</para> | ||
632 | </listitem> | ||
633 | |||
634 | <listitem> | ||
635 | <para><filename><AF-TH-install-dir>/automation_framework/network/configDPDK.py</filename>.</para> | ||
636 | </listitem> | ||
637 | </itemizedlist> | ||
638 | |||
639 | <para><emphasis role="bold">Precondition: </emphasis></para> | ||
640 | |||
641 | <para>A device must have been previously added and connected to the Enea Edge | ||
642 | Management instance.</para> | ||
643 | |||
644 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
645 | <filename>configDPDK.yml</filename> Ansible Playbook with the | ||
646 | <literal><Device-name></literal> and | ||
647 | <literal><enable/disable></literal> as extra-vars:<programlisting>ansible-playbook playbooks/configDPDK.yml -e "device=<Device-name> \ | ||
648 | state=<enable/disable>"</programlisting></para> | ||
649 | |||
650 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
651 | run using the Test Harness:</para> | ||
652 | |||
653 | <para><programlisting># Configure DPDK task result | ||
654 | DEBUG: Set DPDK state to <enable/disable></programlisting><emphasis | ||
655 | role="bold">Note:</emphasis> DPDK use cannot be disabled if DPDK | ||
656 | interfaces are configured. The task will fail in this case.</para> | ||
657 | </section> | ||
658 | |||
659 | <section id="cs_upload"> | ||
660 | <title>Custom Scripts - Upload a Custom Script to the Enea Edge | ||
661 | Management</title> | ||
662 | |||
663 | <para><emphasis role="bold">Description:</emphasis> Upload a Custom | ||
664 | Script to the Enea Edge Management. For details please refer to:</para> | ||
665 | |||
666 | <itemizedlist> | ||
667 | <listitem> | ||
668 | <para><filename><AF-TH-install-dir>/playbooks/uploadCustomScript.yml</filename>.</para> | ||
669 | </listitem> | ||
670 | |||
671 | <listitem> | ||
672 | <para><filename><AF-TH-install-dir>/automation_framework/customScripts/upload.py</filename>.</para> | ||
673 | </listitem> | ||
674 | </itemizedlist> | ||
675 | |||
676 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
677 | |||
678 | <para><literal><AF-TH-install-dir>/lab_config/customScripts</literal> | ||
679 | must contain a Custom Script file.</para> | ||
680 | |||
681 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
682 | <filename>uploadCustomScript.yml</filename> Ansible Playbook with the | ||
683 | <literal><scriptName></literal> and | ||
684 | <literal><phase></literal> as extra-vars: <programlisting>ansible-playbook playbooks/uploadCustomScript.yml -e "scriptName=<scriptName> \ | ||
685 | phase= | ||
686 | <always-after-startup|once-after-startup|always-before-startup|once-before-startup>"</programlisting></para> | ||
687 | |||
688 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
689 | run using the Test Harness:</para> | ||
690 | |||
691 | <programlisting># Upload Custom Script task result | ||
692 | DEBUG: "{{ scriptName }} was uploaded to Enea Edge Management!"</programlisting> | ||
693 | </section> | ||
694 | |||
695 | <section id="cs_upload_device"> | ||
696 | <title>Custom Scripts - Upload a Custom Script from the Enea Edge Management to | ||
697 | a Device</title> | ||
698 | |||
699 | <para><emphasis role="bold">Description:</emphasis> Upload a Custom | ||
700 | Script from the Enea Edge Management to a Device. For details please refer | ||
701 | to:</para> | ||
702 | |||
703 | <itemizedlist> | ||
704 | <listitem> | ||
705 | <para><filename><AF-TH-install-dir>/playbooks/uploadCustomScriptOnDevice.yml</filename>.</para> | ||
706 | </listitem> | ||
707 | |||
708 | <listitem> | ||
709 | <para><filename><AF-TH-install-dir>/automation_framework/customScripts/uploadOnDevice.py</filename>.</para> | ||
710 | </listitem> | ||
711 | </itemizedlist> | ||
712 | |||
713 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
714 | |||
715 | <itemizedlist> | ||
716 | <listitem> | ||
717 | <para>A device must have been previously added and connected to the | ||
718 | Enea Edge Management instance.</para> | ||
719 | </listitem> | ||
720 | |||
721 | <listitem> | ||
722 | <para>A Custom Script must have been previously added to the Enea Edge | ||
723 | Management instance.</para> | ||
724 | </listitem> | ||
725 | </itemizedlist> | ||
726 | |||
727 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
728 | <filename>uploadCustomScriptOnDevice.yml</filename> Ansible Playbook | ||
729 | with the <literal><scriptName></literal>, | ||
730 | <literal><phase></literal> and | ||
731 | <literal><deviceName></literal> as extra-vars: <programlisting>ansible-playbook playbooks/uploadCustomScriptOnDevice.yml -e "scriptName=<scriptName> \ | ||
732 | phase= | ||
733 | <always-after-startup|once-after-startup|always-before-startup|once-before-startup> \ | ||
734 | device=<deviceName>"</programlisting></para> | ||
735 | |||
736 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
737 | run using the Test Harness:</para> | ||
738 | |||
739 | <programlisting># Upload Custom Script on Device task result | ||
740 | DEBUG: "{{ scriptName }} was uploaded to {{ device }}!"</programlisting> | ||
741 | </section> | ||
742 | |||
743 | <section id="cs_remove"> | ||
744 | <title>Custom Scripts - Remove a Custom Script from the Enea Edge | ||
745 | Management</title> | ||
746 | |||
747 | <para><emphasis role="bold">Description:</emphasis> Remove a Custom | ||
748 | Script from the Enea Edge Management. For details please refer to:</para> | ||
749 | |||
750 | <itemizedlist> | ||
751 | <listitem> | ||
752 | <para><filename><AF-TH-install-dir>/playbooks/removeCustomScript.yml</filename>.</para> | ||
753 | </listitem> | ||
754 | |||
755 | <listitem> | ||
756 | <para><filename><AF-TH-install-dir>/automation_framework/customScripts/delete.py</filename>.</para> | ||
757 | </listitem> | ||
758 | </itemizedlist> | ||
759 | |||
760 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
761 | |||
762 | <para>A Custom Script must have been previously added to the Enea Edge | ||
763 | Management.</para> | ||
764 | |||
765 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
766 | <filename>removeCustomScript.yml</filename> Ansible Playbook with the | ||
767 | <literal><scriptName></literal> and | ||
768 | <literal><phase></literal> as extra-vars: <programlisting>ansible-playbook playbooks/removeCustomScript.yml -e "scriptName=<scriptName> \ | ||
769 | phase= | ||
770 | <always-after-startup|once-after-startup|always-before-startup|once-before-startup>"</programlisting></para> | ||
771 | |||
772 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
773 | run using the Test Harness:</para> | ||
774 | |||
775 | <programlisting># Remove Custom Script in phase from Enea Edge Management task result | ||
776 | DEBUG: "{{ scriptName }} from phase {{ phase }} was removed from Enea Edge Management!"</programlisting> | ||
777 | </section> | ||
778 | |||
779 | <section id="cs_remove_device"> | ||
780 | <title>Custom Scripts - Remove a Custom Script from a Device</title> | ||
781 | |||
782 | <para><emphasis role="bold">Description:</emphasis> Remove a Custom | ||
783 | Script from a Device. For details please refer to:</para> | ||
784 | |||
785 | <itemizedlist> | ||
786 | <listitem> | ||
787 | <para><filename><AF-TH-install-dir>/playbooks/removeCustomScriptOnDevice.yml</filename>.</para> | ||
788 | </listitem> | ||
789 | |||
790 | <listitem> | ||
791 | <para><filename><AF-TH-install-dir>/automation_framework/customScripts/deleteOnDevice.py</filename>.</para> | ||
792 | </listitem> | ||
793 | </itemizedlist> | ||
794 | |||
795 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
796 | |||
797 | <itemizedlist> | ||
798 | <listitem> | ||
799 | <para>A device must have been previously added and connected to the | ||
800 | Enea Edge Management instance.</para> | ||
801 | </listitem> | ||
802 | |||
803 | <listitem> | ||
804 | <para>A Custom Script must have been previously added to the | ||
805 | Device.</para> | ||
806 | </listitem> | ||
807 | </itemizedlist> | ||
808 | |||
809 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
810 | <filename>removeCustomScriptOnDevice.yml</filename> Ansible Playbook | ||
811 | with the <literal><scriptName></literal>, | ||
812 | <literal><phase></literal> and | ||
813 | <literal><deviceName></literal> as extra-vars: <programlisting>ansible-playbook playbooks/removeCustomScriptOnDevice.yml -e "scriptName=<scriptName> \ | ||
814 | phase= | ||
815 | <always-after-startup|once-after-startup|always-before-startup|once-before-startup> \ | ||
816 | device=<deviceName>"</programlisting></para> | ||
817 | |||
818 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
819 | run using the Test Harness:</para> | ||
820 | |||
821 | <programlisting># Remove Custom Script in phase from Device task result | ||
822 | DEBUG: "{{ scriptName }} from phase {{ phase }} was removed from {{ device }}!"</programlisting> | ||
823 | </section> | ||
824 | |||
825 | <section id="add_offline_config"> | ||
826 | <title>Offline Configuration - Add an Offline Configuration | ||
827 | Store</title> | ||
828 | |||
829 | <para><emphasis role="bold">Description:</emphasis> Adding an Offline | ||
830 | Config Store to the Enea Edge Management. For details please refer to:</para> | ||
831 | |||
832 | <itemizedlist> | ||
833 | <listitem> | ||
834 | <para><filename><AF-TH-install-dir>/playbooks/addConfigStore.yml</filename>.</para> | ||
835 | </listitem> | ||
836 | |||
837 | <listitem> | ||
838 | <para><filename><AF-TH-install-dir>/automation_framework/device/addConfigStore.py</filename>.</para> | ||
839 | </listitem> | ||
840 | </itemizedlist> | ||
841 | |||
842 | <para><emphasis role="bold">Precondition:</emphasis><itemizedlist> | ||
843 | <listitem> | ||
844 | <para>The Offline Configuration Store should not already exist on | ||
845 | the Enea Edge Management. If it exists, the test will report a | ||
846 | duplicate.</para> | ||
847 | </listitem> | ||
848 | |||
849 | <listitem> | ||
850 | <para>A store JSON file needs to exist: <programlisting><AF-TH-install-dir>/lab_config/<device-name>/store.json</programlisting></para> | ||
851 | </listitem> | ||
852 | </itemizedlist></para> | ||
853 | |||
854 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
855 | <filename>addConfigStore.yml</filename> Ansible Playbook with the | ||
856 | <literal><device-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/addConfigStore.yml -e \ | ||
857 | "device=<device-name>"</programlisting></para> | ||
858 | |||
859 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
860 | run using the Test Harness:</para> | ||
861 | |||
862 | <programlisting># Add Config Store task result | ||
863 | ********************************************************** | ||
864 | ********************************** | ||
865 | * localhost - changed=False | ||
866 | -------------------------------------------------- | ||
867 | Config store for intelc3850-2 device was added!</programlisting> | ||
868 | </section> | ||
869 | |||
870 | <section id="remove_offline_config"> | ||
871 | <title>Offline Configuration - Remove an Offline Configuration | ||
872 | Store</title> | ||
873 | |||
874 | <para><emphasis role="bold">Description:</emphasis> Removing an Offline | ||
875 | Config Store from the Enea Edge Management. For details please refer to:</para> | ||
876 | |||
877 | <itemizedlist> | ||
878 | <listitem> | ||
879 | <para><filename><AF-TH-install-dir>/playbooks/removeConfigStore.yml</filename>.</para> | ||
880 | </listitem> | ||
881 | |||
882 | <listitem> | ||
883 | <para><filename><AF-TH-install-dir>/automation_framework/device/removeConfigStore.py</filename>.</para> | ||
884 | </listitem> | ||
885 | </itemizedlist> | ||
886 | |||
887 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
888 | |||
889 | <para>The Offline Configuration Store the user wishes to remove should | ||
890 | exist in the Enea Edge Management. If it does not, the test will say so.</para> | ||
891 | |||
892 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
893 | <filename>removeConfigStore.yml</filename> Ansible Playbook with the | ||
894 | <literal><store-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/removeConfigStore.yml -e \ | ||
895 | "store=<store-name>"</programlisting></para> | ||
896 | |||
897 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
898 | run using the Test Harness:</para> | ||
899 | |||
900 | <programlisting># Remove Config Store task result ********************************** | ||
901 | ******************************************************* | ||
902 | * localhost - changed=False | ||
903 | -- intelc3850-2 config store was removed! ---------</programlisting> | ||
904 | </section> | ||
905 | |||
906 | <section id="offline_config_add_bridge"> | ||
907 | <title>Offline Configuration - Add a network bridge to an Offline | ||
908 | Configuration Store</title> | ||
909 | |||
910 | <para><emphasis role="bold">Description:</emphasis> Adding a network | ||
911 | bridge to an Offline Config Store in Enea Edge Management. For details please | ||
912 | refer to:</para> | ||
913 | |||
914 | <itemizedlist> | ||
915 | <listitem> | ||
916 | <para><filename><AF-TH-install-dir>/playbooks/addOfflineBridge.yml</filename>.</para> | ||
917 | </listitem> | ||
918 | |||
919 | <listitem> | ||
920 | <para><filename><AF-TH-install-dir>/automation_framework/network/newNetworkBridge.py</filename>.</para> | ||
921 | </listitem> | ||
922 | </itemizedlist> | ||
923 | |||
924 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
925 | |||
926 | <itemizedlist> | ||
927 | <listitem> | ||
928 | <para>The Offline Configuration Store should exist in the Enea Edge | ||
929 | Management. If it does not, the test will say so.</para> | ||
930 | </listitem> | ||
931 | |||
932 | <listitem> | ||
933 | <para>A Bridge JSON configuration file needs to exist: | ||
934 | <programlisting><AF-TH-install-dir>/lab_config/<device-name>/<bridge-name>.json</programlisting></para> | ||
935 | </listitem> | ||
936 | </itemizedlist> | ||
937 | |||
938 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
939 | <filename>addOfflineBridge.yml</filename> Ansible Playbook with the | ||
940 | <literal><device-name></literal>, | ||
941 | <literal><store-name></literal> and | ||
942 | <literal><bridge-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/addOfflineBridge.yml -e \ | ||
943 | "device=<device-name> store=<store-name> bridge=<bridge-name>"</programlisting></para> | ||
944 | |||
945 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
946 | run using the Test Harness:</para> | ||
947 | |||
948 | <programlisting># debug ************************************************************* | ||
949 | ****************************************************** | ||
950 | * localhost - changed=False | ||
951 | -------------------------------------------------- | ||
952 | lan_br bridge already exists | ||
953 | --- will be deleted to create it with the provided configuration | ||
954 | .. | ||
955 | # Add Bridge task result ******************************************** | ||
956 | ****************************************************** | ||
957 | * localhost - changed=False | ||
958 | -- lan_br network bridge was added! ------------</programlisting> | ||
959 | |||
960 | <para><emphasis role="bold">Note:</emphasis> if the bridge exists, it | ||
961 | will be removed and then re-added, as the output above shows.</para> | ||
962 | </section> | ||
963 | |||
964 | <section id="offline_config_dpdk"> | ||
965 | <title>Offline Configuration - Configure a DPDK</title> | ||
966 | |||
967 | <para><emphasis role="bold">Description:</emphasis> Adding an "enable" | ||
968 | or "disable" DPDK state to an Offline Config Store. For details please | ||
969 | refer to:</para> | ||
970 | |||
971 | <itemizedlist> | ||
972 | <listitem> | ||
973 | <para><filename><AF-TH-install-dir>/playbooks/configOfflineDPDK.yml</filename>.</para> | ||
974 | </listitem> | ||
975 | |||
976 | <listitem> | ||
977 | <para><filename><AF-TH-install-dir>/automation_framework/network/configDPDK.py</filename>.</para> | ||
978 | </listitem> | ||
979 | </itemizedlist> | ||
980 | |||
981 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
982 | |||
983 | <para>An empty Offline Configuration Store should exist in Enea Edge | ||
984 | Management.</para> | ||
985 | |||
986 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
987 | <filename>configOfflineDPDK.yml</filename> Ansible Playbook with the | ||
988 | <literal><store-name></literal> and | ||
989 | <literal><enable/disable></literal> as extra-vars: | ||
990 | <programlisting>ansible-playbook playbooks/configOfflineDPDK.yml -e \ | ||
991 | "store=<store-name> state=<enable/disable>"</programlisting></para> | ||
992 | |||
993 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
994 | run using the Test Harness:</para> | ||
995 | |||
996 | <programlisting>DEBUG: Set DPDK state to disable | ||
997 | INFO: Done</programlisting> | ||
998 | |||
999 | <para><emphasis role="bold">Note:</emphasis> the DPDK state cannot be | ||
1000 | changed. Recreate the Offline Config Store and set the DPDK again if you | ||
1001 | want to change the state.</para> | ||
1002 | </section> | ||
1003 | |||
1004 | <section id="offline_config_ucpe"> | ||
1005 | <title>Offline Configuration - Upload an offline configuration onto a | ||
1006 | uCPE Device</title> | ||
1007 | |||
1008 | <para><emphasis role="bold">Description:</emphasis> Uploading an offline | ||
1009 | configuration to a uCPE Device. For details please refer to:</para> | ||
1010 | |||
1011 | <itemizedlist> | ||
1012 | <listitem> | ||
1013 | <para><filename><AF-TH-install-dir>/playbooks/uploadConfigStore.yml</filename>.</para> | ||
1014 | </listitem> | ||
1015 | |||
1016 | <listitem> | ||
1017 | <para><filename><AF-TH-install-dir>/automation_framework/device/uploadConfigStore.py</filename>.</para> | ||
1018 | </listitem> | ||
1019 | </itemizedlist> | ||
1020 | |||
1021 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
1022 | |||
1023 | <itemizedlist> | ||
1024 | <listitem> | ||
1025 | <para>The Offline Configuration Store should exist in the Enea Edge | ||
1026 | Management.</para> | ||
1027 | </listitem> | ||
1028 | |||
1029 | <listitem> | ||
1030 | <para>The device should be connected to the Enea Edge Management.</para> | ||
1031 | </listitem> | ||
1032 | </itemizedlist> | ||
1033 | |||
1034 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1035 | <filename>uploadConfigStore.yml</filename> Ansible Playbook with the | ||
1036 | <literal><store-name></literal> and | ||
1037 | <literal><device-name></literal> as extra-vars:</para> | ||
1038 | |||
1039 | <programlisting>ansible-playbook playbooks/uploadConfigStore.yml -e \ | ||
1040 | "store=<store-name> device=<device-name>"</programlisting> | ||
1041 | |||
1042 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1043 | run using the Test Harness:</para> | ||
1044 | |||
1045 | <programlisting># Upload Config Store task result **************************** | ||
1046 | * localhost - changed=False --------------- | ||
1047 | 2020-10-08 13:29:41,062 - INFO: Upload offline \ | ||
1048 | configuration to uCPE Device | ||
1049 | 2020-10-08 13:30:01,315 - INFO: The '<store-name>' config \ | ||
1050 | store was successfully uploaded on device! | ||
1051 | 2020-10-08 13:30:01,316 - INFO: Done</programlisting> | ||
1052 | </section> | ||
1053 | |||
1054 | <section id="offline_config_status"> | ||
1055 | <title>Offline Configuration - Get the offline configuration upload | ||
1056 | status on the uCPE Device</title> | ||
1057 | |||
1058 | <para><emphasis role="bold">Description:</emphasis> Get the offline | ||
1059 | configuration upload status to a uCPE Device. For details please refer | ||
1060 | to:</para> | ||
1061 | |||
1062 | <itemizedlist> | ||
1063 | <listitem> | ||
1064 | <para><filename><AF-TH-install-dir>/playbooks/getUploadStatus.yml</filename>.</para> | ||
1065 | </listitem> | ||
1066 | |||
1067 | <listitem> | ||
1068 | <para><filename><AF-TH-install-dir>/automation_framework/device/getUploadStatus.py</filename>.</para> | ||
1069 | </listitem> | ||
1070 | </itemizedlist> | ||
1071 | |||
1072 | <para><emphasis role="bold">Precondition:</emphasis></para> | ||
1073 | |||
1074 | <itemizedlist> | ||
1075 | <listitem> | ||
1076 | <para>An upload of the offline configuration should be done on the | ||
1077 | uCPE Device.</para> | ||
1078 | </listitem> | ||
1079 | |||
1080 | <listitem> | ||
1081 | <para>The device should be connected to the Enea Edge Management.</para> | ||
1082 | </listitem> | ||
1083 | </itemizedlist> | ||
1084 | |||
1085 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1086 | <filename>getUploadStatus.yml</filename> Ansible Playbook with the | ||
1087 | <literal><device-name></literal> as extra-vars:</para> | ||
1088 | |||
1089 | <programlisting>ansible-playbook playbooks/getUploadStatus.yml -e \ | ||
1090 | "device=<device-name>"</programlisting> | ||
1091 | |||
1092 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1093 | run using the Test Harness:</para> | ||
1094 | |||
1095 | <programlisting># Upload Config Store task result **************************** | ||
1096 | * localhost - changed=False --------------- | ||
1097 | 2020-10-08 14:13:24,422 - INFO: Get upload offline configure \ | ||
1098 | status on uCPE Device | ||
1099 | 2020-10-08 14:13:24,521 - INFO: Successful: True | ||
1100 | 2020-10-08 14:13:24,522 - INFO: Store name: <store-name> | ||
1101 | 2020-10-08 14:13:24,523 - INFO: In progress: False | ||
1102 | 2020-10-08 14:13:24,524 - INFO: A config store was successfully \ | ||
1103 | uploaded on device! | ||
1104 | 2020-10-08 14:13:24,525 - INFO: Done</programlisting> | ||
1105 | </section> | ||
1106 | </section> | ||
1107 | |||
1108 | <section id="vnf_deploy_lifecycle"> | ||
1109 | <title>VNF Deployment and Lifecycle</title> | ||
1110 | |||
1111 | <para>The following details the automated suite that handles the testing | ||
1112 | of the instantiation, lifecycle and destruction of a VNF for Enea Edge.</para> | ||
1113 | |||
1114 | <section id="inst_vnfi"> | ||
1115 | <title>Instantiating a VNFI</title> | ||
1116 | |||
1117 | <para><emphasis role="bold">Description:</emphasis> Creating a VNF | ||
1118 | instance on a uCPE device. For details please refer to:</para> | ||
1119 | |||
1120 | <itemizedlist> | ||
1121 | <listitem> | ||
1122 | <para><filename><AF-TH-install-dir>/playbooks/instantiateVNFI.yml</filename></para> | ||
1123 | </listitem> | ||
1124 | |||
1125 | <listitem> | ||
1126 | <para><filename><AF-TH-install-dir>/automation_framework/vnf/instantiateVNFI.py</filename></para> | ||
1127 | </listitem> | ||
1128 | </itemizedlist> | ||
1129 | |||
1130 | <para><emphasis role="bold">Preconditions:</emphasis> <itemizedlist> | ||
1131 | <listitem> | ||
1132 | <para>A VNF Image is onboarded and a device is added and connected | ||
1133 | to the Enea Edge Management. Depending on the VNF, other steps may be | ||
1134 | required.</para> | ||
1135 | </listitem> | ||
1136 | |||
1137 | <listitem> | ||
1138 | <para>A VNFI JSON configuration file exists: <programlisting><AF-TH-install-dir>/vnf_config/<VNF-Descriptor-name>/<VNFI-name>.json</programlisting></para> | ||
1139 | |||
1140 | <para><emphasis role="bold">Example:</emphasis> <programlisting><AF-TH-install-dir>/vnf_config/fortigateImage/fortigateFWInstance.json</programlisting></para> | ||
1141 | </listitem> | ||
1142 | </itemizedlist></para> | ||
1143 | |||
1144 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1145 | <filename>instantiateVNFI.yml</filename> Ansible Playbook with the | ||
1146 | <literal><Device-name></literal>, | ||
1147 | <literal><VNF-Descriptor-name></literal> and the | ||
1148 | <literal><VNFI-name></literal> as extra-vars: <programlisting>ansible-playbook playbooks/instantiateVNFI.yml -e "device=<Device-name> \ | ||
1149 | vnfd=<VNF-Descriptor-name> vnfi=<VNFI-name>"</programlisting></para> | ||
1150 | |||
1151 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1152 | run using the Test Harness: <programlisting># Instantiate VNF task result | ||
1153 | <VNFI-name> was instantiated!</programlisting><emphasis | ||
1154 | role="bold">Note:</emphasis> The test will not fail if the VNF instance | ||
1155 | already exists. The output will instead contain: <programlisting># debug | ||
1156 | <VNFI-name> already exists!</programlisting></para> | ||
1157 | </section> | ||
1158 | |||
1159 | <section id="control_vnfi"> | ||
1160 | <title>Controlling a VNFI</title> | ||
1161 | |||
1162 | <para><emphasis role="bold">Description:</emphasis> Changing the status | ||
1163 | of a VNF instance (Pause, Resume, Stop, Start). For details please refer | ||
1164 | to:</para> | ||
1165 | |||
1166 | <itemizedlist> | ||
1167 | <listitem> | ||
1168 | <para><filename><AF-TH-install-dir>/playbooks/controlVNFI.yml</filename></para> | ||
1169 | </listitem> | ||
1170 | |||
1171 | <listitem> | ||
1172 | <para><filename><AF-TH-install-dir>/automation_framework/vnf/controlVNFI.py</filename></para> | ||
1173 | </listitem> | ||
1174 | </itemizedlist> | ||
1175 | |||
1176 | <para><emphasis role="bold">Precondition:</emphasis> A VNF is | ||
1177 | instantiated on a uCPE device.</para> | ||
1178 | |||
1179 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1180 | <filename>controlVNFI.yml</filename> Ansible Playbook with the | ||
1181 | <literal><Device-name></literal>, | ||
1182 | <literal><VNFI-name></literal> and the | ||
1183 | <literal><Command></literal> as extra-vars: <programlisting>ansible-playbook playbooks/controlVNFI.yml -e "device=<Device-name> \ | ||
1184 | vnfi=<VNFI-name> status=<pause|resume|start|stop>"</programlisting></para> | ||
1185 | |||
1186 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1187 | run using the Test Harness: <programlisting># Change VNFI Status task result | ||
1188 | <VNFI-name> status was set to <Command></programlisting><emphasis | ||
1189 | role="bold">Note:</emphasis> The test will not fail if the VNF instance | ||
1190 | does not exist or if the specified command is not valid. Depending on | ||
1191 | the case, the output will contain: <programlisting># debug | ||
1192 | <VNFI-name> was not found!</programlisting>or<programlisting># debug | ||
1193 | Invalid VNF Instance control command specified - <Command></programlisting></para> | ||
1194 | </section> | ||
1195 | |||
1196 | <section id="destroy_vnfi"> | ||
1197 | <title>Destroying a VNFI</title> | ||
1198 | |||
1199 | <para><emphasis role="bold">Description:</emphasis> Destroying a VNF | ||
1200 | instance from a uCPE device. For details please refer to:</para> | ||
1201 | |||
1202 | <itemizedlist> | ||
1203 | <listitem> | ||
1204 | <para><filename><AF-TH-install-dir>/playbooks/destroyVNFI.yml</filename></para> | ||
1205 | </listitem> | ||
1206 | |||
1207 | <listitem> | ||
1208 | <para><filename><AF-TH-install-dir>/automation_framework/vnf/destroyVNFI.py</filename></para> | ||
1209 | </listitem> | ||
1210 | </itemizedlist> | ||
1211 | |||
1212 | <para><emphasis role="bold">Precondition:</emphasis> A VNF is | ||
1213 | instantiated on a uCPE device.</para> | ||
1214 | |||
1215 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1216 | <filename>destroyVNFI.yml</filename> Ansible Playbook with the | ||
1217 | <literal><Device-name></literal> and the | ||
1218 | <filename><VNFI-name></filename> as extra-vars: <programlisting>ansible-playbook playbooks/destroyVNFI.yml -e "device=<Device-name> \ | ||
1219 | vnfi=<VNFI-name>"</programlisting><emphasis | ||
1220 | role="bold">Result:</emphasis> Output of the test case run using the | ||
1221 | Test Harness:<programlisting># Destroy VNFI task result | ||
1222 | <VNFI-name> was destroyed!</programlisting><emphasis | ||
1223 | role="bold">Note:</emphasis> The test will not fail if the VNF instance | ||
1224 | does not exist. The output will instead contain: <programlisting># debug | ||
1225 | <VNFI-name> was not found!</programlisting></para> | ||
1226 | </section> | ||
1227 | </section> | ||
1228 | |||
1229 | <section id="serv_creat_lifecycle"> | ||
1230 | <title>Service Creation and Lifecycle</title> | ||
1231 | |||
1232 | <para>This test suite contains more complex test cases designed to verify | ||
1233 | service creation and service lifecycle management. These test cases also | ||
1234 | serve as examples of how different services can be deployed using the | ||
1235 | Automation Framework (AF) and the Test Harness (TH).</para> | ||
1236 | |||
1237 | <section id="fortigate_firewall"> | ||
1238 | <title>Fortigate VNF as a Firewall</title> | ||
1239 | |||
1240 | <para>This test case was implemented in two different ways to exemplify | ||
1241 | both methods supported by the AF and TH to deploy such services.</para> | ||
1242 | |||
1243 | <para><emphasis role="bold">How to deploy the FortiGate VNF as a | ||
1244 | Firewall:</emphasis></para> | ||
1245 | |||
1246 | <orderedlist> | ||
1247 | <listitem> | ||
1248 | <para>Add a uCPE device.</para> | ||
1249 | </listitem> | ||
1250 | |||
1251 | <listitem> | ||
1252 | <para>Wait for the uCPE device to be connected in the Enea Edge | ||
1253 | Management.</para> | ||
1254 | </listitem> | ||
1255 | |||
1256 | <listitem> | ||
1257 | <para>Onboard the FortiGate VNF Image.</para> | ||
1258 | </listitem> | ||
1259 | |||
1260 | <listitem> | ||
1261 | <para>Bind 2 physical interfaces: <literal>wan_nic</literal> (this | ||
1262 | physical interface has to be connected to the Lab Network) and | ||
1263 | <literal>lan_nic</literal>.</para> | ||
1264 | </listitem> | ||
1265 | |||
1266 | <listitem> | ||
1267 | <para>Create 2 bridges: <literal>wan_br</literal> (using the | ||
1268 | <literal>wan_nic</literal> interface) and <literal>lan_br</literal> | ||
1269 | (using the <literal>lan_nic</literal> interface).</para> | ||
1270 | </listitem> | ||
1271 | |||
1272 | <listitem> | ||
1273 | <para>Instantiate the FortiGate VNF using the basic Firewall | ||
1274 | configuration provided with your Enea Edge Release, and the | ||
1275 | Fortigate License file.</para> | ||
1276 | |||
1277 | <note> | ||
1278 | <para>Please contact the local Fortinet sales representatives in | ||
1279 | your region to get the Fortigate License file.</para> | ||
1280 | </note> | ||
1281 | </listitem> | ||
1282 | </orderedlist> | ||
1283 | |||
1284 | <para>For more information please refer to section <olink | ||
1285 | targetdoc="book_enea_edge_example_usecases" | ||
1286 | targetptr="fortigate_firewall_uc_1">FortiGate VNF as a Firewall in the | ||
1287 | <xi:include href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
1288 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
1289 | xpointer="element(book_enea_edge_example_usecases/1)" /></olink> | ||
1290 | Manual.</para> | ||
1291 | |||
1292 | <section id="fortigate_fw_instance"> | ||
1293 | <title>FortigateFWInstance Test</title> | ||
1294 | |||
1295 | <para><emphasis role="bold">Description:</emphasis> Instantiate the | ||
1296 | FortiGate VNF as a Firewall and test it using an isolated network | ||
1297 | namespace.</para> | ||
1298 | |||
1299 | <para>This example was implemented with the "Test Harness" method, | ||
1300 | based on Ansible Playbooks. For details please refer to:</para> | ||
1301 | |||
1302 | <itemizedlist> | ||
1303 | <listitem> | ||
1304 | <para><filename><AF-TH-install-dir>/playbooks/fortigateFWService/instantiateFortigateFW.yml</filename></para> | ||
1305 | </listitem> | ||
1306 | |||
1307 | <listitem> | ||
1308 | <para><filename><AF-TH-install-dir>/playbooks/fortigateFWService/testFortigateFWInstance.yml</filename></para> | ||
1309 | </listitem> | ||
1310 | |||
1311 | <listitem> | ||
1312 | <para><filename><AF-TH-install-dir>/playbooks/fortigateFWService/cleanupTestFortigateFWInstance.yml</filename></para> | ||
1313 | </listitem> | ||
1314 | |||
1315 | <listitem> | ||
1316 | <para><filename><AF-TH-install-dir>/playbooks/fortigateFWService/cleanupFortigateFWInstance.yml</filename></para> | ||
1317 | </listitem> | ||
1318 | </itemizedlist> | ||
1319 | |||
1320 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
1321 | |||
1322 | <itemizedlist> | ||
1323 | <listitem> | ||
1324 | <para>A device must have been previously added and connected to | ||
1325 | the Enea Edge Management instance.</para> | ||
1326 | </listitem> | ||
1327 | |||
1328 | <listitem> | ||
1329 | <para>Add the Fortigate VNF Image | ||
1330 | (<filename>fortios.qcow2</filename>) to the | ||
1331 | <literal><AF-TH-install-dir>/vnf_image</literal> | ||
1332 | folder.</para> | ||
1333 | </listitem> | ||
1334 | |||
1335 | <listitem> | ||
1336 | <para>The device JSON configuration file is created: | ||
1337 | <filename><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</filename>.</para> | ||
1338 | </listitem> | ||
1339 | |||
1340 | <listitem> | ||
1341 | <para>Add device settings in the <literal>hosts</literal> Ansible | ||
1342 | inventory file under <literal>[fortigateFW]</literal> and remove | ||
1343 | the <filename>intelc3850-2</filename> example.</para> | ||
1344 | |||
1345 | <para><emphasis role="bold">Example:</emphasis> <programlisting>intelc3850-2 ansible_host=172.24.12.114 ansible_port=22 \ | ||
1346 | ansible_user=root ansible_pass=root</programlisting></para> | ||
1347 | </listitem> | ||
1348 | |||
1349 | <listitem> | ||
1350 | <para>NIC JSON configuration files are created:</para> | ||
1351 | |||
1352 | <itemizedlist> | ||
1353 | <listitem> | ||
1354 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_nic.json</filename></para> | ||
1355 | </listitem> | ||
1356 | |||
1357 | <listitem> | ||
1358 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_nic.json</filename></para> | ||
1359 | </listitem> | ||
1360 | </itemizedlist> | ||
1361 | </listitem> | ||
1362 | |||
1363 | <listitem> | ||
1364 | <para>Bridge JSON configuration files are created:</para> | ||
1365 | |||
1366 | <itemizedlist> | ||
1367 | <listitem> | ||
1368 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_br.json</filename></para> | ||
1369 | </listitem> | ||
1370 | |||
1371 | <listitem> | ||
1372 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_br.json</filename></para> | ||
1373 | </listitem> | ||
1374 | </itemizedlist> | ||
1375 | </listitem> | ||
1376 | |||
1377 | <listitem> | ||
1378 | <para>Download the FortiGate VNF Firewall basic configuration file | ||
1379 | from Enea, copy it into the | ||
1380 | <filename><AF-TH-install-dir>/vnf_config/fortigateImage</filename> | ||
1381 | directory and rename it to | ||
1382 | <filename>fortigateFW.conf</filename>.</para> | ||
1383 | </listitem> | ||
1384 | |||
1385 | <listitem> | ||
1386 | <para>Retrieve the FortiGate VNF license file from Fortinet or | ||
1387 | Enea, copy it into the | ||
1388 | <literal><AF-TH-install-dir>/vnf_config/fortigateImage</literal> | ||
1389 | directory and rename it to | ||
1390 | <filename>fortigateLicense.lic</filename>.</para> | ||
1391 | |||
1392 | <para>For more information please refer to section <olink | ||
1393 | targetdoc="book_enea_edge_example_usecases" | ||
1394 | targetptr="fortigate_firewall_uc_1">FortiGate VNF as a Firewall in | ||
1395 | the <xi:include href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
1396 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
1397 | xpointer="element(book_enea_edge_example_usecases/1)" /></olink> | ||
1398 | Manual.</para> | ||
1399 | </listitem> | ||
1400 | </itemizedlist> | ||
1401 | |||
1402 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1403 | <filename>instantiateFortigateFW.yml</filename> Ansible Playbook with | ||
1404 | the <literal><Device-name></literal> as | ||
1405 | extra-vars:<programlisting>ansible-playbook playbooks/fortigateFWService/instantiateFortigateFW.yml \ | ||
1406 | -e "device=<Device-name>"</programlisting></para> | ||
1407 | |||
1408 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1409 | run using the Test Harness: <programlisting># Test FortigateFWInstance task result | ||
1410 | FortigateFWInstance tested successfully!</programlisting></para> | ||
1411 | |||
1412 | <para><emphasis role="bold">Cleanup:</emphasis> Run the | ||
1413 | <filename>cleanupFortigateFWInstance.yml</filename> Ansible Playbook | ||
1414 | with the <literal><Device-name></literal> as extra-vars: | ||
1415 | <programlisting>ansible-playbook playbooks/fortigateFWService/cleanupFortigateFWInstance.yml \ | ||
1416 | -e "device=<Device-name>"</programlisting></para> | ||
1417 | </section> | ||
1418 | |||
1419 | <section id="deploy_fortigate_fw"> | ||
1420 | <title>DeployFortigateFW Scenario</title> | ||
1421 | |||
1422 | <para><emphasis role="bold">Description:</emphasis> Deploy the | ||
1423 | Fortigate VNF as a Firewall. This example was implemented with the | ||
1424 | "Automation Framework" method, based on the | ||
1425 | <filename>unittestSuite.py</filename> Python module.</para> | ||
1426 | |||
1427 | <para>For details please refer to:</para> | ||
1428 | |||
1429 | <itemizedlist> | ||
1430 | <listitem> | ||
1431 | <para><literal><AF-TH-install-dir>/playbooks/unittestSuiteTest/deployFortigateFWScenario.yml</literal></para> | ||
1432 | </listitem> | ||
1433 | |||
1434 | <listitem> | ||
1435 | <para><literal><AF-TH-install-dir>/playbooks/unittestSuiteTest/cleanupFortigateFWScenario.yml</literal></para> | ||
1436 | </listitem> | ||
1437 | |||
1438 | <listitem> | ||
1439 | <para><literal><AF-TH-install-dir>/automation_framework/unittestSuite</literal> | ||
1440 | directory.</para> | ||
1441 | </listitem> | ||
1442 | </itemizedlist> | ||
1443 | |||
1444 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
1445 | |||
1446 | <itemizedlist> | ||
1447 | <listitem> | ||
1448 | <para>A device must have been previously added and connected to | ||
1449 | the Enea Edge Management instance.</para> | ||
1450 | </listitem> | ||
1451 | |||
1452 | <listitem> | ||
1453 | <para>Add the FortiGate VNF Image | ||
1454 | (<filename>fortios.qcow2</filename>) to the | ||
1455 | <literal><AF-TH-install-dir>/vnf_image</literal> | ||
1456 | folder.</para> | ||
1457 | </listitem> | ||
1458 | |||
1459 | <listitem> | ||
1460 | <para>The device JSON configuration file is created:</para> | ||
1461 | |||
1462 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</filename>.</para> | ||
1463 | </listitem> | ||
1464 | |||
1465 | <listitem> | ||
1466 | <para>The NIC JSON configuration files are created:</para> | ||
1467 | |||
1468 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_nic.json</filename></para> | ||
1469 | |||
1470 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_nic.json</filename></para> | ||
1471 | </listitem> | ||
1472 | |||
1473 | <listitem> | ||
1474 | <para>The Bridge JSON configuration files are created:</para> | ||
1475 | |||
1476 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_br.json</filename></para> | ||
1477 | |||
1478 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_br.json</filename></para> | ||
1479 | </listitem> | ||
1480 | |||
1481 | <listitem> | ||
1482 | <para>Download the FortiGate VNF Firewall basic configuration from | ||
1483 | Enea, copy it into the | ||
1484 | <literal><AF-TH-install-dir>/vnf_config/fortigateImage</literal> | ||
1485 | directory and rename it to | ||
1486 | <filename>fortigateFW.conf</filename>.</para> | ||
1487 | </listitem> | ||
1488 | |||
1489 | <listitem> | ||
1490 | <para>Retrieve the FortiGate VNF license file from Fortinet or | ||
1491 | Enea, copy it into the | ||
1492 | <literal><AF-TH-install-dir>/vnf_config/fortigateImage</literal> | ||
1493 | directory and rename it to | ||
1494 | <filename>fortigateLicense.lic</filename>.</para> | ||
1495 | |||
1496 | <para>For more details, please refer to:</para> | ||
1497 | |||
1498 | <itemizedlist> | ||
1499 | <listitem> | ||
1500 | <para><olink targetdoc="book_enea_edge_example_usecases" | ||
1501 | targetptr="fortigate_firewall_uc_1">FortiGate VNF as a | ||
1502 | Firewall in the <xi:include | ||
1503 | href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
1504 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
1505 | xpointer="element(book_enea_edge_example_usecases/1)" /></olink> | ||
1506 | Manual.</para> | ||
1507 | </listitem> | ||
1508 | |||
1509 | <listitem> | ||
1510 | <para><olink | ||
1511 | targetdoc="book_enea_edge_auto_fw_th_user_guide" | ||
1512 | targetptr="python_testsuite">Python Unit-Test Suite in | ||
1513 | <xi:include href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
1514 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
1515 | xpointer="element(book_enea_edge_auto_fw_th_user_guide/1)" /></olink>.</para> | ||
1516 | </listitem> | ||
1517 | </itemizedlist> | ||
1518 | </listitem> | ||
1519 | </itemizedlist> | ||
1520 | |||
1521 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1522 | <filename>deployFortigateFWScenario.yml</filename> Ansible Playbook | ||
1523 | with the <literal><Device-name></literal> as extra-vars: | ||
1524 | <programlisting>ansible-playbook playbooks/unittestSuiteTest/deployFortigateFWScenario.yml \ | ||
1525 | -e "device=<Device-name>"</programlisting></para> | ||
1526 | |||
1527 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1528 | run using the Test Harness: <programlisting># unittestSuite Deploy Test task result | ||
1529 | FortigateFW Scenario deployed successfully!</programlisting></para> | ||
1530 | |||
1531 | <para><emphasis role="bold">Cleanup:</emphasis> Run the | ||
1532 | <filename>cleanupFortigateFWScenario.yml</filename> Ansible Playbook | ||
1533 | with the <literal><Device-name></literal> as extra-vars: | ||
1534 | <programlisting>ansible-playbook playbooks/unittestSuiteTest/cleanupFortigateFWScenario.yml \ | ||
1535 | -e "device=<Device-name>"</programlisting></para> | ||
1536 | </section> | ||
1537 | </section> | ||
1538 | |||
1539 | <section id="chained_vnf"> | ||
1540 | <title>chainedVNFsService</title> | ||
1541 | |||
1542 | <para><emphasis role="bold">Description:</emphasis> This sample test | ||
1543 | case corresponds to the "VNF Chaining Example Use-case" from the Enea | ||
1544 | Edge Example Use-cases manual.</para> | ||
1545 | |||
1546 | <para>For details please refer to:</para> | ||
1547 | |||
1548 | <itemizedlist> | ||
1549 | <listitem> | ||
1550 | <para><filename><AF-TH-install-dir>/playbooks/chainedVNFsService/chainedVNFsService.yml</filename></para> | ||
1551 | </listitem> | ||
1552 | |||
1553 | <listitem> | ||
1554 | <para><filename><AF-TH-install-dir>/playbooks/chainedVNFsService/testChainedVNFsService.yml</filename></para> | ||
1555 | </listitem> | ||
1556 | |||
1557 | <listitem> | ||
1558 | <para><filename><AF-TH-install-dir>/playbooks/chainedVNFsService/cleanupChainedVNFsService.yml</filename></para> | ||
1559 | </listitem> | ||
1560 | </itemizedlist> | ||
1561 | |||
1562 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
1563 | |||
1564 | <itemizedlist> | ||
1565 | <listitem> | ||
1566 | <para>Two devices must have been previously added and connected to | ||
1567 | the Enea Edge Management instance.</para> | ||
1568 | </listitem> | ||
1569 | |||
1570 | <listitem> | ||
1571 | <para>Add the Fortigate VNF Image | ||
1572 | (<filename>fortios.qcow2</filename>) to the | ||
1573 | <literal>vnf_image</literal> folder.</para> | ||
1574 | </listitem> | ||
1575 | |||
1576 | <listitem> | ||
1577 | <para>Add the Juniper vSRX VNF Image | ||
1578 | (<filename>juniper.qcow2</filename>) to the | ||
1579 | <literal>vnf_image</literal> folder.</para> | ||
1580 | </listitem> | ||
1581 | |||
1582 | <listitem> | ||
1583 | <para>The device JSON configuration file(s) is created, e.g.:</para> | ||
1584 | |||
1585 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</filename>.</para> | ||
1586 | </listitem> | ||
1587 | |||
1588 | <listitem> | ||
1589 | <para>Add device settings in the <literal>hosts</literal> Ansible | ||
1590 | inventory file under <literal>[chainedVNFs]</literal>. Keep both | ||
1591 | devices, the "site1" and "site2" entries, and update the values for | ||
1592 | <literal>ansible_host</literal>, <literal>ansible_port</literal>, | ||
1593 | <literal>ansible_user</literal> and <literal>ansible_pass</literal>, | ||
1594 | as applicable.</para> | ||
1595 | |||
1596 | <para><emphasis role="bold">Example:</emphasis></para> | ||
1597 | |||
1598 | <para><programlisting>site1 ansible_host=172.24.14.157 ansible_port=22 ansible_user=root \ | ||
1599 | ansible_pass=root</programlisting></para> | ||
1600 | |||
1601 | <para><programlisting>site2 ansible_host=172.24.14.50 ansible_port=22 ansible_user=root \ | ||
1602 | ansible_pass=root</programlisting></para> | ||
1603 | </listitem> | ||
1604 | |||
1605 | <listitem> | ||
1606 | <para>NIC JSON configuration files are created for each of the | ||
1607 | devices, where <literal>mgmt_nic</literal> is connected to the DHCP | ||
1608 | from the Lab Network and <literal>wan_nic</literal> is connected | ||
1609 | back to back to the other device:</para> | ||
1610 | |||
1611 | <itemizedlist> | ||
1612 | <listitem> | ||
1613 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/mgmt_nic.json</filename></para> | ||
1614 | </listitem> | ||
1615 | |||
1616 | <listitem> | ||
1617 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_nic.json</filename></para> | ||
1618 | </listitem> | ||
1619 | |||
1620 | <listitem> | ||
1621 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_nic.json</filename></para> | ||
1622 | </listitem> | ||
1623 | </itemizedlist> | ||
1624 | </listitem> | ||
1625 | |||
1626 | <listitem> | ||
1627 | <para>Bridge JSON configuration files are created for each of the | ||
1628 | devices:</para> | ||
1629 | |||
1630 | <itemizedlist> | ||
1631 | <listitem> | ||
1632 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/vnf_mgmt_br.json</filename></para> | ||
1633 | </listitem> | ||
1634 | |||
1635 | <listitem> | ||
1636 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/sfc_br.json</filename></para> | ||
1637 | </listitem> | ||
1638 | |||
1639 | <listitem> | ||
1640 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/wan_br.json</filename></para> | ||
1641 | </listitem> | ||
1642 | |||
1643 | <listitem> | ||
1644 | <para><filename><AF-TH-install-dir>/lab_config/<Device-name>/lan_br.json</filename></para> | ||
1645 | </listitem> | ||
1646 | </itemizedlist> | ||
1647 | |||
1648 | <para>Note that sample configuration files needed for devices' NICs | ||
1649 | and bridges can be found in: | ||
1650 | <literal><AF-TH-install-dir>/lab_config/inteld1521-1</literal> | ||
1651 | and | ||
1652 | <literal><AF-TH-install-dir>/lab_config/inteld1521-2</literal>.</para> | ||
1653 | </listitem> | ||
1654 | |||
1655 | <listitem> | ||
1656 | <para>Retrieve the FortiGate VNF Firewall basic configuration files | ||
1657 | from Enea (<filename>FortiFW-Site1.conf</filename> and | ||
1658 | <filename>FortiFW-Site2.conf</filename>), and copy them into the | ||
1659 | <literal><AF-TH-install-dir>/vnf_config/fortigateFWImage</literal> | ||
1660 | directory.</para> | ||
1661 | </listitem> | ||
1662 | |||
1663 | <listitem> | ||
1664 | <para>Retrieve the FortiGate VNF license file from Fortinet or Enea, | ||
1665 | copy it into the | ||
1666 | <literal><AF-TH-install-dir>/vnf_config/fortigateFWImage</literal> | ||
1667 | directory and rename it to | ||
1668 | <filename>fortigateLicense.lic</filename>.</para> | ||
1669 | </listitem> | ||
1670 | |||
1671 | <listitem> | ||
1672 | <para>Retrieve the Juniper vSRX basic configuration files from Enea | ||
1673 | (<filename>vSRX-Site1.iso</filename> and | ||
1674 | <filename>vSRX-Site2.iso</filename>), and copy them into the | ||
1675 | <literal><AF-TH-install-dir>/vnf_config/junipervSRXImage</literal> | ||
1676 | directory.</para> | ||
1677 | </listitem> | ||
1678 | |||
1679 | <listitem> | ||
1680 | <para>Retrieve the <filename>vSRX-domain-update-script</filename> | ||
1681 | from Enea and copy it into the <literal>junipervSRXImage</literal> | ||
1682 | directory.</para> | ||
1683 | |||
1684 | <para>Please refer to the Chapter concerning the <olink | ||
1685 | targetdoc="book_enea_edge_example_usecases" | ||
1686 | targetptr="vnf_chaining">VNF Chaining Example Use-case in the | ||
1687 | <xi:include href="../../s_docbuild/olinkdb/pardoc-names.xml" | ||
1688 | xmlns:xi="http://www.w3.org/2001/XInclude" | ||
1689 | xpointer="element(book_enea_edge_example_usecases/1)" /></olink> | ||
1690 | Manual for additional information about preconditions.</para> | ||
1691 | </listitem> | ||
1692 | </itemizedlist> | ||
1693 | |||
1694 | <para><emphasis role="bold">Action:</emphasis> Run the | ||
1695 | <filename>chainedVNFsService.yml</filename> Ansible Playbook as | ||
1696 | follows:<programlisting>ansible-playbook playbooks/chainedVNFsService/chainedVNFsService.yml \ | ||
1697 | -e "site1=inteld1521-1 site2=inteld1521-2 arch=XeonD"</programlisting></para> | ||
1698 | |||
1699 | <para>Note that "arch" may either be { XeonD | AtomC } depending on the | ||
1700 | target set chosen.</para> | ||
1701 | |||
1702 | <para><emphasis role="bold">Result:</emphasis> Output of the test case | ||
1703 | run using the Test Harness: <programlisting># testChainedVNFsService task result | ||
1704 | ****************************************************************************** | ||
1705 | * site1 - changed=False ---------------------------------------------- | ||
1706 | ---- | ||
1707 | <site1_lan-ip> ---> <site2_lan-ip> | ||
1708 | LAN-to-LAN connectivity (through VPN tunnel)tested successfully!</programlisting></para> | ||
1709 | |||
1710 | <para><emphasis role="bold">Cleanup:</emphasis> Run the | ||
1711 | <filename>cleanupChainedVNFsService.yml</filename> Ansible Playbook as | ||
1712 | follows: <programlisting>ansible-playbook playbooks/chainedVNFsService/cleanupChainedVNFsService.yml \ | ||
1713 | -e "site1=inteld1521-1 site2=inteld1521-2 arch=XeonD"</programlisting></para> | ||
1714 | </section> | ||
1715 | </section> | ||
1716 | |||
1717 | <section id="custom_scripts_bt"> | ||
1718 | <title>Custom Scripts - Basic Test</title> | ||
1719 | |||
1720 | <para>The basic test script can be found in | ||
1721 | <literal><AF-TH-install-dir>/playbooks/customScripts/basicTest.yml</literal>.</para> | ||
1722 | |||
1723 | <para>The <filename>basicTest.yml</filename> script requires the following | ||
1724 | steps:</para> | ||
1725 | |||
1726 | <orderedlist spacing="compact"> | ||
1727 | <listitem> | ||
1728 | <para>Upload a Custom Script onto the Enea Edge Management.</para> | ||
1729 | </listitem> | ||
1730 | |||
1731 | <listitem> | ||
1732 | <para>Upload the Custom Script onto a Device.</para> | ||
1733 | </listitem> | ||
1734 | |||
1735 | <listitem> | ||
1736 | <para>Reboot the Device.</para> | ||
1737 | </listitem> | ||
1738 | |||
1739 | <listitem> | ||
1740 | <para>Wait for the Device to be up and running.</para> | ||
1741 | </listitem> | ||
1742 | |||
1743 | <listitem> | ||
1744 | <para>Remove the Custom Script from the Device.</para> | ||
1745 | </listitem> | ||
1746 | |||
1747 | <listitem> | ||
1748 | <para>Remove the Custom Script from the Enea Edge Management.</para> | ||
1749 | </listitem> | ||
1750 | </orderedlist> | ||
1751 | |||
1752 | <para><emphasis role="bold">Preconditions:</emphasis></para> | ||
1753 | |||
1754 | <itemizedlist> | ||
1755 | <listitem> | ||
1756 | <para>A device must have been previously added and connected to the | ||
1757 | Enea Edge Management.</para> | ||
1758 | </listitem> | ||
1759 | |||
1760 | <listitem> | ||
1761 | <para>The device JSON configuration file must have been created: | ||
1762 | <filename><AF-TH-install-dir>/lab_config/<Device-name>/<Device-name>.json</filename>.</para> | ||
1763 | </listitem> | ||
1764 | |||
1765 | <listitem> | ||
1766 | <para>The custom script should have been previously saved in | ||
1767 | <literal><AF-TH-install-dir>/lab_config/customScripts</literal>.</para> | ||
1768 | </listitem> | ||
1769 | |||
1770 | <listitem> | ||
1771 | <para>Add device settings in the <literal>hosts</literal> Ansible inventory file under | ||
1772 | <literal>[customScriptDevice]</literal> and remove the <literal>inteld1521-1</literal> | ||
1773 | example.</para> | ||
1774 | </listitem> | ||
1775 | </itemizedlist> | ||
1776 | |||
1777 | <para><emphasis role="bold">Example:</emphasis></para> | ||
1778 | |||
1779 | <programlisting>[customScriptDevice] | ||
1780 | inteld1521-1 ansible_host=172.24.12.73 ansible_port=22 ansible_user=root \ | ||
1781 | ansible_pass=root</programlisting> | ||
1782 | |||
1783 | <para><emphasis role="bold">Action:</emphasis> Run | ||
1784 | <filename>basicTest.yml</filename> (example data for | ||
1785 | <filename>test_success_after_always</filename>):</para> | ||
1786 | |||
1787 | <programlisting>ansible-playbook playbooks/customScripts/basicTest.yml -e "device=<Device-name>" \ | ||
1788 | -e "scriptName=test_success_after_always" -e "phase=always-after-startup" \ | ||
1789 | -e "expectedStatus=success"</programlisting> | ||
1790 | |||
1791 | <para><emphasis role="bold">Result:</emphasis> Output of | ||
1792 | <filename>basicTest.yml</filename>:</para> | ||
1793 | |||
1794 | <programlisting>test_success_after_always was uploaded to Enea Edge Management! | ||
1795 | test_success_after_always was uploaded to <Device-name>! | ||
1796 | |||
1797 | <Device-name> device is connected! | ||
1798 | test_success_after_always from phase always-after-startup was removed \ | ||
1799 | from <Device-name>! | ||
1800 | |||
1801 | test_success_after_always from phase always-after-startup was removed \ | ||
1802 | from Enea Edge Management!</programlisting> | ||
1803 | </section> | ||
1804 | </chapter> \ No newline at end of file | ||