janusgraph script

I am new in ansible project.

I need to start janusgraph.sh script through ansible. when I am executing it not giving any error but janusgraph is not starting. my janusgraph is combining with Cassandra, elasticsearch, and gramlin server.

when I will start janusgraph the above three-component should start.

  • name: run janusgraph script
    become_user: {{user_name}} (example)
    shell: bash janusgraph.sh start
    args:
    chdir: {{path_of_janusgraph}} (example)

I am new in ansible project.

I need to start janusgraph.sh script through ansible. when I am executing it not giving any error but janusgraph is not
starting. my janusgraph is combining with Cassandra, elasticsearch, and gramlin server.

when I will start janusgraph the above three-component should start.

- name: run janusgraph script
become_user: {{user_name}} (example)
shell: bash janusgraph.sh start
args:
chdir: {{path_of_janusgraph}} (example)

Hello Rajeeb,

first of all it is recommended to use "command" module instead of "shell".

To see the output of the script, add the following:

  - name: run janusgraph script
    ....
    register: janusgraph_result

  - debug:
      var: janusgraph_result

Regards
       Racke

Hi Racke,
I tried with command but it’s not working.

To see the output

  • name: run janusgraph script

    register: janusgraph_result

  • debug:
    var: janusgraph_result

should output will print in the same consol or is there any particular path?

Hi Racke,
I tried with command but it's not working.

To see the output
- name: run janusgraph script
....
register: janusgraph_result

- debug:
var: janusgraph_result

should output will print in the same consol or is there any particular path?

The debug module displays the contents of the given variable below the "run janusgraph script" task.

Regards
         Racke

Hello Racke

It is working.Thank you Racke