Infrastructure fleet template
Go to file
Alexis Pentori 739eaaa712
Adding Vagrant test env
Signed-off-by: Alexis Pentori <alexis@status.im>
2023-06-27 10:51:59 +02:00
ansible Adding Vagrant test env 2023-06-27 10:51:59 +02:00
.gitignore Adding Vagrant test env 2023-06-27 10:51:59 +02:00
Makefile Adding Vagrant test env 2023-06-27 10:51:59 +02:00
README.md Adding Vagrant test env 2023-06-27 10:51:59 +02:00
Vagrantfile Adding Vagrant test env 2023-06-27 10:51:59 +02:00
ansible.cfg ansible.cfg: drop remote_user=admin 2022-05-11 15:29:38 +02:00
main.tf add CloudFlare zone access boilerplate 2022-06-20 13:17:13 +02:00
providers.tf add Terraform boilerplate 2022-05-11 14:29:16 +02:00
secrets.tf add Terraform boilerplate 2022-05-11 14:29:16 +02:00
variables.tf add Terraform boilerplate 2022-05-11 14:29:16 +02:00
versions.tf versions: upgrade cloudflare from 2.21.0 to 3.26.0 2023-01-11 11:21:39 +01:00
workspaces.tf add Terraform boilerplate 2022-05-11 14:29:16 +02:00

README.md

Description

⚠️ Replace with actual description!

This repo defines a standard template for new Status infrastructure repositories.

Key things to change:

  • Update README.md
  • Terraform
    • Change path in main.tf to match new fleet
    • Add necessary providers in providers.tf
    • Add necessary secrets in secrets.tf
    • Adjust or remove workspaces.tf
    • Adjust versions.tf
  • Ansible
    • Extend ansible/group_vars/all.yml
    • Or add a dedicated group_vars file
    • Create the ansible/main.yml playbook

Repo Usage

For how to use this repo read the Infra Repo Usage doc.

Test

Prerequisites

To run the test environement, you need to have installed

Note: It's opssible to use another virtualization hypervisor, in that case, you need to modify the Vagrantfile accordingly.

Launch

The command make test will launch the following actions:

  • init-test-env : Create the VM, add the user ssh public key into the admin.pub file of infra-role-bootstrap-linux, run the linux bootstraping of the VM (tags for packages, role, docker, firewall, user, logging)
  • test-run-upgrade: Example of plabook to run
  • clean-text-env: Delete the VM, and remove the .vagrant directory.

Adapt to project

  • Modify the ansible/inventory/test to add host group matching the playbook you want to run.
  • Add function in the Makefile for each playbook you want to run.

Warning: The test VM doesn't not install consul on the host, some part of the playbook might failed. Use tags to specify witch role to execute.