Files

75 lines
2.5 KiB
Markdown
Raw Permalink Normal View History

# Enterprise Infrastructure Simulator
2026-04-29 23:30:30 +00:00
## Problem Statement
2026-04-29 23:30:30 +00:00
Infrastructure teams need a safe place to rehearse lifecycle operations before applying them to production fleets. Patch windows, hardening changes, scale events, and node failures all carry operational risk when they are tested only during real incidents.
2026-04-29 23:30:30 +00:00
## Solution Overview
2026-04-29 23:30:30 +00:00
This project models common Linux infrastructure operations with Ansible playbooks and shell-based simulations. It keeps the automation readable and auditable while producing example evidence that resembles a real change record.
2026-04-29 23:30:30 +00:00
## Architecture Overview
```
2026-04-29 23:30:30 +00:00
Operator -> Make/CLI -> Ansible Inventory -> Playbooks -> Linux Nodes
| |
v v
Scenarios Reports/Logs
```
2026-04-29 23:30:30 +00:00
Core components:
2026-04-29 23:30:30 +00:00
- `inventory/hosts.ini` defines managed node groups.
- `playbooks/` contains provisioning, patching, hardening, and decommissioning workflows.
- `scripts/` injects scaling and failure conditions.
- `scenarios/` documents operational exercises.
- `examples/` stores representative outputs for review.
2026-04-29 23:30:30 +00:00
## How to Run
```bash
2026-04-29 23:30:30 +00:00
cd enterprise-infra-simulator
2026-04-29 23:30:30 +00:00
# Validate playbook syntax.
make test
2026-04-29 23:30:30 +00:00
# Provision the simulated estate.
make run
2026-04-29 23:30:30 +00:00
# Apply security patches.
make patch
2026-04-29 23:30:30 +00:00
# Apply host hardening.
make harden
2026-04-29 23:30:30 +00:00
# Run the failure and patch demo.
make demo
```
2026-04-29 23:30:30 +00:00
Direct Ansible commands are also supported:
```bash
2026-04-29 23:30:30 +00:00
ansible-playbook -i inventory/hosts.ini playbooks/provision.yml
ansible-playbook -i inventory/hosts.ini playbooks/patch.yml
ansible-playbook -i inventory/hosts.ini playbooks/hardening.yml
```
2026-04-29 23:30:30 +00:00
## Example Output
2026-04-29 23:30:30 +00:00
```text
PLAY RECAP *********************************************************************
web01 : ok=21 changed=7 unreachable=0 failed=0 skipped=3 rescued=0 ignored=1
db01 : ok=18 changed=4 unreachable=0 failed=0 skipped=5 rescued=0 ignored=1
lb01 : ok=16 changed=3 unreachable=0 failed=0 skipped=6 rescued=0 ignored=0
2026-04-29 23:30:30 +00:00
Patch status: SUCCESS
Updates applied: 12
Reboot required: false
```
2026-04-29 23:30:30 +00:00
Additional sample evidence is available in [examples/patch-output.txt](examples/patch-output.txt) and [examples/failure-simulation.txt](examples/failure-simulation.txt).
2026-04-29 23:30:30 +00:00
## Real-World Use Case
2026-04-29 23:30:30 +00:00
A platform team can use this project to demonstrate how routine operating procedures are encoded, reviewed, and tested before production change windows. The same patterns apply to regulated Linux estates where patch evidence, hardening controls, and incident drills must be repeatable.