ADR-009: Testing Infrastructure and ISO Management
Date
2025-03-09
Status
Accepted
Decision Makers
- Development Team
- QA Team
- Infrastructure Team
Context
The project requires a reliable and automated system for:
- Creating and managing OpenShift installation media (ISOs)
- Setting up and validating test environments
- Managing virtual infrastructure for testing
- Supporting both connected and disconnected installations
- Enabling reproducible testing processes
Considered Options
1. Manual ISO Creation and Testing
- Pros:
- Simple implementation
- Direct control
- Cons:
- Error-prone
- Time-consuming
- Not reproducible
2. Third-party Testing Frameworks
- Pros:
- Established solutions
- Community support
- Cons:
- Limited customization
- Complex integration
- Overhead
3. Custom Testing Infrastructure (Selected)
- Pros:
- Full control over process
- Tailored to requirements
- Integration with existing tools
- Automation capabilities
- Cons:
- Development effort
- Maintenance responsibility
- Documentation needs
Decision
Implement a comprehensive testing infrastructure with:
- Core Components
hack/ ├── create-iso.sh # ISO generation ├── deploy-on-kvm.sh # VM deployment ├── watch-and-reboot-kvm-vms.sh # VM monitoring ├── configure_dns_entries.sh # DNS configuration └── deploy-freeipa.sh # Identity management e2e-tests/ ├── bootstrap_env.sh # Environment setup ├── validate_env.sh # Environment validation ├── run_e2e.sh # Test orchestration └── delete_e2e.sh # Environment cleanup
- ISO Management
- Automated ISO creation
- Configuration templating
- Validation checks
- Asset organization
- Testing Infrastructure
- Environment setup
- VM deployment
- Network configuration
- Monitoring systems
Implementation
ISO Creation Process
# ISO Generation Flow
1. Configuration Validation
- Verify input parameters
- Check dependencies
- Validate templates
2. ISO Creation
- Generate configuration
- Create bootable ISO
- Apply customizations
- Validate output
3. Asset Management
- Organize generated files
- Track configurations
- Maintain versions
Testing Infrastructure
# Test Environment Setup
1. Environment Bootstrap
- System package installation
- Tool configuration
- Network setup
- Service initialization
2. Infrastructure Deployment
- VM creation
- Network configuration
- DNS setup
- Identity management
3. Test Execution
- Environment validation
- Test case running
- Result collection
- Environment cleanup
Monitoring and Control
# Infrastructure Management
1. VM Monitoring
- State tracking
- Resource monitoring
- Boot process validation
- Error detection
2. Network Management
- DNS configuration
- Network validation
- Connectivity testing
- Route verification
Consequences
Positive
- Automated ISO generation
- Consistent test environments
- Reproducible processes
- Integrated monitoring
- Efficient resource management
- Comprehensive validation
Negative
- Setup complexity
- Resource requirements
- Maintenance overhead
- Technical expertise needed
Test Coverage
Basic Testing
- ISO creation validation
- Environment setup verification
- Network configuration testing
- VM deployment validation
Advanced Testing
- Disconnected installations
- Multi-node deployments
- Network scenarios
- Failure recovery
Related ADRs
- ADR-013: End-to-End Testing Framework
- ADR-006: Testing and Execution Environment
- ADR-007: Virtual Infrastructure Testing