<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Issues to create my First Playbook on a VM-500 Virtual Palo Alto Firewall in Automation/API Discussions</title>
    <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/issues-to-create-my-first-playbook-on-a-vm-500-virtual-palo-alto/m-p/512668#M3098</link>
    <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/210381"&gt;@fersherls&lt;/a&gt;&amp;nbsp;, as you have probably noticed Ansible logging messages could be a little more helpful. It looks like the way you're calling your variables within the playbook is problematic.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you encapsulate some text within double curly braces, you need the text to be the name of a variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this example, we encapsulate the word "example" between braces, and this will allow us to call forward the value of an object with that name&lt;/P&gt;
&lt;PRE&gt; {{ example }}&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So in the&amp;nbsp;original, we see that you're trying to store the value of objects in curly braces. this will confuse Ansible, which will look for a variable named 1.1.1.1 and set the value of that object to `ip_address`&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ip_address: '{{ 1.1.1.1 }}'
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;should look like this instead.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ip_address: '1.1.1.1'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;additional issue with the username and password you're calling, as &lt;A title="docs" href="https://docs.ansible.com/ansible/latest/user_guide/playbooks_variables.html#:~:text=advanced%20variable%20syntax-,Creating%20valid%20variable%20names,cannot%20begin%20with%20a%20number." target="_self"&gt;Ansible requires that a variable name begin with a string&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;username:   '{{ 111111111 | default(omit) }}'
password:   '{{ 111111111 | default(omit) }}'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;should look like either of these, with the first example calling for the values of objects named &lt;EM&gt;my_username_variable&lt;/EM&gt; and &lt;EM&gt;my_password_variable.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;username:   '{{ my_username_variable | default(omit) }}'
password:   '{{ my_password_variable | default(omit) }}'

username:   'admin'
password:   'password123'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please let me know if this helps,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Calvin&lt;/P&gt;</description>
    <pubDate>Tue, 23 Aug 2022 13:06:09 GMT</pubDate>
    <dc:creator>cremsburg</dc:creator>
    <dc:date>2022-08-23T13:06:09Z</dc:date>
    <item>
      <title>Issues to create my First Playbook on a VM-500 Virtual Palo Alto Firewall</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/issues-to-create-my-first-playbook-on-a-vm-500-virtual-palo-alto/m-p/511456#M3091</link>
      <description>&lt;P&gt;Hello Palo Alto Community&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I've been trying to make work my first Playbook in ansible, to pretty much whatever it works, right now Im trying to create a test address object, but I kept geeting what it looks like, a syntax error this is the configuration of my playbook.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The image attached is the error im seeing(Looks like connection to the device is established correctly, is just that something maybe syntax is wrong.), do you have any idea what I might be missing?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks in Advance&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Galaxy was install correctly&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;ansible-galaxy collection install paloaltonetworks.panos&lt;/PRE&gt;
&lt;P&gt;This is exactly the playbook configuration.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;hosts:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;DEV&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;connection:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;local&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;vars:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;device:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;ip_address:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'{{ 1.1.1.1 }}'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;username: &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'{{ 111111111 | default(omit) }}'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;password: &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'{{ 111111111 | default(omit) }}'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;api_key: &amp;nbsp; &amp;nbsp;'{{ supersecretkey | default(omit) }}'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;tasks&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; -&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;name:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Create address object&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;panos_address_object:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;provider:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'{{ device }}'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;name:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'Hello-World'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;value:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'1.1.1.1'&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;description:&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;'Test'&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;collections&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; -&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;paloaltonetworks.panos&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;Please note you are posting a public message where community members and experts can provide assistance. Sharing private information such as serial numbers or company information is not recommended.</description>
      <pubDate>Wed, 10 Aug 2022 15:50:54 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/issues-to-create-my-first-playbook-on-a-vm-500-virtual-palo-alto/m-p/511456#M3091</guid>
      <dc:creator>fersherls</dc:creator>
      <dc:date>2022-08-10T15:50:54Z</dc:date>
    </item>
    <item>
      <title>Re: Issues to create my First Playbook on a VM-500 Virtual Palo Alto Firewall</title>
      <link>https://live.paloaltonetworks.com/t5/automation-api-discussions/issues-to-create-my-first-playbook-on-a-vm-500-virtual-palo-alto/m-p/512668#M3098</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://live.paloaltonetworks.com/t5/user/viewprofilepage/user-id/210381"&gt;@fersherls&lt;/a&gt;&amp;nbsp;, as you have probably noticed Ansible logging messages could be a little more helpful. It looks like the way you're calling your variables within the playbook is problematic.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you encapsulate some text within double curly braces, you need the text to be the name of a variable.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this example, we encapsulate the word "example" between braces, and this will allow us to call forward the value of an object with that name&lt;/P&gt;
&lt;PRE&gt; {{ example }}&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So in the&amp;nbsp;original, we see that you're trying to store the value of objects in curly braces. this will confuse Ansible, which will look for a variable named 1.1.1.1 and set the value of that object to `ip_address`&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ip_address: '{{ 1.1.1.1 }}'
&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;should look like this instead.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ip_address: '1.1.1.1'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;additional issue with the username and password you're calling, as &lt;A title="docs" href="https://docs.ansible.com/ansible/latest/user_guide/playbooks_variables.html#:~:text=advanced%20variable%20syntax-,Creating%20valid%20variable%20names,cannot%20begin%20with%20a%20number." target="_self"&gt;Ansible requires that a variable name begin with a string&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;username:   '{{ 111111111 | default(omit) }}'
password:   '{{ 111111111 | default(omit) }}'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;should look like either of these, with the first example calling for the values of objects named &lt;EM&gt;my_username_variable&lt;/EM&gt; and &lt;EM&gt;my_password_variable.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;username:   '{{ my_username_variable | default(omit) }}'
password:   '{{ my_password_variable | default(omit) }}'

username:   'admin'
password:   'password123'&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please let me know if this helps,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Calvin&lt;/P&gt;</description>
      <pubDate>Tue, 23 Aug 2022 13:06:09 GMT</pubDate>
      <guid>https://live.paloaltonetworks.com/t5/automation-api-discussions/issues-to-create-my-first-playbook-on-a-vm-500-virtual-palo-alto/m-p/512668#M3098</guid>
      <dc:creator>cremsburg</dc:creator>
      <dc:date>2022-08-23T13:06:09Z</dc:date>
    </item>
  </channel>
</rss>

