Browse Source

genesis deployment fixes

pull/1943/head
Greg Szabo 7 years ago
parent
commit
8e0ed4ddd0
2 changed files with 14 additions and 3 deletions
  1. +3
    -2
      ansible/roles/config/tasks/main.yml
  2. +11
    -1
      ansible/roles/status/tasks/main.yml

+ 3
- 2
ansible/roles/config/tasks/main.yml View File

@ -1,7 +1,7 @@
---
- name: gather tendermint public keys
when: (validators == true or validators == 'true') and tendermint_genesis_file is not defined
when: (validators == true or validators == 'true') and genesis_file is not defined
tags: reconfig-toml,reconfig-genesis
command: "/usr/bin/tendermint show_validator --home /etc/{{service}} --log_level error"
register: pubkeys
@ -12,7 +12,7 @@
file: "path=/etc/{{service}} owner={{service}} group={{service}} recurse=yes"
- name: register tendermint public keys as host facts
when: (validators == true or validators == 'true') and tendermint_genesis_file is not defined
when: (validators == true or validators == 'true') and genesis_file is not defined
tags: reconfig-toml,reconfig-genesis
set_fact: "pubkey='{{pubkeys.stdout}}'"
connection: local
@ -28,6 +28,7 @@
- name: copy pre-created genesis.json
when: genesis_file is defined
tags: reconfig-genesis
copy: "src={{genesis_file}} dest=/etc/{{service}}/genesis.json owner={{service}} group={{service}}"
- name: copy tendermint config.toml


+ 11
- 1
ansible/roles/status/tasks/main.yml View File

@ -1,6 +1,6 @@
---
- name: start service
- name: application service status
command: "service {{service}} status"
changed_when: false
register: status
@ -8,3 +8,13 @@
- name: Result
debug: var=status.stdout_lines
- name: tendermint service status
when: service != 'tendermint'
command: "service {{service}}-server status"
changed_when: false
register: tendermintstatus
- name: Result
when: service != 'tendermint'
debug: var=tendermintstatus.stdout_lines

Loading…
Cancel
Save