Download the PHP package tourze/aws-lightsail-bundle without Composer
On this page you can find all versions of the php package tourze/aws-lightsail-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package aws-lightsail-bundle
AWS Lightsail Bundle
中文
A comprehensive Symfony bundle for AWS Lightsail integration, providing an intuitive interface for managing Lightsail resources with EasyAdmin support.
Table of Contents
- Features
- Requirements
- Installation
- Quick Start
- Configuration
- Supported Resources
- Console Commands
- Access Admin Interface
- API Documentation
- Advanced Configuration
- Troubleshooting
- Security
- Contributing
- License
Features
- Complete AWS Lightsail Resource Management - Manage all Lightsail resources from a single interface
- EasyAdmin Integration - Beautiful admin interface with minimal configuration
- Multi-Credential Support - Manage multiple AWS accounts from one application
- Automatic Resource Synchronization - Keep local database in sync with AWS
- Console Commands - Powerful CLI tools for automation and scripting
- Comprehensive API - Programmatic access to all Lightsail features
- Secure Credential Management - Encrypted storage of AWS credentials
Requirements
- PHP 8.1 or higher
- Symfony 7.3 or higher
- Doctrine ORM 3.0 or higher
- AWS SDK for PHP 3.349.3
- EasyAdmin Bundle 4.0 or higher
Installation
Step 1: Register the Bundle
Configuration
Step 2: Configure Environment Variables
Add the following to your .env or .env.local file:
Create Database Tables
Run the database migration to create required tables:
Or use migrations:
Quick Start
Access Admin Interface
After installation, access the admin interface at:
Add AWS Credentials
The first step is to add AWS credentials in the admin interface to manage Lightsail resources.
Example: Managing Instances
Supported Resources
The bundle supports management of all major Lightsail resources:
- Instances - Virtual private servers
- Disks & Snapshots - Block storage and backups
- Static IPs - Reserved IP addresses
- Domains & DNS - Domain management and DNS records
- CDN Distributions - Content delivery networks
- Buckets - Object storage
- Databases - Managed MySQL and PostgreSQL
- Certificates - SSL/TLS certificates
- Load Balancers - Application load balancers
- Container Services - Docker container deployment
- Alarms - Monitoring and alerting
API Documentation
Services
The bundle provides the following services for programmatic access:
Working with Instance Synchronization
Console Commands
The bundle provides powerful console commands for managing Lightsail resources:
Instance Control Command
Parameters:
operation: Operation type (start/stop/reboot)instance-name: Instance name (optional, interactive selection if not provided)--credential-id, -c: AWS credential ID--region, -r: AWS region--force, -f: Force execution without confirmation
Create Instance Command
Parameters:
name: Instance name (required)--credential-id, -c: AWS credential ID--region, -r: AWS region--blueprint, -b: Blueprint ID (OS image)--bundle: Bundle ID (instance type)--availability-zone, -z: Availability zone--key-pair-name, -k: SSH key pair name--tags, -t: Tags (format: key1=value1,key2=value2)--user-data, -u: User data (startup script)
Sync Instances Command
Parameters:
--credential-id, -c: AWS credential ID (optional, all credentials if not provided)--region, -r: Specific region (optional, all regions if not provided)
Features:
- Syncs instance information to local database
- Syncs SSH key pairs
- Removes locally stored resources that no longer exist in AWS
- Shows progress and statistics
Advanced Configuration
Custom Admin Routes
To customize the admin interface path, add to config/routes.yaml:
Service Configuration
The bundle automatically configures all necessary services. You can override service definitions in your application's configuration if needed.
Advanced Usage
Multi-Region Support
The bundle supports managing resources across multiple AWS regions through the console commands:
Multi-Credential Management
Manage resources from multiple AWS accounts:
Troubleshooting
Common Issues
- Missing AWS credentials: Ensure AWS credentials are properly configured in the admin interface
- Permission errors: Verify IAM user has necessary Lightsail permissions
- Region-specific resources: Some resources may not be available in all regions
Debug Mode
Enable debug logging for troubleshooting:
Security
AWS Credentials Security
This bundle handles AWS credentials securely:
- Environment Variables: Store credentials in environment variables, not in code
- IAM Best Practices: Use IAM users with minimal required permissions
- Credential Rotation: Regularly rotate AWS access keys
- Local Storage: Credentials stored in database are encrypted
Required AWS Permissions
Ensure your AWS IAM user has these permissions:
Security Recommendations
- Use IAM Roles: When running on AWS infrastructure, prefer IAM roles over access keys
- Environment Isolation: Use different AWS credentials for different environments
- Access Logging: Enable CloudTrail to monitor Lightsail API calls
- Network Security: Restrict admin interface access to authorized networks
Contributing
Contributions are welcome! Please ensure:
- All tests pass
- Code follows PSR-12 standards
- New features include tests
- Documentation is updated
License
The MIT License (MIT). Please see License File for more information.
References
All versions of aws-lightsail-bundle with dependencies
ext-hash Version *
aws/aws-sdk-php Version ^3.269
doctrine/collections Version ^2.3
doctrine/dbal Version ^4.0
doctrine/doctrine-bundle Version ^2.13
doctrine/orm Version ^3.0
doctrine/persistence Version ^3.1 || ^4
easycorp/easyadmin-bundle Version ^4
knplabs/knp-menu Version ^3.7
nesbot/carbon Version ^2.72 || ^3
psr/log Version ^3|^2|^1
symfony/config Version ^6.4
symfony/console Version ^6.4
symfony/dependency-injection Version ^6.4
symfony/doctrine-bridge Version ^6.4
symfony/form Version ^6.4
symfony/http-foundation Version ^6.4
symfony/http-kernel Version ^6.4
symfony/routing Version ^6.4
tourze/doctrine-timestamp-bundle Version 0.0.*
tourze/easy-admin-menu-bundle Version 0.1.*
tourze/enum-extra Version 0.1.*