Automation Tools
- Automation Tools
This article details the automation tools utilized on our MediaWiki server infrastructure, focusing on configuration management, deployment, and monitoring. Understanding these tools is crucial for anyone involved in maintaining or extending the server environment. This guide is geared towards newcomers to the system.
Introduction
Maintaining a complex system like our MediaWiki installation requires robust automation. Manual configuration is error-prone and time-consuming. The tools described below allow us to manage the server fleet efficiently, ensuring consistency, reliability, and rapid response to incidents. These tools work in conjunction with our Server Security practices.
Configuration Management: Ansible
We leverage Ansible for configuration management. Ansible is an agentless automation tool, meaning it doesn’t require software to be installed on the managed nodes (servers). It operates over SSH, making it relatively easy to deploy and maintain. Ansible uses YAML-based playbooks to define desired system states. These playbooks focus on idempotency – applying the same playbook multiple times should result in the same system state.
Here's a summary of our Ansible setup:
Component | Version | Purpose |
---|---|---|
Ansible Control Node | 2.9.27 | Orchestrates automation tasks. |
Inventory File | Dynamic (AWS) | Lists managed servers. |
Playbook Directory | /etc/ansible/playbooks/ | Contains automation scripts. |
SSH Key Authentication | Yes | Secure communication with servers. |
Ansible playbooks automate tasks such as:
- Software installation (e.g., PHP, MariaDB, Apache)
- Configuration file management (e.g., `php.ini`, `httpd.conf`)
- User and group management
- Service management (starting, stopping, restarting)
- Security updates
We utilize Roles within Ansible to organize and reuse code. This promotes modularity and reduces redundancy. See our Ansible Best Practices article for more details.
Continuous Integration & Continuous Deployment (CI/CD): Jenkins
Jenkins serves as our CI/CD pipeline. It automates the process of building, testing, and deploying code changes to our MediaWiki environment. Jenkins is triggered by commits to our Git repositories.
The CI/CD process involves the following steps:
1. **Code Commit:** A developer commits code to the Git repository. 2. **Build:** Jenkins pulls the code and builds the necessary artifacts. This includes running unit tests and code quality checks. 3. **Testing:** Automated tests are executed to verify functionality. These tests include Selenium tests to ensure UI functionality. 4. **Deployment:** If tests pass, Jenkins deploys the changes to a staging environment. 5. **Approval:** After manual testing in the staging environment, changes are approved for deployment to production. 6. **Production Deployment:** Jenkins deploys the changes to the production servers, leveraging Ansible for configuration updates.
Here's a table detailing Jenkins configuration:
Parameter | Value |
---|---|
Jenkins Version | 2.361.4 |
Build Server | Dedicated EC2 Instance |
Git Repository | GitLab |
Build Triggers | Git Commit, Scheduled |
Notification System | Email, Slack |
Proper configuration of Jenkins Pipelines is essential for a smooth deployment process.
Monitoring & Alerting: Prometheus & Grafana
We use Prometheus for time-series data collection and Grafana for visualization and alerting. Prometheus scrapes metrics from various server components (e.g., CPU usage, memory usage, disk I/O, HTTP request rates) at regular intervals. These metrics are stored in a time-series database.
Grafana allows us to create dashboards to visualize these metrics. We’ve created dashboards for:
- Server health
- Database performance
- Web server performance
- MediaWiki specific metrics (e.g., page views, edit rates)
Alerting rules are configured in Prometheus to notify us of critical issues (e.g., high CPU usage, low disk space, database errors). Alerts are sent via PagerDuty to ensure timely response.
Below is a summary of our monitoring stack:
Component | Version | Description |
---|---|---|
Prometheus | 2.38.0 | Time-series database and alerting. |
Grafana | 9.1.1 | Data visualization and dashboarding. |
Node Exporter | 0.18.1 | Collects system metrics. |
Alertmanager | 0.24.0 | Handles alerts from Prometheus. |
PagerDuty | Current | Incident Management Platform |
See our Monitoring Guide for detailed instructions on configuring and using these tools. Understanding the relationship between Server Load and these tools is critical.
Further Resources
Intel-Based Server Configurations
Configuration | Specifications | Benchmark |
---|---|---|
Core i7-6700K/7700 Server | 64 GB DDR4, NVMe SSD 2 x 512 GB | CPU Benchmark: 8046 |
Core i7-8700 Server | 64 GB DDR4, NVMe SSD 2x1 TB | CPU Benchmark: 13124 |
Core i9-9900K Server | 128 GB DDR4, NVMe SSD 2 x 1 TB | CPU Benchmark: 49969 |
Core i9-13900 Server (64GB) | 64 GB RAM, 2x2 TB NVMe SSD | |
Core i9-13900 Server (128GB) | 128 GB RAM, 2x2 TB NVMe SSD | |
Core i5-13500 Server (64GB) | 64 GB RAM, 2x500 GB NVMe SSD | |
Core i5-13500 Server (128GB) | 128 GB RAM, 2x500 GB NVMe SSD | |
Core i5-13500 Workstation | 64 GB DDR5 RAM, 2 NVMe SSD, NVIDIA RTX 4000 |
AMD-Based Server Configurations
Configuration | Specifications | Benchmark |
---|---|---|
Ryzen 5 3600 Server | 64 GB RAM, 2x480 GB NVMe | CPU Benchmark: 17849 |
Ryzen 7 7700 Server | 64 GB DDR5 RAM, 2x1 TB NVMe | CPU Benchmark: 35224 |
Ryzen 9 5950X Server | 128 GB RAM, 2x4 TB NVMe | CPU Benchmark: 46045 |
Ryzen 9 7950X Server | 128 GB DDR5 ECC, 2x2 TB NVMe | CPU Benchmark: 63561 |
EPYC 7502P Server (128GB/1TB) | 128 GB RAM, 1 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (128GB/2TB) | 128 GB RAM, 2 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (128GB/4TB) | 128 GB RAM, 2x2 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (256GB/1TB) | 256 GB RAM, 1 TB NVMe | CPU Benchmark: 48021 |
EPYC 7502P Server (256GB/4TB) | 256 GB RAM, 2x2 TB NVMe | CPU Benchmark: 48021 |
EPYC 9454P Server | 256 GB RAM, 2x2 TB NVMe |
Order Your Dedicated Server
Configure and order your ideal server configuration
Need Assistance?
- Telegram: @powervps Servers at a discounted price
⚠️ *Note: All benchmark scores are approximate and may vary based on configuration. Server availability subject to stock.* ⚠️