This project has been replaced by -> https://github.com/M0NsTeRRR/homelabv3-infra
This is my Homelab infrastructure.
- Ansible core (version >= 2.14)
- Python3 and Pip
- Packer (version >= 1.8)
- Packer builder arm
- Terraform (version >= 1.3)
- Terragrunt (version >= 0.42)
cd ansible
Fill certs folders
Install python dependencies pip3 install -r requirements.txt
Install ansible galaxy dependencies ansible-galaxy install -r requirements.yml
fill all secrets.yml based on secrets.example in each subdirectory of groups_vars
ansible-playbook -i hosts playbooks/add-ssh-keys.yml
ansible-playbook -i hosts playbooks/generate-certs.yml
ansible-playbook -i hosts deploy_<zone>.yml
Replace <zone> by the appropriate zone name
cd packer
Init packer plugins
packer init packer/templates/debian
Port 8888 used for debian build
Port 8889 used for ubuntu build
Open both ports on windows firewall
Start powershell prompt with admin right netsh interface portproxy add v4tov4 listenaddress=<WINDOWS IP> connectaddress=<WSL IP> listenport=<WINDOWS PORT> connectport=<WSL PORT>
Replace with the LAN IP of your PC and with [8888, 8889]
To delete the rules netsh interface portproxy del v4tov4 listenaddress=<IP> listenport=<PORT>
Supported distributions :
VM
Raspberry Pi (v3/v4)
- Ubuntu (20.04.4) - iso
./build.sh (sudo permission required for Raspberry Pi choice only)
cd terraform
Install dependencies pip3 install paramiko
fill account.hcl based on account.example
Command must be run in one of this directories (dmz/lab/vpn)
terragrunt run-all plan
terragrunt run-all apply
The code is under CeCILL license.
You can find all details here: https://cecill.info/licences/Licence_CeCILL_V2.1-en.html
Copyright © Ludovic Ortega, 2021
Contributor(s):
-Ortega Ludovic - ludovic.ortega@adminafk.fr