Skip to content

Instantly share code, notes, and snippets.

@VeselaHouba
Created December 12, 2018 14:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save VeselaHouba/2f61fdf04362b19fdc51d22af090cd47 to your computer and use it in GitHub Desktop.
Save VeselaHouba/2f61fdf04362b19fdc51d22af090cd47 to your computer and use it in GitHub Desktop.
---
- hosts: testf5
gather_facts: false
vars:
f5_provider:
server: "{{ ansible_host }}"
password: admin
user: admin
validate_certs: false
tasks:
- name: Import ASM policy
bigip_asm_policy_import:
provider: "{{ f5_provider }}"
name: test_asm.xml
source: test_asm.xml
force: false
delegate_to: localhost
register: asm_register
- name: Make sure config is saved
bigip_config:
provider: "{{ f5_provider }}"
save: true
delegate_to: localhost
when: asm_register.changed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment