Ansible help

Hi folks,

I'm trying to setup an ansible playbook for our A10 devices. I intend to use the playbook to create new server, sg and vip configs. However, I am stuck with the overall setup and keep getting random errors. I tried to set up the playbook using both of the a10 ansible modules referrenced in the community and on the A10 github. Neither seem to be working the way I'd expect them to. After many changes to the playbook I was finally able to run a play but I keep getting the following error:

" "msg": "failed to connect (status code 404), error was HTTP Error 404: Not Found"


Below is my playbook. The vars are setup this way since I kept running into different errors about variables not being defined. I also tried different partitions (shared and L3V partition) to no avail.

Any advice or input on how to get ansible working with my A10's would be appreciated. Both A10s are running 4.1.4-GR1-P2, build 151 (if that helps).

#!/usr/bin/env ansible-playbook

# A10 SLB Playbook

# Create Server object

- name: A10 SLB

 connection: local

 hosts: <myhostname>

 gather_facts: False

 vars:

   host: "{{ a10_host }}"

   username: "{{ a10_username }}"

   password: "{{ a10_password }}"


 tasks:

 - name: Create a new server

   a10_server:

     validate_certs: no

     host: '{{ host }}'

     username: '{{ username }}'

     password: '{{ password }}'

     partition: shared

     server_name: test

     server_ip: 10.10.10.30

     server_ports:

       - port_num: 8080

         protocol: tcp

     write_config: yes

Comments

Sign In or Register to comment.