Automated Deployment Pipeline using Jenkins
This repository contains a basic script to set up an automated deployment pipeline for a simple web application using Jenkins.
Prerequisites
A server with Ubuntu installed.
Git installed on the server.
A GitHub repository containing your web application.
Getting Started
- Clone this repository on your server.
git clone https://github.com/GitProSolutions/automated-deployment-pipeline.git
- Run the script to set up Jenkins and deploy the web application.
sudo ./deploy.sh
-
Open your web browser and navigate to http://<your_server_ip>:8080. Follow the steps to set up Jenkins and create a new job.
-
In the "Build Triggers" section, select "Poll SCM" and specify a schedule (e.g. H/15 * * * *).
-
In the "Build" section, select "Execute shell" and enter the following command:
sudo cp -r [YOUR_REPO]/* /var/www/html/ && sudo systemctl restart apache2
- Save the job and build it to test the deployment pipeline.
Customization
You can customize the script based on your specific requirements. For example, you can use a different web server, a different version of Jenkins, or a different Continuous Integration tool like TravisCI, CircleCI, etc.
Contributing
Feel free to contribute to this repository by creating a pull request or reporting an issue.
License
This project is licensed under the MIT License - see the LICENSE file for details.