fix up ansible-lint warnings (#15)

Signed-off-by: Ben Burns <803016+benjamincburns@users.noreply.github.com>
pull/16/head
Benjamin Burns 5 years ago committed by GitHub
parent 1ebaf3850c
commit 4c9ec434cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      tasks/compile.yml
  2. 14
      tasks/main.yml
  3. 5
      tasks/network.yml

@ -8,6 +8,7 @@
- name: Check JDK version - name: Check JDK version
shell: javac -version | egrep -o '[0-9]+\.[0-9]+\.[0-9]+' shell: javac -version | egrep -o '[0-9]+\.[0-9]+\.[0-9]+'
register: jdk_version register: jdk_version
changed_when: false
ignore_errors: true ignore_errors: true
- name: Ensure JDK is installed - name: Ensure JDK is installed
@ -22,15 +23,17 @@
version: "{{ besu_git_commit }}" version: "{{ besu_git_commit }}"
- name: Build Besu - name: Build Besu
shell: ./gradlew --no-daemon --parallel clean assemble command: ./gradlew --no-daemon --parallel clean assemble
args: args:
chdir: /tmp/besu chdir: /tmp/besu
changed_when: true
- name: Get Besu Version - name: Get Besu Version
shell: "awk '/version=/ { gsub(/version=/,\"\"); print $1 }' gradle.properties" shell: "awk '/version=/ { gsub(/version=/,\"\"); print $1 }' gradle.properties"
args: args:
chdir: /tmp/besu chdir: /tmp/besu
register: besu_version_cmd register: besu_version_cmd
changed_when: false
- name: Set Besu Version Fact - name: Set Besu Version Fact
set_fact: set_fact:

@ -1,13 +1,19 @@
--- ---
- name: Ensure we have sane configuration - name: Ensure we have sane configuration
block: block:
- fail: - name: Check besu_version is correct
fail:
msg: You must set "besu_version" for this role to run when not building Besu from source msg: You must set "besu_version" for this role to run when not building Besu from source
when: besu_version is not defined and not besu_build_from_source when: besu_version is not defined and not besu_build_from_source
- fail: - name: Check besu_version is not set when besu_build_from_source is set
msg: The vars "besu_version" and "besu_build_from_source" are incompatible. If trying to build a specific git refspec, use "besu_git_refspec" instead of besu_version. fail:
msg: >-
The vars "besu_version" and "besu_build_from_source" are
incompatible. If trying to build a specific git refspec, use
"besu_git_refspec" instead of besu_version.
when: besu_version is defined and besu_build_from_source when: besu_version is defined and besu_build_from_source
- fail: - name: Check orion_version is not set when fast sync is enabled
fail:
msg: Orion and Fast-Sync are incompatible msg: Orion and Fast-Sync are incompatible
when: orion_version is defined and besu_sync_mode == "FAST" when: orion_version is defined and besu_sync_mode == "FAST"

@ -1,7 +1,10 @@
--- ---
- name: Get the default ipv4 address - name: Get the default ipv4 address
set_fact: set_fact:
besu_default_ip: "{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] if hostvars[inventory_hostname]['ansible_default_ipv4']['address'] is defined else '127.0.0.1' }}" besu_default_ip: >-
{{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] if
hostvars[inventory_hostname]['ansible_default_ipv4']['address'] is
defined else '127.0.0.1' }}
besu_aws_public_ip: "" besu_aws_public_ip: ""
besu_gcp_public_ip: "" besu_gcp_public_ip: ""
besu_azure_public_ip: "" besu_azure_public_ip: ""

Loading…
Cancel
Save