---
- name: Metabase installed
  community.general.pkgng:
    name: metabase
    state: latest

- name: metabase enabled
  shell: sysrc metabase_enable="YES"
  notify: metabase restarted
    
- name: Metabase config installed
  template:
    src: metabase.conf.j2
    dest: /usr/local/etc/metabase.conf
    owner: root
    mode: 0600
  notify: Metabase restarted

- name: metabase started
  service: name=metabase state=started
