Create a copy and fill in the required environment variables fields
cp ./.envrc.dist ./.envrc
Load the environment variables in your current working shell
set -a && source ./.envrc && set +a
Create a Ruby Environment (Gemset)
rbenv gemset create 3.1.2 pritunl-aws-vm-single-server
Install the required Gemset for Terraspace Framework
bundle install
Install Terraform Vendor Modules from Terraform Registry
terraspace bundle
Plan and Provision a VM
terraspace all plan
terraspace all up
Monitor the Operations by outputting the logs
terraspace logs -f
Prepare the Environment
cd ./provisioning
python -m venv ./.venv
source ./.venv/bin/activate
Ansible Base (Core Distribution)
pip install -r requirements.txt
AWS Plugin
ansible-galaxy collection install amazon.aws
Show AWS EC2 Resource
ansible-inventory -i aws_ec2.yml --graph
ansible tag_Name_pritunl_vm -i aws_ec2.yml -m ping
Check for Possible Changes (Dry Run)
ansible-playbook -i aws_ec2.yml main.yml --check
Install the Updates (Approve for any changes)
ansible-playbook -i aws_ec2.yml main.yml
Only for APT Check/Changes
ansible-playbook -i aws_ec2.yml main.yml --tags "apt" --check
Only for SystemD Check/Changes
ansible-playbook -i aws_ec2.yml main.yml --tags "systemd" --check
- Create a Packer Images for Initial VM Provisioning