Deployment with Terraform 12 is unstable due to these bugs: #144, #147, #148, #149. Please use TF 11.11 - 11.14 and following branch for deployment https://github.com/poanetwork/blockscout-terraform/tree/before-t12
Go to Deploying BlockScout if you already have an infrastructure and simply want to install or update your BlockScout instance.
hosts file from hosts.example (mv hosts.example hosts) and adjust to your needs. Each host should represent each BlockScout instance you want to deploy.
Each host name should belong exactly to one group. Also, per Ansible requirements, hosts and groups names should be unique.
hosts file with one BlockScout instance will look like:
[group] is a group name, which will be interpreted as a prefix for all created resources and host is a name of BlockScout instance.
4) For each host merge infrastructure.yml.example and all.yml.example config template files in host_vars folder into single config file with the same name as in hosts file:
infrastructure.yml.example and all.yml.example config template files in group_vars folder into single config file with the same name as group name in hosts file:
group_vars and host_vars.
You can move variables between host and group vars depending on if variable should be applied to the host or to the entire group.
group_vars/all.yml file.
More on variable precedence => Official Ansible Docs.
ansible-playbook deploy_infra.yml
- During the deployment the “diffs didn’t match” error may occur, it will be ignored automatically. If Ansible play recap shows 0 failed plays, then the deployment was successful despite the error.
- Optionally, you may want to check the variables that were uploaded to the Parameter Store at AWS Console.