---
- name: setup firewall
  import_tasks: firewall.yml

- name: Install cockpit-ws
  package:
    name: "{{ pkg_list | join(',') }}"
    state: present
  vars:
    pkg_list:
    - cockpit-ws
    - cockpit-system
    - cockpit-bridge
    - cockpit-docker
    - "{{ cockpit_plugins }}"
  when: not openshift_is_atomic | bool
  register: result
  until: result is succeeded

- name: Enable cockpit-ws
  systemd:
    name: cockpit.socket
    enabled: true
    state: started
  when: not openshift_is_atomic | bool

---
- name: setup firewall
  import_tasks: firewall.yml

- name: Install cockpit-ws
  package:
    name: "{{ pkg_list | join(',') }}"
    state: present
  vars:
    pkg_list:
    - cockpit-ws
    - cockpit-system
    - cockpit-bridge
    - cockpit-docker
    - "{{ cockpit_plugins | join(',') }}"
  when: not openshift_is_atomic | bool
  register: result
  until: result is succeeded

- name: Enable cockpit-ws
  systemd:
    name: cockpit.socket
    enabled: true
    state: started
  when: not openshift_is_atomic | bool

Fix issue with cockpit package list
Fix issue with cockpit package list

The package list contains an item which is a list by default.  The list
is converted to a comma separated string to conform to the pattern used
by the package command.
