---
# tasks file for openliberty
# Docs here: https://openliberty.io/blog/2020/04/09/microprofile-3-3-open-liberty-20004.html#yum
- name: Install OpenLiberty GPG key
  become: true
  ansible.builtin.apt_key:
    url: https://public.dhe.ibm.com/ibmdl/export/pub/software/openliberty/runtime/os-native-packages/public.key
    state: present
  when:
    - ansible_distribution == "Ubuntu"
- name: Add OpenLiberty repo
  become: true
  ansible.builtin.apt_repository:
    repo: deb https://public.dhe.ibm.com/ibmdl/export/pub/software/openliberty/runtime/os-native-packages/deb/ /
    state: present
    filename: openliberty
- name: Install OpenLiberty packages
  become: true
  ansible.builtin.apt:
    pkg:
      - openliberty
      - openliberty
