ansible playbook to start and stop a WebSphere application

0 votes
I was looking for an ansible playbook to start and stop a WebSphere application. Any help will be appreciated...

Thanks you!
Oct 30, 2019 in Ansible by Hannah
• 18,570 points
6,221 views

1 answer to this question.

0 votes

The below playbook should be good enough:

- name: Start
  server: 
    state: started 
    wasdir: /usr/local/WebSphere/AppServer/ 
    name: server-01

- name: Stop
  server: 
    state: stopped 
    wasdir: /usr/local/WebSphere/AppServer/ 
    name: server-01
answered Oct 30, 2019 by Tanya
How it will stop and start without  stop.sh and start.sh
You can use this kind of code.

- name: Create
  profile_dmgr:
    state: present
    wasdir: /usr/local/WebSphere/AppServer/
    name: dmgr
    cell_name: devCell
    host_name: localhost
    node_name: devcell-dmgr
    username: admin
    password: allyourbasearebelongtous

- name: Remove
  profile_dmgr:
    state: absent
    wasdir: /usr/local/WebSphere/AppServer/
    name: dmgr

Before running this also set variables like hostname in conf file.

Related Questions In Ansible

0 votes
1 answer
0 votes
0 answers
0 votes
1 answer

Is it possible to start ec2 Windows machine and run windows command using ansible playbook?

Hi@Lakshminarayanan, Yes, you can do that. But after ...READ MORE

answered Aug 14, 2020 in Ansible by MD
• 95,440 points
1,989 views
0 votes
1 answer
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,458 views
+2 votes
1 answer
0 votes
1 answer

ansible playbook to create and remove a WebSphere Application Server Node Agent profile

This should workout: - name: Create profile_nodeagent: ...READ MORE

answered Oct 30, 2019 in Ansible by Tanishq
921 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP