
This project demonstrates infrastructure-as-code principles using Ansible to automate secure, repeatable Linux server provisioning.
An Ansible-based configuration management project that automates Linux server setup and deployment. This project demonstrates infrastructure-as-code principles by codifying server configuration into reusable, version-controlled playbooks.
What It Does
Automates complete server setup with four modular roles:
- Base Configuration: Updates system packages and installs essential utilities
- SSH Hardening: Configures secure SSH access with public key authentication
- Nginx Web Server: Installs and configures nginx for web hosting
- Application Deployment: Deploys static websites from tarball or GitHub repository
Tested on: Ubuntu 20.04 / 22.04
Design Principles
- Idempotent Playbooks: Safe to re-run without causing unintended changes
- Role-based Modular Architecture: Each role handles a specific concern for reusability
- Tag-based Selective Execution: Run specific roles independently
- Declarative Configuration: Infrastructure defined as code for version control
Tech Stack
Infrastructure:
- Ansible for configuration automation
- Linux (Ubuntu/Debian) server targets
- YAML for declarative configuration
- SSH for secure remote execution
Features:
- Role-based architecture for modularity
- Tag-based selective execution
- Idempotent operations for reliability
- Inventory management for multiple servers
Project Structure
configuration-management/
├── setup.yml # Main playbook
├── inventory.ini # Server inventory
├── base/ # Base system configuration role
├── ssh/ # SSH hardening role
├── nginx/ # Web server setup role
└── app/ # Application deployment role
Key Features
- Automated Provisioning: Complete server setup with a single command
- Idempotent Execution: Safe to run multiple times without side effects
- Selective Deployment: Use tags to run specific roles
- Scalable Design: Easily manage multiple servers through inventory
This project showcases DevOps fundamentals including infrastructure automation, configuration management, and deployment orchestration.