Getting Device Credentials Dynamically

Device credentials can be dynamically retrieved as part of the workflow execution process through a YAML (JSON) task. The following syntax must be used in the task in order to get device credentials.
  • Get device detail: $$devicename.username$$
  • Get device credential: $$devicename.password$$
Note: Device(s) must be added in the Appviewx inventory

To get the device credentials dynamically during the workflow execution process:

  1. From the top left corner of the screen, click .
  2. Select Inventory > Device.

  3. On the Device Inventory page, ensure there is at least one device added with relevant credentials.

  4. Design a new workflow.
  5. Drag and drop relevant tasks.
  6. From the User Interface section, drag and drop the YAML task.
  7. Add input data in the YAML format.
  8. Enter the following syntax to get the device credentials dynamically.
    Syntax Usage Sample
    ---
    -
     name: Creating a virtual server in a F5 device
     hosts: local
     tasks:
            - name: Add virtual server
              bigip_virtual_server:
                device: <Devicename or IP address>
                username: $$devicename.username$$
                password: $$devicename.password$$
                state: present
    
    ---
    -
     name: Creating a virtual server in a F5 device
     hosts: local
     tasks:
            - name: Add virtual server
              bigip_virtual_server:
                device: bigip.ltm.12.1
                username: $$ bigip.ltm.12.1.username$$
                password: $$ bigip.ltm.12.1.password$$
                state: present
    
  9. Save and enable the workflow.
  10. Trigger the workflow from the Request :: View/Run page.