Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Here are the steps in order to use it :

  • Install the roles :

    Code Block
    ansible-galaxy install francelabs.datafari
    ansible-galaxy install alvistack.openjdk
  • Create a folder and inside it create two files :
    - inventory.txt
    - playbook.yml

    Code Block
    mkdir ansibledatafari
    touch ansibledatafari/inventory.txt
    touch ansibledatafari/playbook.yml
  • Edit inventory.txt :
    Put inside the host(s) to install Datafari on it. For example with a server’s IP that is : 1.1.1.1 ans SSH public key connection the inventory is :

    Code Block
    [datafari]
    datafari_server ansible_connection=ssh ansible_host=1.1.1.1 ansible_ssh_user=root
  • Edit playbook.yml :
    The following example file indicates that we want to install Datafari into all our hosts present into inventory.
    become: true is to tell Ansible that we install the role’s role's taks with root user.
    openjdk_release : “11” "11" is to specify the version of Java we want. For Datafari we only support Java 11 for now.
    Finally, we indicate the roles that we want to install. First the role that will set Java into the remote host and the role to install Datafari

    Code Block
    ---
     - hosts: all
       become: true
       vars:
         openjdk_release: "11"
       roles:
       - alvistack.openjdk
       - ansible-role-datafari
    
  • Launch the Ansible command to install the roles :

    Code Block
    cd ansibledatafari
    ansible-playbook -i inventory.txt playbook.yml

...