Friday, 18 September 2020

End to End Automation of Java web App Using jenkins, bitbucket,sonaqube,Maven,Tomcat,Artifactory,Slack

 Tools Used:

  • Bitbucket— Source Code Management
  • Maven — Build Tool
  • Jenkins — Continuous Integration (CI/CD)
  • Artifactory — Artifact Repository Manager
  • SonarQube — Code Quality and Code Analysis
  • Tomcat — Application Server(Web container)



What is the Requirement? - Setup MyDevopsApp Java Project using Maven in Bitbucket and Automate end to end Builds, Code quality checks, Deployments and Collaboration using Jenkins and other Devops tools we have used so far. Could you please work on below lab exercise on a brand new EC2 instance(small instance) and show the output when we meet on next week end?


Lab Exercise Steps:
1. Also, create a repo called MyAutomationRepo in bitbucket. (lab exercise # 5)
2. Create a Java project called MyDevopsApp (instead of MyWebApp which we did before (lab exercise #5) using Maven.
3. Set the above project in Bitbucket(lab exercise #5)
4. Set up a free style job called MyDevopsFreeStyleJob (use webhooks,lab exercise #6, lab exercise # 8) in Jenkins and automate builds, deployments to Tomcat server (lab exercise #6). Also integrate with SonarQube to see the code quality report(lab exercise #10). Finally Jenkins should deploy to Tomcat immediately if there is a code change(lab exercise #7, lab exercise 8). Also jenkins should upload WAR into Artifactory as well. (lab exercise # 17, lab exercise 18). And send notifications to Slack(lab exercise # 19)
5 Finally show the below output in Tomcat by modifying index.jsp (lab exercise #6) in your java project. 
       Congrats I am now a Devops Engineer I Can Migrate App to cloud using Bitbucket,Jenkins,Maven and Tomcat!!!
6. SonarQube dashboard should be viewed in Sonarqube.
7. Artifactory should show uploaded artifacts as well.
8. Slack should show the message coming from Jenkins for every build success/failure.

Tips:

You all know the maven command to create a Java project using Maven and where you to change the word MyWebApp to MyDevopsApp.
mvn archetype:generate -DgroupId=com.mkyong -DartifactId=MyWebApp -DarchetypeArtifactId=maven-archetype-webapp -DinteractiveMode=false

No comments:

Post a Comment