--- - name: "Create database(s)" influxdb_database: hostname: "127.0.0.1" database_name: "{{ item }}" with_items: "{{ services.influxdb.databases }}" when: - services.influxdb.databases is defined