From b1f5055286bda61facb8eb3d14374bc55964a162 Mon Sep 17 00:00:00 2001 From: Arsenii Petrovich Date: Wed, 4 Sep 2019 12:30:26 +0300 Subject: [PATCH] Update README and tasks --- README.md | 9 +++++---- clean.yml | 7 +------ roles/check/tasks/main.yml | 3 +-- 3 files changed, 7 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index a7cffa3..06af50f 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ This version of playbooks supports the multi-hosts deployment, which means that | Dependency name | Installation method | | -------------------------------------- | ------------------------------------------------------------ | -| Terraform >=0.11.11 | [Installation guide](https://learn.hashicorp.com/terraform/getting-started/install.html) | +| Terraform >=0.12 | [Installation guide](https://learn.hashicorp.com/terraform/getting-started/install.html) | | Python >=2.6.0 | `apt install python` | | Python-pip | `apt install python-pip` | | boto & boto3 & botocore python modules | `pip install boto boto3 botocore` | @@ -29,12 +29,12 @@ This version of playbooks supports the multi-hosts deployment, which means that | Dependency name | Installation method | | -------------------------------------- | ------------------------------------------------------------ | -| Terraform >=0.11.11 | [Installation guide](https://learn.hashicorp.com/terraform/getting-started/install.html) | +| Terraform >=0.12 | [Installation guide](https://learn.hashicorp.com/terraform/getting-started/install.html) | | Python >=2.6.0 | `apt install python` | | Python-pip | `apt install python-pip` | | boto & boto3 & botocore python modules | `pip install boto boto3 botocore` | | AWS CLI | `pip install awscli` | -| All BlockScout prerequisites | [Check it here](https://github.com/poanetwork/blockscout#requirements) | +| All BlockScout prerequisites | [Check it here](https://poanetwork.github.io/blockscout/#/requirements) | # AWS permissions @@ -168,7 +168,7 @@ Also, if you need to **distribute variables accross all the hosts/groups**, you # Deploying BlockScout -0. (optional) This step is for mac OS users. Please skip it, if this is not your case. +
0. (optional) This step is for mac OS users. Please skip it, if this is not your case. To avoid the error ``` @@ -183,6 +183,7 @@ error and crashing of Python follow the next steps: - Save, exit, close terminal and re-open the terminal. Check to see that the environment variable is now set: `env` (source: https://stackoverflow.com/questions/50168647/multiprocessing-causes-python-to-crash-and-gives-an-error-may-have-been-in-progr); +
1. Ensure all the [BlockScout prerequisites](#Prerequisites-for-deploying-blockscout) are installed and has the right version number; 2. Create the AWS access key and secret access key for user with [sufficient permissions](#AWS); diff --git a/clean.yml b/clean.yml index 6c54acf..cd86ab4 100644 --- a/clean.yml +++ b/clean.yml @@ -5,12 +5,7 @@ file: state: absent path: "{{ item }}" - with_fileglob: - - "roles/main_infra/files/.terraform" - - "roles/main_infra/files/terraform.tfstate.d" - - "roles/main_infra/files/main.tfvars" - - "roles/main_infra/files/backend.tfvars" - - "roles/main_infra/files/terraform.tfplan" + with_items: - "log.txt" - "/tmp/blockscout-{{ group_names[0] }}-{{ chain }}" - "/tmp/files-{{ group_names[0] }}" diff --git a/roles/check/tasks/main.yml b/roles/check/tasks/main.yml index cee6df3..303d228 100644 --- a/roles/check/tasks/main.yml +++ b/roles/check/tasks/main.yml @@ -6,8 +6,7 @@ - name: Check chain names fail: msg: "The chain '{{ item }}' is invalid. It must consist only of the lowercase characters a-z and digits 0-9, and must not more than 5 characters long." - when: (item.key | length > 5 or item.key is not match("^[a-z0-9]+$")) and item.key != "all" and item.key != "ungrouped" - with_dict: "{{ groups }}" + when: chain | length > 5 or chain is not match("^[a-z0-9]+$") - name: Check if terraform is installed command: "{{ terraform_location }} --version"