Get your hands dirty with Ansible installation and setup.
Use it to restart Tomcat to get upto speed.
Local box – MacOS (Ansible will be installed here)
Target box – kochi (192.168.2.5 – Laptop running Ubuntu)
Tomcat on kochi /home/jeljo/tomcat8A
Installation on MacOS
Ansible playbook to install java and tomcat in a remote host.Join our DevOps hands-on series to get hands-on experience in creating a fully automated assembl. Ansible ad hoc commands are one-liners designed to achieve a very specific task they are like quick snippets and your compact swiss army knife when you want to do a quick task across multiple machines. To put simply, Ansible ad hoc commands are one-liner Linux shell commands and playbooks are.
Local box :
Setup the Public key
Copy the public key to target box
Test by logging into the Target box.
Configure the hosts to be managed.
Ansible Tomcat Start
A verbose view for troubleshooting in case of issues :
Using Ansible with Tomcat
Creating the playbook
If you get an error related to JAVA_HOME path
Ansible Tomcat Deploy War
just update the catalina.sh script with the path to you java location.
For Example :