Welcome to hop-ec2, a project designed to automate the deployment and configuration of Apache Hop on an AWS EC2 instance using Terraform and Ansible. This project sets up an EC2 instance, installs necessary software, and configures environmental variables and scripts for Apache Hop.
Before you begin, ensure you have the following installed on your machine:
-
Clone this repository to your local machine:
git clone https://github.com/usbrandon/hop-ec2.git cd hop-ec2 -
Run the
update_aws_profile.shscript to configure your AWS profile for Terraform:./update_aws_profile.sh
Follow the prompts to input your AWS credentials.
-
Initialize Terraform: Set up Terraform to manage the infrastructure:
terraform init
-
Plan Deployment: Review the changes Terraform will make to your AWS environment:
terraform plan
-
Apply Configuration: Create the resources in AWS:
terraform apply
Confirm the action when prompted.
- After the successful deployment, Terraform will output the public IP of the EC2 instance.
- Use SSH to connect to the instance:
Terraform will detect if you are on Linux or Windows and create a connection script for you.
ssh -i /path/to/your/key.pem ubuntu@<EC2-Public-IP>
./connect_to_ec2.sh
After deploying the EC2 instance, Ansible will automatically configure the environment for Apache Hop. However, you should verify that everything is set up as expected:
- Check if Apache Hop is correctly installed and configured. Hop ends up in the /opt/hop folder.
- Verify environmental variables and script aliases.
env
- If you encounter any issues with the deployment, check the Terraform and Ansible logs for detailed error messages.
- Ensure your AWS account has the necessary permissions and quotas to create the resources.
Contributions to hop-ec2 are welcome. Please read the contributing guidelines before submitting pull requests.