---

 

- hosts: all

  become: yes

 

  tasks:

    - name: create an empty folders

      import_tasks: /etc/ansible/foldercreation.yml

    - name: Copy rpm file to server

      copy:

         src: "{{ item }}"

         dest: /home/user/ansible/rpmpackages/

      with_fileglob:

        - /home/user/ansible/rpmpackages/*

    - name: copy the dynatrace file from home to root

      shell: sudo mv 
/home/user/ansible/rpmpackages/dynatrace-agent-6.1.0.7880-unix.jar 
/compuware/dt/

      shell: sudo chmod -R 755 
/compuware/dt/dynatrace-agent-6.1.0.7880-unix.jar

      shell: sudo chown -R user 
/compuware/dt/dynatrace-agent-6.1.0.7880-unix.jar

    - name: install dynatrace

      expect:

        command: /opt/SecureSpan/JDK/bin/java -jar 
/compuware/dt/dynatrace-agent-6.1.0.7880-unix.jar -installDir /compuware/dt/

        responses:
           The product will be installed to /compuware/dt/dynatrace-6.1.0. 
Do you want to install to this directory? \(Y/N\): 'Y'


for dynatarce installation I am getting below error , what could  be the 
reason

TASK [install dynatrace] 
***********************************************************************************************************************************************
task path: /etc/ansible/installrpm.yml:28
changed: [server] => {"changed": true, "cmd": "/opt/SecureSpan/JDK/bin/java 
-jar /compuware/dt/dynatrace-agent-6.1.0.7880-unix.jar -installDir 
/compuware/dt/", "delta": "0:00:00.183363", "end": "2018-02-19 
13:33:46.355043", "rc": 0, "start": "2018-02-19 13:33:46.171680", "stdout": 
"Invalid argument given!\r\n use <installer> -h to list all the available 
arguments", "stdout_lines": ["Invalid argument given!", " use <installer> 
-h to list all the available arguments"]}
META: ran handlers
META: ran handlers

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/080ffc57-a0c1-4168-ab95-16758edc89b6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to