---
- file: dest=/var/cache/neutron owner=neutron state=directory
- file: dest=/var/cache/neutron/api owner=neutron state=directory

- name: install neutron-server service
  upstart_service: |
    name=neutron-server
    user=neutron
    cmd=/usr/local/bin/neutron-server
    config_dirs=/etc/neutron
    config_files=/etc/neutron/neutron.conf,{% if neutron.plugin == 'ml2' %},/etc/neutron/plugins/ml2/ml2_plugin.ini{% endif %}{% if neutron.plugin == 'ovs' %},/etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini{% endif %}

- name: start neutron-server
  action: service name=neutron-server state=started

- name: Permit access to Neutron
  command: ufw allow 9797/tcp

---
- file: dest=/var/cache/neutron owner=neutron state=directory
- file: dest=/var/cache/neutron/api owner=neutron state=directory

- set_fact: neutron_plugin_config=/etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini
  when: neutron.plugin == 'ovs'

- set_fact: neutron_plugin_config=/etc/neutron/plugins/ml2/ml2_plugin.ini
  when: neutron.plugin == 'ml2'

- name: install neutron-server service
  upstart_service: |
    name=neutron-server
    user=neutron
    cmd=/usr/local/bin/neutron-server
    config_dirs=/etc/neutron
    config_files="/etc/neutron/neutron.conf,{{ neutron_plugin_config }}"

- name: start neutron-server
  action: service name=neutron-server state=started

- name: Permit access to Neutron
  command: ufw allow 9797/tcp

Remove extra comma and use set_fact idiom
Remove extra comma and use set_fact idiom

The last commit had an errant comma which led to an incorrect
upstart config. Remove the extra comma and use set_fact instead.
