As application development is becoming more complex, major and minor changes need to be monitored to trace back problems to their source. Also, in case a deployment fails, it is important to know which change caused it and when it was integrated into the source code. This ready-to-install plugin helps monitor all activities in your GitHub repository and be instantly notified on new code changes.
Some of the metrics provided for this plugin include:
- Pull Requests
- Issues and Issues comments
- Commits and Commit comments
- Make sure a username and personal access token is created to monitor your GitHub account. Create a token with read access if you don't have one yet.
- Our Linux server monitoring agent should be installed in the server.
- While adding a plugin, the plugin name and its folder name inside the Site24x7 agent should be identical.
- Download and install the latest version of the Site24x7 Linux agent in the server where you plan to run the plugin. If it is installed successfully, you will see a Linux server monitor in the Site24x7 Control Panel. This confirms that the agent is able to communicate with our data center.
- Download the git_hub.py and git_hub.cfg files from our GitHub repository.
wget https://raw.githubusercontent.com/site24x7/plugins/master/git_hub/git_hub.pywget https://raw.githubusercontent.com/site24x7/plugins/master/git_hub/git_hub.cfg
- In the 'git_hub.cfg' file, add the username, personal access token, and the repository(s) that needs to be monitored. Sample configuration:
[display_name]user_name="[email protected]"personal_access_token="123ascejsfnkl"repo_name="Sample_repo1"where display_name denotes the monitor name to be displayed in the Site24x7 web client and 'repo_name' denotes the repository name that needs to be monitored.
- After completing the configuration, please execute the following command to ensure data is obtained.
run "python git_hub.py --repo_name='Sample_repo1'"
- Create a folder with the name 'git_hub', under the Site24x7 Linux agent plugin directory '/opt/site24x7/monagent/plugins/' and place the 'git_hub.py' and 'git_hub.cfg' files under '/opt/site24x7/monagent/plugins/git_hub'.
View Data in the Site24x7 Web Client
- Log in to Site24x7 and go to Server > Plugins > click on the name of the plugin monitor.
- You will be able to view GitHub events.