From f152658f6c0f3431bbd392510e61ff9ef9b0222e Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 11 Oct 2017 13:05:15 -0400 Subject: [PATCH 01/60] Introducing neutrino denom --- ansible/app_options_files/public_testnet | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 66f3dddf1..6bae413ae 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -22,7 +22,7 @@ }, "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 9007199254740991 }, { @@ -40,7 +40,7 @@ }, "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 9007199254740992 }, { @@ -54,7 +54,7 @@ "address": "0FA1DB09E8B174E81E94280C047C158D4271457B", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 1928936473812 }, { @@ -72,7 +72,7 @@ }, "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 20000000000 }, { @@ -94,7 +94,7 @@ "amount": 1000 }, { - "denom": "buckyball", + "denom": "neutrino", "amount": 3478765434568 } ] @@ -108,7 +108,7 @@ }, "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { @@ -122,7 +122,7 @@ "address": "7B8422A210D0F0B8734908C093ECF0E9A768BDB8", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { @@ -136,7 +136,7 @@ "address": "C2104A8191E282AA45D210BA93282B36768EDDA1", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { @@ -150,7 +150,7 @@ "address": "0F8FB94B5A4D04220F15058B7AA16AF1328B57A9", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { @@ -164,7 +164,7 @@ "address": "117FE408E1F74C453901BCB638F996964FD29CBB", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { @@ -178,7 +178,7 @@ "address": "F63F2D34C03430A54B7F6A43C886B4A83F366B84", "coins": [ { - "denom": "buckyball", + "denom": "neutrino", "amount": 53712836452781 }, { From 7872ade62663f62a69100f6dac9d04cd7efd88a8 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 12 Oct 2017 10:17:38 -0400 Subject: [PATCH 02/60] testnet specification fixes --- ansible/app_options_files/public_testnet | 78 ++++++++++++------- .../config/templates/genesis-server.json.j2 | 24 ------ .../config/templates/genesis-service.json.j2 | 12 --- .../roles/config/templates/genesis.json.j2 | 2 +- 4 files changed, 52 insertions(+), 64 deletions(-) delete mode 100644 ansible/roles/config/templates/genesis-server.json.j2 delete mode 100644 ansible/roles/config/templates/genesis-service.json.j2 diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 6bae413ae..d3e029ee4 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -22,8 +22,8 @@ }, "coins": [ { - "denom": "neutrino", - "amount": 9007199254740991 + "denom": "fermion", + "amount": 10000000 }, { "denom": "gregcoin", @@ -40,8 +40,8 @@ }, "coins": [ { - "denom": "neutrino", - "amount": 9007199254740992 + "denom": "fermion", + "amount": 10000000 }, { "denom": "antoncoin", @@ -54,8 +54,8 @@ "address": "0FA1DB09E8B174E81E94280C047C158D4271457B", "coins": [ { - "denom": "neutrino", - "amount": 1928936473812 + "denom": "fermion", + "amount": 10000000 }, { "denom": "adriancoin", @@ -72,8 +72,8 @@ }, "coins": [ { - "denom": "neutrino", - "amount": 20000000000 + "denom": "fermion", + "amount": 10000000 }, { "denom": "buckycoin", @@ -81,21 +81,45 @@ } ] }, + { + "name": "bucky-new", + "address": "4FE8FFE12EDBA34BE4E587B2125177AC24594BAF", + "coins": [ + { + "denom": "fermion", + "amount": 10000000 + }, + { + "denom": "buckycoin", + "amount": 2000 + } + ] + }, { "name": "rigel", - "address": "3A8BE0EEE474C8D197AA14312B59ACB2D9DFECDE", - "pub_key": { - "type": "ed25519", - "data": "C7CAC198E3999C4DD9F25C575C4C10587C083F73B1E985AC65658992DE6B552E" - }, + "address": "C7A6F5FD77DDCA5C43600F33D14533A27C683F55", + "coins": [ + { + "denom": "rigelcoin", + "amount": 1000 + }, + { + "denom": "fermion", + "amount": 10000000 + } + ] + }, + { + "name": "rigel2", + "address": "5B228AB64E290F1FC4D3E933B7623CCA3F015C34", "coins": [ { "denom": "rigelcoin", "amount": 1000 }, { - "denom": "neutrino", - "amount": 3478765434568 + "denom": "fermion", + "amount": 10000000 } ] }, @@ -108,8 +132,8 @@ }, "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "shadowcoin", @@ -122,8 +146,8 @@ "address": "7B8422A210D0F0B8734908C093ECF0E9A768BDB8", "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "pengcoin", @@ -136,8 +160,8 @@ "address": "C2104A8191E282AA45D210BA93282B36768EDDA1", "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "mattcoin", @@ -150,8 +174,8 @@ "address": "0F8FB94B5A4D04220F15058B7AA16AF1328B57A9", "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "freycoin", @@ -164,8 +188,8 @@ "address": "117FE408E1F74C453901BCB638F996964FD29CBB", "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "wancloudcoin", @@ -178,8 +202,8 @@ "address": "F63F2D34C03430A54B7F6A43C886B4A83F366B84", "coins": [ { - "denom": "neutrino", - "amount": 53712836452781 + "denom": "fermion", + "amount": 10000000 }, { "denom": "bianjiecoin", diff --git a/ansible/roles/config/templates/genesis-server.json.j2 b/ansible/roles/config/templates/genesis-server.json.j2 deleted file mode 100644 index a1c7741b3..000000000 --- a/ansible/roles/config/templates/genesis-server.json.j2 +++ /dev/null @@ -1,24 +0,0 @@ -{ - "genesis_time":"{{ansible_date_time.iso8601}}", - "chain_id":"{{testnet_name}}", - "validators": - [ -{% if (validators == true) or (validators == 'true') %} -{% set comma = joiner(",") %} -{% for host in (groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])) %} - {{ comma() }} - { - "pub_key": { - "data": "{{hostvars[host]["pubkey"]["data"]}}", - "type": "{{hostvars[host]["pubkey"]["type"]}}" - }, - "power":10, - "name":"{{hostvars[host]["inventory_hostname"]}}" - } -{% endfor %} -{% endif %} - ], - "app_hash":"", - "app_options": {} -} - diff --git a/ansible/roles/config/templates/genesis-service.json.j2 b/ansible/roles/config/templates/genesis-service.json.j2 deleted file mode 100644 index 7f9a48316..000000000 --- a/ansible/roles/config/templates/genesis-service.json.j2 +++ /dev/null @@ -1,12 +0,0 @@ -{ - "genesis_time":"{{ansible_date_time.iso8601}}", - "chain_id":"{{testnet_name}}", - "validators": [], - "app_hash":"", - "app_options": { -{% if app_options_file is defined %} -{% include app_options_file %} -{% endif %} - } -} - diff --git a/ansible/roles/config/templates/genesis.json.j2 b/ansible/roles/config/templates/genesis.json.j2 index e2f956ebb..4bf3b44c5 100644 --- a/ansible/roles/config/templates/genesis.json.j2 +++ b/ansible/roles/config/templates/genesis.json.j2 @@ -12,7 +12,7 @@ "data": "{{hostvars[host]["pubkey"]["data"]}}", "type": "{{hostvars[host]["pubkey"]["type"]}}" }, - "power":10, + "power":1000, "name":"{{hostvars[host]["inventory_hostname"]}}" } {% endfor %} From 51d74ebdfa3f999574aa01d074b749741529c522 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 12 Oct 2017 12:49:26 -0400 Subject: [PATCH 03/60] Zaki added --- ansible/app_options_files/public_testnet | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index d3e029ee4..770f83338 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -210,6 +210,20 @@ "amount": 1000 } ] + }, + { + "name": "zaki", + "address": "E2080141FEAD5986FD411121CA077F2835294F5A", + "coins": [ + { + "denom": "fermion", + "amount": 10000000 + }, + { + "denom": "zakicoin", + "amount": 1000 + } + ] } ], From e0fbe6fb3ec628cb33abc0cedb24f3a8e29fe66e Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 12 Oct 2017 14:08:29 -0400 Subject: [PATCH 04/60] Version parsing changed in build to accommodate Gaia's extra space --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index ca44de525..7a7af20cd 100644 --- a/build/Makefile +++ b/build/Makefile @@ -104,7 +104,7 @@ build-basecoin: git-branch # set app_version version-%: $(GOPATH)/bin/% if [ -z "$(BUILD_NUMBER)" ]; then echo "BUILD_NUMBER not set" ; false ; fi - $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' )) + $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) # set build_folder folder-%: version-% From 7aa0957fc54f558c0f1697990f244045c815c6c5 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 12 Oct 2017 14:42:59 -0400 Subject: [PATCH 05/60] Changed fermion numbers --- ansible/app_options_files/public_testnet | 28 ++++++++++++------------ 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 770f83338..3c232ea77 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -23,7 +23,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "gregcoin", @@ -41,7 +41,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "antoncoin", @@ -55,7 +55,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "adriancoin", @@ -73,7 +73,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "buckycoin", @@ -87,7 +87,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "buckycoin", @@ -105,7 +105,7 @@ }, { "denom": "fermion", - "amount": 10000000 + "amount": 10000 } ] }, @@ -119,7 +119,7 @@ }, { "denom": "fermion", - "amount": 10000000 + "amount": 10000 } ] }, @@ -133,7 +133,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "shadowcoin", @@ -147,7 +147,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "pengcoin", @@ -161,7 +161,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "mattcoin", @@ -175,7 +175,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "freycoin", @@ -189,7 +189,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "wancloudcoin", @@ -203,7 +203,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "bianjiecoin", @@ -217,7 +217,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000 + "amount": 100 }, { "denom": "zakicoin", From 43c86c2a9cad15513cfd1c90786c4f6cb37fb492 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 12 Oct 2017 14:55:24 -0400 Subject: [PATCH 06/60] Ansible 2.2 compatibility fix --- ansible/roles/install/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/install/tasks/main.yml b/ansible/roles/install/tasks/main.yml index 410468adb..59f97d36e 100644 --- a/ansible/roles/install/tasks/main.yml +++ b/ansible/roles/install/tasks/main.yml @@ -5,7 +5,7 @@ file: path=/etc/localtime state=link src=/usr/share/zoneinfo/{{timezone}} force=yes - name: Disable journald rate-limiting - lineinfile: "path=/etc/systemd/journald.conf regexp={{item.regexp}} line='{{item.line}}'" + lineinfile: "dest=/etc/systemd/journald.conf regexp={{item.regexp}} line='{{item.line}}'" with_items: - { regexp: "^#RateLimitInterval", line: "RateLimitInterval=0s" } - { regexp: "^#RateLimitBurst", line: "RateLimitBurst=0" } From 639aedd5a1c1163ee55106c595074249eb64c7ca Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 13 Oct 2017 08:31:15 -0400 Subject: [PATCH 07/60] Changed wallets --- ansible/app_options_files/public_testnet | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 3c232ea77..11e3a5735 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -23,7 +23,7 @@ "coins": [ { "denom": "fermion", - "amount": 100 + "amount": 1000000 }, { "denom": "gregcoin", @@ -51,7 +51,7 @@ }, { "name": "adrian", - "address": "0FA1DB09E8B174E81E94280C047C158D4271457B", + "address": "4548017683F771FDBCF7D8E74F4723868AA20009", "coins": [ { "denom": "fermion", @@ -66,10 +66,6 @@ { "name": "bucky", "address": "2B24DEE2364762300168DF19B6C18BCE2D399EA2", - "pub_key": { - "type": "ed25519", - "data": "37BF9D6F8D66DC3FAECD330291CF08DF52E2F646B01F7E43BC0A746AED927A62" - }, "coins": [ { "denom": "fermion", @@ -211,6 +207,20 @@ } ] }, + { + "name": "alexis", + "address": "42989458D3285F05FE0233EE669A1CCD90AE6F3E", + "coins": [ + { + "denom": "fermion", + "amount": 100 + }, + { + "denom": "alexiscoin", + "amount": 1000 + } + ] + }, { "name": "zaki", "address": "E2080141FEAD5986FD411121CA077F2835294F5A", From 95048b21b20b957ea0c5a7b83f67eff9cc23967c Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 13 Oct 2017 21:45:17 -0400 Subject: [PATCH 08/60] Added fermion to bucky --- ansible/app_options_files/public_testnet | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 11e3a5735..78cbc97ef 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -69,7 +69,7 @@ "coins": [ { "denom": "fermion", - "amount": 100 + "amount": 10000 }, { "denom": "buckycoin", @@ -83,7 +83,7 @@ "coins": [ { "denom": "fermion", - "amount": 100 + "amount": 10000 }, { "denom": "buckycoin", From c0e373bad0cae954f2bd0158fac16fe5954249c5 Mon Sep 17 00:00:00 2001 From: Ethan Buchman Date: Sat, 14 Oct 2017 08:46:06 -0400 Subject: [PATCH 09/60] bump bucky fermions --- ansible/app_options_files/public_testnet | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 78cbc97ef..13ed97d81 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -83,7 +83,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000 + "amount": 10000000000 }, { "denom": "buckycoin", From cc45151c4d1d2f10c1bd519b7c6501a4d3ff60b9 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 20 Oct 2017 22:54:24 -0400 Subject: [PATCH 10/60] Testnet stuff --- ansible/app_options_files/public_testnet | 24 +++++++++++++++++-- ansible/roles/config/templates/config.toml.j2 | 5 ++-- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 13ed97d81..bcd03ed08 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -181,7 +181,7 @@ }, { "name": "wancloud", - "address": "117FE408E1F74C453901BCB638F996964FD29CBB", + "address": "02C1F2CE501DAF30F758E657B71FC7AD568C4BE5", "coins": [ { "denom": "fermion", @@ -195,7 +195,7 @@ }, { "name": "bianjie", - "address": "F63F2D34C03430A54B7F6A43C886B4A83F366B84", + "address": "7D626173FAA69D96E56523A333EAF78F87843CE5", "coins": [ { "denom": "fermion", @@ -234,6 +234,26 @@ "amount": 1000 } ] + }, + { + "name": "jimyang", + "address": "6F94C5B7FEB6EF926A8901A8E8F4B2077D02B354", + "coins": [ + { + "denom": "fermion", + "amount": 1000 + } + ] + }, + { + "name": "MichaelYuan", + "address": "F75D0FD7036A3BB9092DD0938BBF0A9323224832", + "coins": [ + { + "denom": "fermion", + "amount": 100000 + } + ] } ], diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 361381378..d76429835 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -12,7 +12,8 @@ log_level = "mempool:error,*:debug" {% else %} db_backend = "leveldb" -log_level = "state:info,*:error" +#log_level = "state:info,*:error" +log_level = "debug" {% endif %} @@ -39,7 +40,7 @@ create_empty_blocks_interval = 1 {% else %} [consensus] -create_empty_blocks_interval = 1 +create_empty_blocks_interval = 10 {% endif %} From 45021f017b9fccf9b509c2cbf858e1503b5733b3 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 20 Oct 2017 23:15:54 -0400 Subject: [PATCH 11/60] log level --- ansible/roles/config/templates/config.toml.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index d76429835..c7a8a0533 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -12,8 +12,8 @@ log_level = "mempool:error,*:debug" {% else %} db_backend = "leveldb" -#log_level = "state:info,*:error" -log_level = "debug" +log_level = "state:info,*:error" +#log_level = "*:debug" {% endif %} From 8e0ed4ddd069c8bf6361371931fd074e0479a29e Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 26 Oct 2017 19:44:58 -0400 Subject: [PATCH 12/60] genesis deployment fixes --- ansible/roles/config/tasks/main.yml | 5 +++-- ansible/roles/status/tasks/main.yml | 12 +++++++++++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/ansible/roles/config/tasks/main.yml b/ansible/roles/config/tasks/main.yml index 8fa90583f..5130a4a1f 100644 --- a/ansible/roles/config/tasks/main.yml +++ b/ansible/roles/config/tasks/main.yml @@ -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 diff --git a/ansible/roles/status/tasks/main.yml b/ansible/roles/status/tasks/main.yml index e47d634e7..d063ee564 100644 --- a/ansible/roles/status/tasks/main.yml +++ b/ansible/roles/status/tasks/main.yml @@ -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 + From b1d433314b58cadad9f591f3894c607de18283a0 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 6 Nov 2017 01:00:05 -0500 Subject: [PATCH 13/60] app options cahgnes --- ansible/app_options_files/kingethan | 12 -------- ansible/app_options_files/public_testnet | 36 ++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 12 deletions(-) delete mode 100644 ansible/app_options_files/kingethan diff --git a/ansible/app_options_files/kingethan b/ansible/app_options_files/kingethan deleted file mode 100644 index 2245ffd4d..000000000 --- a/ansible/app_options_files/kingethan +++ /dev/null @@ -1,12 +0,0 @@ - "accounts": [{ - "address": "C13B2A17030E416D0C83B7FF7CDFFB2E2353FA11", - "coins": [ - { - "denom": "mycoin", - "amount": 9007199254740992 - } - ] - }], - "plugin_options": [ - "coin/issuer", {"app": "sigs", "addr": "C13B2A17030E416D0C83B7FF7CDFFB2E2353FA11"} - ] diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index bcd03ed08..b4accc753 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -31,6 +31,42 @@ } ] }, + { + "name": "monitor1", + "address": "CE456B8BA9AFD1CBDF4ED14558E8C30691E549EA", + "coins": [ + { + "denom": "fermion", + "amount": 100 + }, + { + "denom": "moncoin", + "amount": 600000 + }, + { + "denom": "leadertoken", + "amount": 1 + } + ] + }, + { + "name": "monitor2", + "address": "EF708182E21F893634FD8DCB82A5128E16C76B83", + "coins": [ + { + "denom": "fermion", + "amount": 100 + }, + { + "denom": "moncoin", + "amount": 0 + }, + { + "denom": "leadertoken", + "amount": 0 + } + ] + }, { "name": "anton", "address": "40CC622438D3E42148A1FFD3A27C07C100F8FA3D", From 060091402b7737c9698207a30f9cce998b1b171e Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 6 Nov 2017 02:51:33 -0500 Subject: [PATCH 14/60] config.toml changes --- ansible/roles/config/templates/config.toml.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index c7a8a0533..090c7f62f 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -35,12 +35,12 @@ skip_timeout_commit = true timeout_commit = 1 wal_light = true block_part_size = 262144 -create_empty_blocks_interval = 1 +create_empty_blocks_interval = 60 {% else %} [consensus] -create_empty_blocks_interval = 10 +create_empty_blocks_interval = 60 {% endif %} From bbe151c1d2508e9b523fc2bccb1352af11977f1f Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 6 Nov 2017 14:25:29 -0500 Subject: [PATCH 15/60] change max_peer_num --- ansible/roles/config/templates/config.toml.j2 | 1 + 1 file changed, 1 insertion(+) diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 090c7f62f..6c9d4a23d 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -45,6 +45,7 @@ create_empty_blocks_interval = 60 {% endif %} [p2p] +max_num_peers = 300 {% if service == 'tendermint' %} max_msg_packet_payload_size=65536 send_rate=51200000 # 50 MB/s From 32ead683ce94f02c0a0c06933a8dfd80a63fcfe7 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 7 Nov 2017 16:52:02 -0500 Subject: [PATCH 16/60] Adding debug option --- ansible/roles/install/tasks/main.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ansible/roles/install/tasks/main.yml b/ansible/roles/install/tasks/main.yml index 59f97d36e..fd7932898 100644 --- a/ansible/roles/install/tasks/main.yml +++ b/ansible/roles/install/tasks/main.yml @@ -13,6 +13,9 @@ - name: Restart journald service: name=systemd-journald state=restarted +- name: Ability to get the core dump on SIGABRT + command: "ulimit -c unlimited" + #TODO include is deprecated in Ansible 2.4.0 and will be removed in 2.8.0 #Replace it with include_tasks From 862d7eb82c4218302c6e3f70a49fd339b45077a5 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 9 Nov 2017 11:19:06 -0500 Subject: [PATCH 17/60] ulimit in ansible fix --- ansible/roles/install/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/install/tasks/main.yml b/ansible/roles/install/tasks/main.yml index fd7932898..0e54ce655 100644 --- a/ansible/roles/install/tasks/main.yml +++ b/ansible/roles/install/tasks/main.yml @@ -14,7 +14,7 @@ service: name=systemd-journald state=restarted - name: Ability to get the core dump on SIGABRT - command: "ulimit -c unlimited" + shell: "ulimit -c unlimited" #TODO include is deprecated in Ansible 2.4.0 and will be removed in 2.8.0 #Replace it with include_tasks From 20576cab5f046098cd07568e3e80d2ae05a06a80 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 14 Nov 2017 23:17:41 -0500 Subject: [PATCH 18/60] go 1.9.2 dependency added --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 7a7af20cd..0a4b4ab6b 100644 --- a/build/Makefile +++ b/build/Makefile @@ -3,7 +3,7 @@ ## extra_check = true -go_min_version = 1.8.3 +go_min_version = 1.9.2 gpg_key = 2122CBE9 ifeq ($(extra_check),true) From ce6eab5ea9c0b5cba80ca02dca76917725d7b4fa Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 22 Nov 2017 19:24:42 -0500 Subject: [PATCH 19/60] Makefile build test --- build/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 0a4b4ab6b..c1f500f55 100644 --- a/build/Makefile +++ b/build/Makefile @@ -102,7 +102,8 @@ build-basecoin: git-branch ### # set app_version -version-%: $(GOPATH)/bin/% +#version-%: $(GOPATH)/bin/% +version-%: if [ -z "$(BUILD_NUMBER)" ]; then echo "BUILD_NUMBER not set" ; false ; fi $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) From a1d529e5cf8d0828a9148bc8597f68c60c8b02fe Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 22 Nov 2017 19:32:39 -0500 Subject: [PATCH 20/60] folder test fix in build --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index c1f500f55..74b803acf 100644 --- a/build/Makefile +++ b/build/Makefile @@ -104,7 +104,7 @@ build-basecoin: git-branch # set app_version #version-%: $(GOPATH)/bin/% version-%: - if [ -z "$(BUILD_NUMBER)" ]; then echo "BUILD_NUMBER not set" ; false ; fi + test -n "$(BUILD_NUMBER)" $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) # set build_folder From dd5f81e4309944f62655dbdb8b3c7ecdc1c07d4a Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 22 Nov 2017 23:56:57 -0500 Subject: [PATCH 21/60] Reset Makefile changes --- build/Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/build/Makefile b/build/Makefile index 74b803acf..957d59efd 100644 --- a/build/Makefile +++ b/build/Makefile @@ -102,9 +102,8 @@ build-basecoin: git-branch ### # set app_version -#version-%: $(GOPATH)/bin/% -version-%: - test -n "$(BUILD_NUMBER)" +version-%: $(GOPATH)/bin/% + test -z "$(BUILD_NUMBER)" && echo "BUILD_NUMBER is not set" && false $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) # set build_folder From ae85a7ae411331ddb9bfbee6a9edc02e5270128d Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 22 Nov 2017 23:59:10 -0500 Subject: [PATCH 22/60] Build Makefile changes --- build/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 957d59efd..c64917604 100644 --- a/build/Makefile +++ b/build/Makefile @@ -103,7 +103,8 @@ build-basecoin: git-branch # set app_version version-%: $(GOPATH)/bin/% - test -z "$(BUILD_NUMBER)" && echo "BUILD_NUMBER is not set" && false + @echo "BUILD_NUMBER is $(BUILD_NUMBER)" + test -n "$(BUILD_NUMBER)" $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) # set build_folder From 4b7260cdc56bb200da569ff823a6ef1db74d4ea0 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 23 Nov 2017 00:07:03 -0500 Subject: [PATCH 23/60] Build Makefile changes --- build/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index c64917604..4caaf26ff 100644 --- a/build/Makefile +++ b/build/Makefile @@ -102,7 +102,9 @@ build-basecoin: git-branch ### # set app_version -version-%: $(GOPATH)/bin/% +version-%: + @echo "Checking if binary exists" + test -n $(GOPATH)/bin/$* @echo "BUILD_NUMBER is $(BUILD_NUMBER)" test -n "$(BUILD_NUMBER)" $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) From 8bfb54d1aa7466c2f3b087e716bc2c573faa7b18 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 23 Nov 2017 00:10:09 -0500 Subject: [PATCH 24/60] Build Makefile changes --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 4caaf26ff..6251ce07d 100644 --- a/build/Makefile +++ b/build/Makefile @@ -107,7 +107,7 @@ version-%: test -n $(GOPATH)/bin/$* @echo "BUILD_NUMBER is $(BUILD_NUMBER)" test -n "$(BUILD_NUMBER)" - $(eval $*_version=$(shell $< version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) + $(eval $*_version=$(shell $(GOPATH)/bin/$* version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) # set build_folder folder-%: version-% From 3905c11934d8e51a0f98986445d547d9fd26ffb9 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 1 Dec 2017 12:03:16 -0500 Subject: [PATCH 25/60] Crude hack from developers to fix gometalinter dependency --- build/Makefile | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/build/Makefile b/build/Makefile index 6251ce07d..72f488666 100644 --- a/build/Makefile +++ b/build/Makefile @@ -56,22 +56,15 @@ build-tendermint: git-branch @echo "*** Building tendermint" go get -d -u github.com/tendermint/tendermint/cmd/tendermint cd $(GOPATH)/src/github.com/tendermint/tendermint && git checkout "$(GIT_BRANCH)" && git pull - $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_vendor_deps build + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_vendor_deps build cp $(GOPATH)/src/github.com/tendermint/tendermint/build/tendermint $(GOPATH)/bin @echo "*** Built tendermint" -#build-basecoin: git-branch -# @echo "*** Building basecoin-old" -# go get -d -u github.com/tendermint/basecoin/cmd/basecoin -# cd $(GOPATH)/src/github.com/tendermint/basecoin && git checkout "$(GIT_BRANCH)" && git pull -# $(MAKE) -C $(GOPATH)/src/github.com/tendermint/basecoin get_vendor_deps install -# @echo "*** Built basecoin" - build-ethermint: git-branch @echo "*** Building ethermint" go get -d -u github.com/tendermint/ethermint/cmd/ethermint cd $(GOPATH)/src/github.com/tendermint/ethermint && git checkout "$(GIT_BRANCH)" && git pull - $(MAKE) -C $(GOPATH)/src/github.com/tendermint/ethermint get_vendor_deps build + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/ethermint get_vendor_deps build cp $(GOPATH)/src/github.com/tendermint/ethermint/build/ethermint $(GOPATH)/bin @echo "*** Built ethermint" @@ -79,7 +72,7 @@ build-trackomatron: git-branch @echo "*** Building trackomatron" go get -d -u github.com/tendermint/trackomatron/cmd/tracko cd $(GOPATH)/src/github.com/tendermint/trackomatron && git checkout "$(GIT_BRANCH)" && git pull - $(MAKE) -C $(GOPATH)/src/github.com/tendermint/trackomatron get_vendor_deps install + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/trackomatron get_vendor_deps install @echo "Workaround: trackomatron package has tracko as the binary - trackomatron needed for proper packaging" && rm -rf $(GOPATH)/bin/trackomatron && ln -s $(GOPATH)/bin/tracko $(GOPATH)/bin/trackomatron @echo "*** Built trackomatron" @@ -87,14 +80,14 @@ build-gaia: git-branch @echo "*** Building gaia" go get -d -u go github.com/cosmos/gaia || echo "Workaround for go downloads." cd $(GOPATH)/src/github.com/cosmos/gaia && git checkout "$(GIT_BRANCH)" && git pull - $(MAKE) -C $(GOPATH)/src/github.com/cosmos/gaia get_vendor_deps install + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/gaia get_vendor_deps install @echo "*** Built gaia" build-basecoin: git-branch @echo "*** Building basecoin from cosmos-sdk" go get -d -u go github.com/cosmos/cosmos-sdk || echo "Workaround for go downloads." cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull - $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_vendor_deps install + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_vendor_deps install @echo "*** Built basecoin from cosmos-sdk" ### From 2a0fbdfc97b50dc6675cf100dd06ccf039b0d6be Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 5 Dec 2017 09:16:50 -0500 Subject: [PATCH 26/60] Makefile fixes for empty GOPATH directories --- build/Makefile | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/build/Makefile b/build/Makefile index 72f488666..c0927fdaa 100644 --- a/build/Makefile +++ b/build/Makefile @@ -1,12 +1,13 @@ ## -# Extra checks, because we do not use autoconf. Set extra_check to false if it is bothering you. +# Extra checks, because we do not use autoconf. ## -extra_check = true +requirements_check = true +gpg_check = false go_min_version = 1.9.2 gpg_key = 2122CBE9 -ifeq ($(extra_check),true) +ifeq ($(requirements_check),true) ifndef GOPATH $(error GOPATH not set) else @@ -17,6 +18,7 @@ ifneq ($(go_min_version),$(go_version_check)) $(error go version go_min_version or above is required) endif endif +ifeq ($(gpg_check),true) gpg_check := $(shell gpg -K | grep '/$(gpg_key) ' | sed 's,^.*/\($(gpg_key)\) .*$$,\1,') ifneq ($(gpg_check),$(gpg_key)) $(error GPG key $(gpg_key) not found.) @@ -27,6 +29,7 @@ ifndef GPG_PASSPHRASE $(error GPG_PASSPHRASE not set) endif endif +endif ### # Here comes the real deal @@ -52,7 +55,12 @@ $(binaries): %: build-% package-rpm-% package-deb-% git-branch: $(eval GIT_BRANCH=$(shell echo $${GIT_BRANCH:-master})) -build-tendermint: git-branch +gopath-setup: + test -d $(GOPATH) || mkdir -p $(GOPATH) + test -d $(GOPATH)/bin || mkdir -p $(GOPATH)/bin + test -d $(GOPATH)/src || mkdir -p $(GOPATH)/src + +build-tendermint: git-branch gopath-setup @echo "*** Building tendermint" go get -d -u github.com/tendermint/tendermint/cmd/tendermint cd $(GOPATH)/src/github.com/tendermint/tendermint && git checkout "$(GIT_BRANCH)" && git pull @@ -60,7 +68,7 @@ build-tendermint: git-branch cp $(GOPATH)/src/github.com/tendermint/tendermint/build/tendermint $(GOPATH)/bin @echo "*** Built tendermint" -build-ethermint: git-branch +build-ethermint: git-branch gopath-setup @echo "*** Building ethermint" go get -d -u github.com/tendermint/ethermint/cmd/ethermint cd $(GOPATH)/src/github.com/tendermint/ethermint && git checkout "$(GIT_BRANCH)" && git pull @@ -68,7 +76,7 @@ build-ethermint: git-branch cp $(GOPATH)/src/github.com/tendermint/ethermint/build/ethermint $(GOPATH)/bin @echo "*** Built ethermint" -build-trackomatron: git-branch +build-trackomatron: git-branch gopath-setup @echo "*** Building trackomatron" go get -d -u github.com/tendermint/trackomatron/cmd/tracko cd $(GOPATH)/src/github.com/tendermint/trackomatron && git checkout "$(GIT_BRANCH)" && git pull @@ -76,14 +84,14 @@ build-trackomatron: git-branch @echo "Workaround: trackomatron package has tracko as the binary - trackomatron needed for proper packaging" && rm -rf $(GOPATH)/bin/trackomatron && ln -s $(GOPATH)/bin/tracko $(GOPATH)/bin/trackomatron @echo "*** Built trackomatron" -build-gaia: git-branch +build-gaia: git-branch gopath-setup @echo "*** Building gaia" go get -d -u go github.com/cosmos/gaia || echo "Workaround for go downloads." cd $(GOPATH)/src/github.com/cosmos/gaia && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/gaia get_vendor_deps install @echo "*** Built gaia" -build-basecoin: git-branch +build-basecoin: git-branch gopath-setup @echo "*** Building basecoin from cosmos-sdk" go get -d -u go github.com/cosmos/cosmos-sdk || echo "Workaround for go downloads." cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull @@ -97,7 +105,7 @@ build-basecoin: git-branch # set app_version version-%: @echo "Checking if binary exists" - test -n $(GOPATH)/bin/$* + test -f $(GOPATH)/bin/$* @echo "BUILD_NUMBER is $(BUILD_NUMBER)" test -n "$(BUILD_NUMBER)" $(eval $*_version=$(shell $(GOPATH)/bin/$* version | head -1 | cut -d- -f1 | sed 's/^\(ethermint:\s*\|\)\(v\|\)//' | tr -d '\t ' )) From 62c6b48277e8e983694a06489605048dea4bafa0 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 6 Dec 2017 09:39:33 -0500 Subject: [PATCH 27/60] Gaia build deprecated gaiacli --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index c0927fdaa..6642ad610 100644 --- a/build/Makefile +++ b/build/Makefile @@ -126,7 +126,7 @@ prepare-ethermint = mkdir -p $(build_folder)/etc/ethermint && \ cp $(GOPATH)/src/github.com/tendermint/ethermint/setup/genesis.json $(build_folder)/etc/ethermint/genesis.json && \ cp -r $(GOPATH)/src/github.com/tendermint/ethermint/setup/keystore $(build_folder)/etc/ethermint prepare-trackomatron = rm -f $(build_folder)/usr/bin/trackomatron && cp $(GOPATH)/bin/tracko $(GOPATH)/bin/trackocli $(build_folder)/usr/bin -prepare-gaia = cp $(GOPATH)/bin/gaiacli $(build_folder)/usr/bin +prepare-gaia = prepare-basecoin = cp $(GOPATH)/bin/basecli $(GOPATH)/bin/basecoin $(GOPATH)/bin/baseserver $(GOPATH)/bin/counter $(GOPATH)/bin/countercli $(GOPATH)/bin/eyes $(GOPATH)/bin/eyescli $(build_folder)/usr/bin ### From 1ade893555aaf86c3e1ff1957c72863839e8041b Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 6 Dec 2017 09:41:16 -0500 Subject: [PATCH 28/60] More gaiacli cleanup --- build/Makefile | 1 - build/spectemplates/gaia.data | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/build/Makefile b/build/Makefile index 6642ad610..635a882d0 100644 --- a/build/Makefile +++ b/build/Makefile @@ -294,7 +294,6 @@ distclean: clean rm -rf $(GOPATH)/bin/basecli rm -rf $(GOPATH)/bin/ethermint rm -rf $(GOPATH)/bin/gaia - rm -rf $(GOPATH)/bin/gaiacli rm -rf $(GOPATH)/bin/tracko rm -rf $(GOPATH)/bin/trackocli diff --git a/build/spectemplates/gaia.data b/build/spectemplates/gaia.data index dad756e47..7152b1b51 100644 --- a/build/spectemplates/gaia.data +++ b/build/spectemplates/gaia.data @@ -1,5 +1,5 @@ PACKAGE_SUMMARY="gaia - Tendermint Cosmos delegation game chain" PACKAGE_URL="https://cosmos.network/" -PACKAGE_ADDITIONAL_HEADER="Provides: gaiacli" +PACKAGE_ADDITIONAL_HEADER="" PACKAGE_DESCRIPTION="Gaia description comes later." From 9620e36ed7d342010676578ecedb3ff44b198c46 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 7 Dec 2017 22:24:17 -0500 Subject: [PATCH 29/60] Permanent journald fix --- ansible/roles/install/tasks/main.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ansible/roles/install/tasks/main.yml b/ansible/roles/install/tasks/main.yml index 0e54ce655..939b1acec 100644 --- a/ansible/roles/install/tasks/main.yml +++ b/ansible/roles/install/tasks/main.yml @@ -10,6 +10,12 @@ - { regexp: "^#RateLimitInterval", line: "RateLimitInterval=0s" } - { regexp: "^#RateLimitBurst", line: "RateLimitBurst=0" } +- name: Create journal directory for permanent logs + file: path=/var/log/journal state=directory + +- name: Set journal folder with systemd-tmpfiles + command: "systemd-tmpfiles --create --prefix /var/log/journal" + - name: Restart journald service: name=systemd-journald state=restarted From d5ffce28fd0ab032e04eb1135b6f45af0f45a502 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 12 Dec 2017 00:01:50 -0500 Subject: [PATCH 30/60] gaia node start added to building package --- build/gaia/etc/systemd/system/gaia.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gaia/etc/systemd/system/gaia.service b/build/gaia/etc/systemd/system/gaia.service index 2a8b3195e..6d7057874 100644 --- a/build/gaia/etc/systemd/system/gaia.service +++ b/build/gaia/etc/systemd/system/gaia.service @@ -17,7 +17,7 @@ Restart=on-failure User=gaia Group=gaia PermissionsStartOnly=true -ExecStart=/usr/bin/gaia start --without-tendermint --home=/etc/gaia +ExecStart=/usr/bin/gaia node start --without-tendermint --home=/etc/gaia ExecReload=/bin/kill -HUP $MAINPID KillSignal=SIGTERM From 85710237fd366012157cfa8b4b9c71a6a3f15a4e Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 13 Dec 2017 10:25:23 -0500 Subject: [PATCH 31/60] Fabo coin --- ansible/app_options_files/public_testnet | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index b4accc753..0ce453e88 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -290,6 +290,16 @@ "amount": 100000 } ] + }, + { + "name": "Fabo", + "address": "DF096FDE8D380FA5B2AD20DB2962C82DDEA1ED9B", + "coins": [ + { + "denom": "fermion", + "amount": 100 + } + ] } ], From 6680240fbe44df78621a91c5089ff7f8901d3eea Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Thu, 14 Dec 2017 01:06:45 -0500 Subject: [PATCH 32/60] Coin changes, config changes --- ansible/app_options_files/public_testnet | 16 +++++++++++++++- ansible/roles/config/templates/config.toml.j2 | 4 ++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 0ce453e88..a52fdd51e 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -175,7 +175,7 @@ }, { "name": "peng", - "address": "7B8422A210D0F0B8734908C093ECF0E9A768BDB8", + "address": "DC97A6E1A3E1FE868B55BA93C7FC626368261E09", "coins": [ { "denom": "fermion", @@ -300,6 +300,20 @@ "amount": 100 } ] + }, + { + "name": "chjango", + "address": "1C0F9000D0AF1CBCAF8EAD636B729797905D6D24", + "coins": [ + { + "denom": "fermion", + "amount": 100 + }, + { + "denom": "tokenchjango", + "amount": 1000 + } + ] } ], diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 6c9d4a23d..807a6494d 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -42,10 +42,14 @@ create_empty_blocks_interval = 60 [consensus] create_empty_blocks_interval = 60 +[tx_index] +index_all_tags = true + {% endif %} [p2p] max_num_peers = 300 +pex = true {% if service == 'tendermint' %} max_msg_packet_payload_size=65536 send_rate=51200000 # 50 MB/s From 9692f68d507305e6023761aab67e14148274cc45 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 20 Dec 2017 05:09:42 -0500 Subject: [PATCH 33/60] Generic service fix --- ansible/roles/generic-service/templates/systemd.service.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/generic-service/templates/systemd.service.j2 b/ansible/roles/generic-service/templates/systemd.service.j2 index 201b7942d..c38cca468 100644 --- a/ansible/roles/generic-service/templates/systemd.service.j2 +++ b/ansible/roles/generic-service/templates/systemd.service.j2 @@ -4,7 +4,7 @@ Requires=network-online.target After=network-online.target [Service] -Environment="TMHOME=/etc/{{service}}/tendermint" +Environment="TMHOME=/etc/{{service}}" Restart=on-failure User={{service}} Group={{service}} From d8dd7491e22a837e84b7cbf4f0ea562e377d49da Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 29 Dec 2017 13:48:14 -0500 Subject: [PATCH 34/60] Added get_tools to build tendermint --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 635a882d0..fd8bc94db 100644 --- a/build/Makefile +++ b/build/Makefile @@ -64,7 +64,7 @@ build-tendermint: git-branch gopath-setup @echo "*** Building tendermint" go get -d -u github.com/tendermint/tendermint/cmd/tendermint cd $(GOPATH)/src/github.com/tendermint/tendermint && git checkout "$(GIT_BRANCH)" && git pull - export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_vendor_deps build + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_tools get_vendor_deps build cp $(GOPATH)/src/github.com/tendermint/tendermint/build/tendermint $(GOPATH)/bin @echo "*** Built tendermint" From 91ce3af5641fde0de4a36fa903d70d26af32d538 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 5 Jan 2018 21:25:28 -0500 Subject: [PATCH 35/60] Makefile fix for new deterministic makefile in tendermint repo --- build/Makefile | 1 - 1 file changed, 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index fd8bc94db..3611918a2 100644 --- a/build/Makefile +++ b/build/Makefile @@ -65,7 +65,6 @@ build-tendermint: git-branch gopath-setup go get -d -u github.com/tendermint/tendermint/cmd/tendermint cd $(GOPATH)/src/github.com/tendermint/tendermint && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_tools get_vendor_deps build - cp $(GOPATH)/src/github.com/tendermint/tendermint/build/tendermint $(GOPATH)/bin @echo "*** Built tendermint" build-ethermint: git-branch gopath-setup From 1d10217df230448f15cd0e83787d2f5d6a842db4 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sun, 21 Jan 2018 13:01:50 -0500 Subject: [PATCH 36/60] tendermint build fix --- build/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/build/Makefile b/build/Makefile index 3611918a2..fd8bc94db 100644 --- a/build/Makefile +++ b/build/Makefile @@ -65,6 +65,7 @@ build-tendermint: git-branch gopath-setup go get -d -u github.com/tendermint/tendermint/cmd/tendermint cd $(GOPATH)/src/github.com/tendermint/tendermint && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/tendermint get_tools get_vendor_deps build + cp $(GOPATH)/src/github.com/tendermint/tendermint/build/tendermint $(GOPATH)/bin @echo "*** Built tendermint" build-ethermint: git-branch gopath-setup From c00faa8960c8b62e58042e22fe060f06567d282b Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 26 Jan 2018 08:08:18 -0500 Subject: [PATCH 37/60] Token spitter wallet --- ansible/app_options_files/public_testnet | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index a52fdd51e..52f6add05 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -187,6 +187,16 @@ } ] }, + { + "name": "token-splitter", + "address": "2406B52B1DE26F992E5BF334E5F30049C682B5CB", + "coins": [ + { + "denom": "fermion", + "amount": 10000 + } + ] + }, { "name": "matt", "address": "C2104A8191E282AA45D210BA93282B36768EDDA1", From b3a14da617ec50a0a04c20949d98f8689b107d66 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sun, 28 Jan 2018 21:11:37 -0500 Subject: [PATCH 38/60] basecoin build fix --- build/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/Makefile b/build/Makefile index fd8bc94db..93379fa93 100644 --- a/build/Makefile +++ b/build/Makefile @@ -93,9 +93,9 @@ build-gaia: git-branch gopath-setup build-basecoin: git-branch gopath-setup @echo "*** Building basecoin from cosmos-sdk" - go get -d -u go github.com/cosmos/cosmos-sdk || echo "Workaround for go downloads." + go get -d -u github.com/cosmos/cosmos-sdk/examples/basecoin/cmd/basecoind cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull - export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_vendor_deps install + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps install @echo "*** Built basecoin from cosmos-sdk" ### From 1f3e1eec832408b63a4046cba83b00d0333520a7 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sun, 28 Jan 2018 21:14:50 -0500 Subject: [PATCH 39/60] basecoin build copy fix --- build/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/build/Makefile b/build/Makefile index 93379fa93..73419ca1b 100644 --- a/build/Makefile +++ b/build/Makefile @@ -96,6 +96,7 @@ build-basecoin: git-branch gopath-setup go get -d -u github.com/cosmos/cosmos-sdk/examples/basecoin/cmd/basecoind cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps install + cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoin $(GOPATH)/bin @echo "*** Built basecoin from cosmos-sdk" ### From c6190b385968365b3aacfbf4e5ce3757588082ca Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sun, 28 Jan 2018 22:37:58 -0500 Subject: [PATCH 40/60] basecoin build typo fix --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 73419ca1b..215a22e61 100644 --- a/build/Makefile +++ b/build/Makefile @@ -95,7 +95,7 @@ build-basecoin: git-branch gopath-setup @echo "*** Building basecoin from cosmos-sdk" go get -d -u github.com/cosmos/cosmos-sdk/examples/basecoin/cmd/basecoind cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull - export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps install + export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps build cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoin $(GOPATH)/bin @echo "*** Built basecoin from cosmos-sdk" From 73a4cfb06a6dc9707e12de3b2f6e04d69d089fc1 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sun, 28 Jan 2018 22:49:44 -0500 Subject: [PATCH 41/60] moer basecoin build fixes --- build/Makefile | 5 ++--- build/spectemplates/basecoin.data | 2 +- build/spectemplates/cosmos-sdk.data | 2 +- build/spectemplates/ethermint.data | 2 +- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/build/Makefile b/build/Makefile index 215a22e61..7b05c33da 100644 --- a/build/Makefile +++ b/build/Makefile @@ -128,7 +128,7 @@ prepare-ethermint = mkdir -p $(build_folder)/etc/ethermint && \ cp -r $(GOPATH)/src/github.com/tendermint/ethermint/setup/keystore $(build_folder)/etc/ethermint prepare-trackomatron = rm -f $(build_folder)/usr/bin/trackomatron && cp $(GOPATH)/bin/tracko $(GOPATH)/bin/trackocli $(build_folder)/usr/bin prepare-gaia = -prepare-basecoin = cp $(GOPATH)/bin/basecli $(GOPATH)/bin/basecoin $(GOPATH)/bin/baseserver $(GOPATH)/bin/counter $(GOPATH)/bin/countercli $(GOPATH)/bin/eyes $(GOPATH)/bin/eyescli $(build_folder)/usr/bin +prepare-basecoin = cp $(GOPATH)/bin/basecoin $(build_folder)/usr/bin ### # Package the binary for CentOS/RedHat (RPM) and Debian/Ubuntu (DEB) @@ -287,12 +287,11 @@ clean: mostlyclean distclean: clean rm -rf $(GOPATH)/src/github.com/tendermint/tendermint - rm -rf $(GOPATH)/src/github.com/tendermint/basecoin + rm -rf $(GOPATH)/src/github.com/cosmos/cosmos-sdk rm -rf $(GOPATH)/src/github.com/tendermint/ethermint rm -rf $(GOPATH)/src/github.com/tendermint/trackomatron rm -rf $(GOPATH)/bin/tendermint rm -rf $(GOPATH)/bin/basecoin - rm -rf $(GOPATH)/bin/basecli rm -rf $(GOPATH)/bin/ethermint rm -rf $(GOPATH)/bin/gaia rm -rf $(GOPATH)/bin/tracko diff --git a/build/spectemplates/basecoin.data b/build/spectemplates/basecoin.data index b74d64309..b5e0f3728 100644 --- a/build/spectemplates/basecoin.data +++ b/build/spectemplates/basecoin.data @@ -1,5 +1,5 @@ PACKAGE_SUMMARY="basecoin is a Proof-of-Stake cryptocurrency and framework" PACKAGE_URL="https://cosmos.network/" -PACKAGE_ADDITIONAL_HEADER="Provides: basecli" +PACKAGE_ADDITIONAL_HEADER="Provides: basecoin" PACKAGE_DESCRIPTION="Basecoin is an ABCI application designed to be used with the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. It also provides a general purpose framework for extending the feature-set of the cryptocurrency by implementing plugins." diff --git a/build/spectemplates/cosmos-sdk.data b/build/spectemplates/cosmos-sdk.data index 5b00998a0..3b2da23ca 100644 --- a/build/spectemplates/cosmos-sdk.data +++ b/build/spectemplates/cosmos-sdk.data @@ -1,5 +1,5 @@ PACKAGE_SUMMARY="cosmos-sdk is a Proof-of-Stake framework" PACKAGE_URL="https://cosmos.network/" -PACKAGE_ADDITIONAL_HEADER="Provides: basecoin basecli" +PACKAGE_ADDITIONAL_HEADER="Provides: basecoin" PACKAGE_DESCRIPTION="Cosmos-SDK is a general purpose framework for the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency." diff --git a/build/spectemplates/ethermint.data b/build/spectemplates/ethermint.data index b736c0bb8..e9d403db7 100644 --- a/build/spectemplates/ethermint.data +++ b/build/spectemplates/ethermint.data @@ -1,5 +1,5 @@ PACKAGE_SUMMARY="ethermint enables ethereum as an ABCI application on tendermint and the COSMOS hub" PACKAGE_URL="https://tendermint.com/" -PACKAGE_ADDITIONAL_HEADER="Provides: basecli" +PACKAGE_ADDITIONAL_HEADER="Provides: ethermint" PACKAGE_DESCRIPTION="Ethermint enables ethereum to run as an ABCI application on tendermint and the COSMOS hub. This application allows you to get all the benefits of ethereum without having to run your own miners." From af30cef5747d868de99d134e8164fd66c800e5c9 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 30 Jan 2018 09:45:05 -0500 Subject: [PATCH 42/60] Coin changes for Peng's faucet --- ansible/app_options_files/public_testnet | 66 ++++++++++++++++++++---- 1 file changed, 57 insertions(+), 9 deletions(-) diff --git a/ansible/app_options_files/public_testnet b/ansible/app_options_files/public_testnet index 52f6add05..9320b3f65 100644 --- a/ansible/app_options_files/public_testnet +++ b/ansible/app_options_files/public_testnet @@ -119,7 +119,7 @@ "coins": [ { "denom": "fermion", - "amount": 10000000000 + "amount": 10000 }, { "denom": "buckycoin", @@ -137,7 +137,7 @@ }, { "denom": "fermion", - "amount": 10000 + "amount": 1000 } ] }, @@ -151,17 +151,13 @@ }, { "denom": "fermion", - "amount": 10000 + "amount": 1000 } ] }, { "name": "shadow", "address": "B140EFAAE6D5CA1C8E98814C557AF7112E3B9EAE", - "pub_key": { - "type": "ed25519", - "data": "F492282705DF29ACC3BB803D543B7BF98C8080FA28AE85B62B45827EA9DA8167" - }, "coins": [ { "denom": "fermion", @@ -188,12 +184,64 @@ ] }, { - "name": "token-splitter", + "name": "official-faucet", "address": "2406B52B1DE26F992E5BF334E5F30049C682B5CB", "coins": [ { "denom": "fermion", - "amount": 10000 + "amount": 100000 + }, + { + "denom": "antoncoin", + "amount": 100000 + }, + { + "denom": "adriancoin", + "amount": 100000 + }, + { + "denom": "buckycoin", + "amount": 100000 + }, + { + "denom": "rigelcoin", + "amount": 100000 + }, + { + "denom": "shadowcoin", + "amount": 100000 + }, + { + "denom": "pengcoin", + "amount": 100000 + }, + { + "denom": "mattcoin", + "amount": 100000 + }, + { + "denom": "freycoin", + "amount": 100000 + }, + { + "denom": "wancloudcoin", + "amount": 100000 + }, + { + "denom": "bianjiecoin", + "amount": 100000 + }, + { + "denom": "alexiscoin", + "amount": 100000 + }, + { + "denom": "zakicoin", + "amount": 100000 + }, + { + "denom": "gregcoin", + "amount": 100000 } ] }, From ffb806f2b2d11f857d644691ed2fdcce668b46be Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Wed, 7 Feb 2018 16:22:51 -0500 Subject: [PATCH 43/60] Updated go version to 1.9.4 on build --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 7b05c33da..15978bbb1 100644 --- a/build/Makefile +++ b/build/Makefile @@ -4,7 +4,7 @@ requirements_check = true gpg_check = false -go_min_version = 1.9.2 +go_min_version = 1.9.4 gpg_key = 2122CBE9 ifeq ($(requirements_check),true) From 9bd1f28b8d3085240b84ae6bb784f773ab307553 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 12 Feb 2018 09:41:54 -0500 Subject: [PATCH 44/60] Minor package changes --- build/basecoin/DEBIAN/postinst | 8 ++------ build/ethermint/DEBIAN/postinst | 6 +----- build/gaia/DEBIAN/postinst | 10 ++-------- build/spectemplates/app-template.spec | 2 +- 4 files changed, 6 insertions(+), 20 deletions(-) diff --git a/build/basecoin/DEBIAN/postinst b/build/basecoin/DEBIAN/postinst index 9a06d6e3f..9d30d77ea 100644 --- a/build/basecoin/DEBIAN/postinst +++ b/build/basecoin/DEBIAN/postinst @@ -20,12 +20,8 @@ set -e case "$1" in configure) chown basecoin.basecoin /etc/basecoin - sudo -Hu basecoin basecoin init --home /etc/basecoin 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - #The above command generates a genesis.json file that contains validators. This is wrong, the validator part should be empty. https://github.com/tendermint/basecoin/issues/124 - sudo -Hu basecoin tendermint init --home /etc/basecoin/tendermint - #The above command might need some kind of additional option in the future. https://github.com/tendermint/tendermint/issues/542 - chmod 755 /etc/basecoin/tendermint - chown basecoin.basecoin /etc/basecoin/tendermint + sudo -Hu basecoin basecoin node init --home /etc/basecoin 2B24DEE2364762300168DF19B6C18BCE2D399EA2 + sudo -Hu basecoin tendermint init --home /etc/basecoin systemctl daemon-reload ;; diff --git a/build/ethermint/DEBIAN/postinst b/build/ethermint/DEBIAN/postinst index 90739f818..d2f968358 100644 --- a/build/ethermint/DEBIAN/postinst +++ b/build/ethermint/DEBIAN/postinst @@ -25,11 +25,7 @@ case "$1" in chown ethermint.ethermint /etc/ethermint/keystore/UTC--2016-10-21T22-30-03.071787745Z--7eff122b94897ea5b0e2a9abf47b86337fafebdc sudo -Hu ethermint /usr/bin/ethermint --datadir /etc/ethermint init /etc/ethermint/genesis.json - sudo -Hu ethermint tendermint init --home /etc/ethermint/tendermint - - chown ethermint.ethermint /etc/ethermint/tendermint - chmod 755 /etc/ethermint/tendermint - + sudo -Hu ethermint tendermint init --home /etc/ethermint systemctl daemon-reload ;; diff --git a/build/gaia/DEBIAN/postinst b/build/gaia/DEBIAN/postinst index e1b606cb8..9bca36119 100644 --- a/build/gaia/DEBIAN/postinst +++ b/build/gaia/DEBIAN/postinst @@ -20,14 +20,8 @@ set -e case "$1" in configure) chown gaia.gaia /etc/gaia - sudo -Hu gaia gaia init --home /etc/gaia 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - #The above command generates a genesis.json file that contains validators. This is wrong, the validator part should be empty. https://github.com/tendermint/basecoin/issues/124 - sudo -Hu gaia tendermint init --home /etc/gaia/tendermint - #The above command might need some kind of additional option in the future. https://github.com/tendermint/tendermint/issues/542 - - chmod 755 /etc/gaia/tendermint - chown gaia.gaia /etc/gaia/tendermint - + sudo -Hu gaia gaia node init --home /etc/gaia 2B24DEE2364762300168DF19B6C18BCE2D399EA2 + sudo -Hu gaia tendermint init --home /etc/gaia systemctl daemon-reload ;; diff --git a/build/spectemplates/app-template.spec b/build/spectemplates/app-template.spec index ad937d029..a622d1b4c 100644 --- a/build/spectemplates/app-template.spec +++ b/build/spectemplates/app-template.spec @@ -36,7 +36,7 @@ cd %{name}-%{version}-%{release} %post sudo -Hu %{name} tendermint init --home %{_sysconfdir}/%{name} -sudo -Hu %{name} %{name} init --home %{_sysconfdir}/%{name} 2B24DEE2364762300168DF19B6C18BCE2D399EA2 +sudo -Hu %{name} %{name} node init --home %{_sysconfdir}/%{name} 2B24DEE2364762300168DF19B6C18BCE2D399EA2 #Temporary until https://github.com/tendermint/basecoin/issues/123 rm -f %{_sysconfdir}/%{name}/key.json From 1eb7a8a2cc47dd45c318e3f49a50c83d3f56e3cb Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 19 Feb 2018 19:38:29 -0500 Subject: [PATCH 45/60] Removed trackomatron, updated config to tendermint 0.16 (config dir) and changed services to in-process --- ansible/roles/config/tasks/main.yml | 16 +- ansible/roles/config/templates/config.toml.j2 | 200 +++++++++++++++--- ansible/roles/getconfigtoml/tasks/main.yml | 2 +- ansible/roles/status/tasks/main.yml | 16 +- build/Makefile | 24 +-- build/basecoin/DEBIAN/postinst | 1 - build/basecoin/DEBIAN/prerm | 1 - .../systemd/system-preset/50-basecoin.preset | 1 - .../systemd/system/basecoin-server.service | 24 --- .../etc/systemd/system/basecoin.service | 16 +- build/ethermint/DEBIAN/postinst | 2 +- build/ethermint/DEBIAN/prerm | 1 - .../systemd/system-preset/50-ethermint.preset | 1 - .../systemd/system/ethermint-server.service | 24 --- .../etc/systemd/system/ethermint.service | 14 +- build/gaia/DEBIAN/postinst | 1 - build/gaia/DEBIAN/prerm | 1 - .../etc/systemd/system-preset/50-gaia.preset | 1 - .../etc/systemd/system/gaia-server.service | 24 --- build/gaia/etc/systemd/system/gaia.service | 16 +- build/spectemplates/app-template.spec | 7 - build/spectemplates/cosmos-sdk.data | 5 - build/spectemplates/trackomatron.data | 5 - build/spectemplates/trackomatron.spec | 63 ------ 24 files changed, 207 insertions(+), 259 deletions(-) delete mode 100644 build/basecoin/etc/systemd/system/basecoin-server.service delete mode 100644 build/ethermint/etc/systemd/system/ethermint-server.service delete mode 100644 build/gaia/etc/systemd/system/gaia-server.service delete mode 100644 build/spectemplates/cosmos-sdk.data delete mode 100644 build/spectemplates/trackomatron.data delete mode 100644 build/spectemplates/trackomatron.spec diff --git a/ansible/roles/config/tasks/main.yml b/ansible/roles/config/tasks/main.yml index 5130a4a1f..50ebe1001 100644 --- a/ansible/roles/config/tasks/main.yml +++ b/ansible/roles/config/tasks/main.yml @@ -3,7 +3,7 @@ - name: gather tendermint public keys 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" + command: "/usr/bin/tendermint show_validator --home /etc/{{service}}/config --log_level error" register: pubkeys changed_when: false @@ -22,21 +22,21 @@ tags: reconfig-genesis template: src: genesis.json.j2 - dest: "/etc/{{service}}/genesis.json" + dest: "/etc/{{service}}/config/genesis.json" owner: "{{service}}" group: "{{service}}" - 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}}" + copy: "src={{genesis_file}} dest=/etc/{{service}}/config/genesis.json owner={{service}} group={{service}}" - name: copy tendermint config.toml tags: reconfig-toml when: validators == true or validators == 'true' template: src: config.toml.j2 - dest: "/etc/{{service}}/config.toml" + dest: "/etc/{{service}}/config/config.toml" owner: "{{service}}" group: "{{service}}" @@ -45,14 +45,14 @@ tags: reconfig-toml,reconfig-genesis get_url: "url={{item['src']}} dest={{item['dst']}} force=yes" with_items: - - { src: "https://raw.githubusercontent.com/tendermint/testnets/master/{{validator_network}}/{{service}}/genesis.json" , dst: "/etc/{{service}}/genesis.json" } - - { src: "https://raw.githubusercontent.com/tendermint/testnets/master/{{validator_network}}/config.toml" , dst: "/etc/{{service}}/config.toml" } + - { src: "https://raw.githubusercontent.com/tendermint/testnets/master/{{validator_network}}/{{service}}/genesis.json" , dst: "/etc/{{service}}/config/genesis.json" } + - { src: "https://raw.githubusercontent.com/tendermint/testnets/master/{{validator_network}}/config.toml" , dst: "/etc/{{service}}/config/config.toml" } - name: Set validator network files permissions for non-validators when: validators == false or validators == 'false' tags: reconfig-toml,reconfig-genesis file: "path={{item}} owner={{service}} group={{service}}" with_items: - - "/etc/{{service}}/genesis.json" - - "/etc/{{service}}/config.toml" + - "/etc/{{service}}/config/genesis.json" + - "/etc/{{service}}/config/config.toml" diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 13e2be318..6ebc28ed4 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -1,63 +1,213 @@ # This is a TOML config file. # For more information, see https://github.com/toml-lang/toml +##### main base config options ##### + +# TCP or UNIX socket address of the ABCI application, +# or the name of an ABCI application compiled in with the Tendermint binary proxy_app = "tcp://127.0.0.1:46658" + +# A custom human readable name for this node moniker = "{{inventory_hostname}}" + +# If this node is many blocks behind the tip of the chain, FastSync +# allows them to catchup quickly by downloading blocks in parallel +# and verifying their commits fast_sync = true + {% if service == 'tendermint' %} +# Database backend: leveldb | memdb db_backend = "memdb" + +# Database directory +db_path = "data" + +# Output level for logging, including package level options log_level = "mempool:error,*:debug" {% else %} +# Database backend: leveldb | memdb db_backend = "leveldb" -log_level = "state:info,*:error" -#log_level = "*:debug" + +# Database directory +db_path = "data" + +# Output level for logging, including package level options +log_level = "main:info,state:info,*:error" +#log_level = "mempool:error,*:debug" {% endif %} +##### additional base config options ##### + +# Path to the JSON file containing the initial validator set and other meta data +genesis_file = "config/genesis.json" + +# Path to the JSON file containing the private key to use as a validator in the consensus protocol +priv_validator_file = "config/priv_validator.json" + +# Path to the JSON file containing the private key to use for node authentication in the p2p protocol +node_key_file = "config/node_key.json" + +# Mechanism to connect to the ABCI application: socket | grpc +abci = "socket" + +# TCP or UNIX socket address for the profiling server to listen on +prof_laddr = "" + +# If true, query the ABCI app on connecting to a new peer +# so the app can decide if we should keep the connection or not +filter_peers = false + +##### advanced configuration options ##### + +##### rpc server configuration options ##### [rpc] + +# TCP or UNIX socket address for the RPC server to listen on laddr = "tcp://0.0.0.0:46657" +# TCP or UNIX socket address for the gRPC server to listen on +# NOTE: This server only supports /broadcast_tx_commit +grpc_laddr = "" + +# Activate unsafe RPC commands like /dial_seeds and /unsafe_flush_mempool +unsafe = false + +##### peer to peer configuration options ##### +[p2p] + +# Address to listen for incoming connections +laddr = "tcp://0.0.0.0:46656" + +# Comma separated list of seed nodes to connect to +{% if validators == true or validators == 'true' %} +{% set comma = joiner(",") %}seeds = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" +{% else %} +seeds = "{{ seeds | default() }}" +{% endif %} + +# Comma separated list of nodes to keep persistent connections to +persistent_peers = "" + +# Path to address book +addr_book_file = "config/addrbook.json" + +# Set true for strict address routability rules +addr_book_strict = true + +# Time to wait before flushing messages out on the connection, in ms +flush_throttle_timeout = 100 + +# Maximum number of peers to connect to +#max_num_peers = 50 +max_num_peers = 300 + +# Maximum size of a message packet payload, in bytes +{% if service == 'tendermint' %} +max_msg_packet_payload_size = 65536 +{% else %} +max_msg_packet_payload_size = 1024 +{% endif %} + +# Rate at which packets can be sent, in bytes/second +{% if service == 'tendermint' %} +send_rate = 51200000 # 50 MB/s +{% else %} +send_rate = 512000 +{% endif %} + +# Rate at which packets can be received, in bytes/second {% if service == 'tendermint' %} +recv_rate = 51200000 # 50 MB/s +{% else %} +recv_rate = 512000 +{% endif %} + +# Set true to enable the peer-exchange reactor +pex = true + +# Seed mode, in which node constantly crawls the network and looks for +# peers. If another node asks it for addresses, it responds and disconnects. +# +# Does not work if the peer-exchange reactor is disabled. +seed_mode = false +##### mempool configuration options ##### [mempool] + +{% if service == 'tendermint' %} recheck = false +{% else %} +recheck = true +{% endif %} +recheck_empty = true broadcast = true +{% if service == 'tendermint' %} wal_dir = "" +{% else %} +wal_dir = "data/mempool.wal" +{% endif %} +##### consensus configuration options ##### [consensus] -max_block_size_txs = 10000 -create_empty_blocks = false + +wal_file = "data/cs.wal/wal" +{% if service == 'tendermint' %} +wal_light = true +{% else %} +wal_light = false +{% endif %} + +# All timeouts are in milliseconds +{% if service == 'tendermint' %} timeout_propose = 10000 -skip_timeout_commit = true +{% else %} +timeout_propose = 3000 +{% endif %} +timeout_propose_delta = 500 +timeout_prevote = 1000 +timeout_prevote_delta = 500 +timeout_precommit = 1000 +timeout_precommit_delta = 500 +{% if service == 'tendermint' %} timeout_commit = 1 -wal_light = true -block_part_size = 262144 -create_empty_blocks_interval = 60 +{% else %} +timeout_commit = 1000 +{% endif %} +# Make progress as soon as we have all the precommits (as if TimeoutCommit = 0) +{% if service == 'tendermint' %} +skip_timeout_commit = true {% else %} +skip_timeout_commit = false +{% endif %} -[consensus] +# BlockSize +max_block_size_txs = 10000 +max_block_size_bytes = 1 + +# EmptyBlocks mode and possible interval between empty blocks in seconds +{% if service == 'tendermint' %} +create_empty_blocks = false +{% else %} +create_empty_blocks = true create_empty_blocks_interval = 60 +{% endif %} + +# Reactor sleep duration parameters are in milliseconds +peer_gossip_sleep_duration = 100 +peer_query_maj23_sleep_duration = 2000 +##### transactions indexer configuration options ##### [tx_index] -index_all_tags = true -{% endif %} +# What indexer to use for transactions +# +# Options: +# 1) "null" (default) +# 2) "kv" - the simplest possible indexer, backed by key-value storage (defaults to levelDB; see DBBackend). +indexer = "kv" -[p2p] -max_num_peers = 300 -pex = true -{% if service == 'tendermint' %} -max_msg_packet_payload_size=65536 -send_rate=51200000 # 50 MB/s -recv_rate=51200000 # 50 MB/s -{% endif %} -laddr = "tcp://0.0.0.0:46656" -{% if validators == true or validators == 'true' %} -{% set comma = joiner(",") %}seeds = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" -{% else %} -seeds = "{{ seeds | default() }}" -{% endif %} diff --git a/ansible/roles/getconfigtoml/tasks/main.yml b/ansible/roles/getconfigtoml/tasks/main.yml index d0495f103..5daab5b6f 100644 --- a/ansible/roles/getconfigtoml/tasks/main.yml +++ b/ansible/roles/getconfigtoml/tasks/main.yml @@ -1,6 +1,6 @@ --- - name: Get config.toml from node - fetch: "dest={{ destination | default('.') }}/config.toml flat=yes src=/etc/{{service}}/config.toml" + fetch: "dest={{ destination | default('.') }}/config.toml flat=yes src=/etc/{{service}}/config/config.toml" run_once: yes diff --git a/ansible/roles/status/tasks/main.yml b/ansible/roles/status/tasks/main.yml index d063ee564..c9229d400 100644 --- a/ansible/roles/status/tasks/main.yml +++ b/ansible/roles/status/tasks/main.yml @@ -8,13 +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: 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 +#- name: Result +# when: service != 'tendermint' +# debug: var=tendermintstatus.stdout_lines diff --git a/build/Makefile b/build/Makefile index 15978bbb1..650771dc2 100644 --- a/build/Makefile +++ b/build/Makefile @@ -35,12 +35,12 @@ endif # Here comes the real deal ### -binaries = tendermint basecoin ethermint trackomatron gaia -build-binaries = build-tendermint build-basecoin build-ethermint build-trackomatron build-gaia -package-rpm = package-rpm-tendermint package-rpm-basecoin package-rpm-ethermint package-rpm-trackomatron package-rpm-gaia -install-rpm = install-rpm-tendermint install-rpm-basecoin install-rpm-ethermint install-rpm-trackomatron install-rpm-gaia -package-deb = package-deb-tendermint package-deb-basecoin package-deb-ethermint package-deb-trackomatron package-deb-gaia -install-deb = install-deb-tendermint install-deb-basecoin install-deb-ethermint install-deb-trackomatron install-deb-gaia +binaries = tendermint basecoin ethermint gaia +build-binaries = build-tendermint build-basecoin build-ethermint build-gaia +package-rpm = package-rpm-tendermint package-rpm-basecoin package-rpm-ethermint package-rpm-gaia +install-rpm = install-rpm-tendermint install-rpm-basecoin install-rpm-ethermint install-rpm-gaia +package-deb = package-deb-tendermint package-deb-basecoin package-deb-ethermint package-deb-gaia +install-deb = install-deb-tendermint install-deb-basecoin install-deb-ethermint install-deb-gaia all: $(binaries) build: $(build-binaries) @@ -76,14 +76,6 @@ build-ethermint: git-branch gopath-setup cp $(GOPATH)/src/github.com/tendermint/ethermint/build/ethermint $(GOPATH)/bin @echo "*** Built ethermint" -build-trackomatron: git-branch gopath-setup - @echo "*** Building trackomatron" - go get -d -u github.com/tendermint/trackomatron/cmd/tracko - cd $(GOPATH)/src/github.com/tendermint/trackomatron && git checkout "$(GIT_BRANCH)" && git pull - export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/tendermint/trackomatron get_vendor_deps install - @echo "Workaround: trackomatron package has tracko as the binary - trackomatron needed for proper packaging" && rm -rf $(GOPATH)/bin/trackomatron && ln -s $(GOPATH)/bin/tracko $(GOPATH)/bin/trackomatron - @echo "*** Built trackomatron" - build-gaia: git-branch gopath-setup @echo "*** Building gaia" go get -d -u go github.com/cosmos/gaia || echo "Workaround for go downloads." @@ -126,7 +118,6 @@ prepare-tendermint = prepare-ethermint = mkdir -p $(build_folder)/etc/ethermint && \ cp $(GOPATH)/src/github.com/tendermint/ethermint/setup/genesis.json $(build_folder)/etc/ethermint/genesis.json && \ cp -r $(GOPATH)/src/github.com/tendermint/ethermint/setup/keystore $(build_folder)/etc/ethermint -prepare-trackomatron = rm -f $(build_folder)/usr/bin/trackomatron && cp $(GOPATH)/bin/tracko $(GOPATH)/bin/trackocli $(build_folder)/usr/bin prepare-gaia = prepare-basecoin = cp $(GOPATH)/bin/basecoin $(build_folder)/usr/bin @@ -289,13 +280,10 @@ distclean: clean rm -rf $(GOPATH)/src/github.com/tendermint/tendermint rm -rf $(GOPATH)/src/github.com/cosmos/cosmos-sdk rm -rf $(GOPATH)/src/github.com/tendermint/ethermint - rm -rf $(GOPATH)/src/github.com/tendermint/trackomatron rm -rf $(GOPATH)/bin/tendermint rm -rf $(GOPATH)/bin/basecoin rm -rf $(GOPATH)/bin/ethermint rm -rf $(GOPATH)/bin/gaia - rm -rf $(GOPATH)/bin/tracko - rm -rf $(GOPATH)/bin/trackocli .PHONY : clean diff --git a/build/basecoin/DEBIAN/postinst b/build/basecoin/DEBIAN/postinst index 9d30d77ea..9bdc58678 100644 --- a/build/basecoin/DEBIAN/postinst +++ b/build/basecoin/DEBIAN/postinst @@ -21,7 +21,6 @@ case "$1" in configure) chown basecoin.basecoin /etc/basecoin sudo -Hu basecoin basecoin node init --home /etc/basecoin 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - sudo -Hu basecoin tendermint init --home /etc/basecoin systemctl daemon-reload ;; diff --git a/build/basecoin/DEBIAN/prerm b/build/basecoin/DEBIAN/prerm index 5cc57e154..389f40267 100644 --- a/build/basecoin/DEBIAN/prerm +++ b/build/basecoin/DEBIAN/prerm @@ -19,7 +19,6 @@ set -e case "$1" in remove|upgrade|deconfigure) systemctl stop basecoin 2> /dev/null || : - systemctl stop basecoin-service 2> /dev/null || : ;; failed-upgrade) diff --git a/build/basecoin/etc/systemd/system-preset/50-basecoin.preset b/build/basecoin/etc/systemd/system-preset/50-basecoin.preset index c97097b13..b35369c2d 100644 --- a/build/basecoin/etc/systemd/system-preset/50-basecoin.preset +++ b/build/basecoin/etc/systemd/system-preset/50-basecoin.preset @@ -1,3 +1,2 @@ disable basecoin.service -disable basecoin-server.service diff --git a/build/basecoin/etc/systemd/system/basecoin-server.service b/build/basecoin/etc/systemd/system/basecoin-server.service deleted file mode 100644 index 5bf269498..000000000 --- a/build/basecoin/etc/systemd/system/basecoin-server.service +++ /dev/null @@ -1,24 +0,0 @@ -[Unit] -Description=Basecoin server -Requires=network-online.target -BindTo=basecoin.service -PartOf=basecoin.service -Before=basecoin.service -After=network-online.target -PropagatesReloadTo=basecoin.service -ReloadPropagatedFrom=basecoin.service - -[Service] -Environment="TMHOME=/etc/basecoin" -Restart=on-failure -User=basecoin -Group=basecoin -PermissionsStartOnly=true -ExecStart=/usr/bin/tendermint node -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target -Also=basecoin.service - diff --git a/build/basecoin/etc/systemd/system/basecoin.service b/build/basecoin/etc/systemd/system/basecoin.service index 3b62e75bd..27878ff71 100644 --- a/build/basecoin/etc/systemd/system/basecoin.service +++ b/build/basecoin/etc/systemd/system/basecoin.service @@ -1,16 +1,7 @@ [Unit] Description=Basecoin -#propagates activation, deactivation and activation fails. Requires=network-online.target -#propagates activation, deactivation, activation fails and stops -BindTo=basecoin-server.service -#propagates stop and restart (one-way) -PartOf=basecoin-server.service -#order -After=network-online.target basecoin-server.service -#propagates reload -PropagatesReloadTo=basecoin-server.service -ReloadPropagatedFrom=basecoin-server.service +After=network-online.target [Service] Environment="BCHOME=/etc/basecoin" @@ -18,11 +9,10 @@ Restart=on-failure User=basecoin Group=basecoin PermissionsStartOnly=true -ExecStart=/usr/bin/basecoin start --without-tendermint +ExecStart=/usr/bin/basecoind start ExecReload=/bin/kill -HUP $MAINPID KillSignal=SIGTERM [Install] -WantedBy=multi-user.target basecoin-server.service -Also=basecoin-server.service +WantedBy=multi-user.target diff --git a/build/ethermint/DEBIAN/postinst b/build/ethermint/DEBIAN/postinst index d2f968358..439fdc395 100644 --- a/build/ethermint/DEBIAN/postinst +++ b/build/ethermint/DEBIAN/postinst @@ -1,5 +1,5 @@ #!/bin/sh -# postinst script for basecoin +# postinst script for ethermint # set -e diff --git a/build/ethermint/DEBIAN/prerm b/build/ethermint/DEBIAN/prerm index 5af626fdf..00a775cef 100644 --- a/build/ethermint/DEBIAN/prerm +++ b/build/ethermint/DEBIAN/prerm @@ -19,7 +19,6 @@ set -e case "$1" in remove|upgrade|deconfigure) systemctl stop ethermint 2> /dev/null || : - systemctl stop ethermint-service 2> /dev/null || : ;; failed-upgrade) diff --git a/build/ethermint/etc/systemd/system-preset/50-ethermint.preset b/build/ethermint/etc/systemd/system-preset/50-ethermint.preset index f181a0bcc..836a28c30 100644 --- a/build/ethermint/etc/systemd/system-preset/50-ethermint.preset +++ b/build/ethermint/etc/systemd/system-preset/50-ethermint.preset @@ -1,3 +1,2 @@ disable ethermint.service -disable ethermint-server.service diff --git a/build/ethermint/etc/systemd/system/ethermint-server.service b/build/ethermint/etc/systemd/system/ethermint-server.service deleted file mode 100644 index 4cbd8adcf..000000000 --- a/build/ethermint/etc/systemd/system/ethermint-server.service +++ /dev/null @@ -1,24 +0,0 @@ -[Unit] -Description=Ethermint server -Requires=network-online.target -BindTo=ethermint.service -PartOf=ethermint.service -Before=ethermint.service -After=network-online.target -PropagatesReloadTo=ethermint.service -ReloadPropagatedFrom=ethermint.service - -[Service] -Environment="TMHOME=/etc/ethermint" -Restart=on-failure -User=ethermint -Group=ethermint -PermissionsStartOnly=true -ExecStart=/usr/bin/tendermint node -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target ethermint.service -Also=ethermint.service - diff --git a/build/ethermint/etc/systemd/system/ethermint.service b/build/ethermint/etc/systemd/system/ethermint.service index ad03103ab..f71a074ea 100644 --- a/build/ethermint/etc/systemd/system/ethermint.service +++ b/build/ethermint/etc/systemd/system/ethermint.service @@ -1,16 +1,7 @@ [Unit] Description=Ethermint -#propagates activation, deactivation and activation fails. Requires=network-online.target -#propagates activation, deactivation, activation fails and stops -BindTo=ethermint-server.service -#propagates stop and restart (one-way) -PartOf=ethermint-server.service -#order -After=network-online.target ethermint-server.service -#propagates reload -PropagatesReloadTo=ethermint-server.service -ReloadPropagatedFrom=ethermint-server.service +After=network-online.target [Service] Restart=on-failure @@ -22,6 +13,5 @@ ExecReload=/bin/kill -HUP $MAINPID KillSignal=SIGTERM [Install] -WantedBy=multi-user.target ethermint-server.service -Also=ethermint-server.service +WantedBy=multi-user.target diff --git a/build/gaia/DEBIAN/postinst b/build/gaia/DEBIAN/postinst index 9bca36119..427b7c493 100644 --- a/build/gaia/DEBIAN/postinst +++ b/build/gaia/DEBIAN/postinst @@ -21,7 +21,6 @@ case "$1" in configure) chown gaia.gaia /etc/gaia sudo -Hu gaia gaia node init --home /etc/gaia 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - sudo -Hu gaia tendermint init --home /etc/gaia systemctl daemon-reload ;; diff --git a/build/gaia/DEBIAN/prerm b/build/gaia/DEBIAN/prerm index 8a0522a41..165c1ab6a 100644 --- a/build/gaia/DEBIAN/prerm +++ b/build/gaia/DEBIAN/prerm @@ -19,7 +19,6 @@ set -e case "$1" in remove|upgrade|deconfigure) systemctl stop gaia 2> /dev/null || : - systemctl stop gaia-service 2> /dev/null || : ;; failed-upgrade) diff --git a/build/gaia/etc/systemd/system-preset/50-gaia.preset b/build/gaia/etc/systemd/system-preset/50-gaia.preset index a9fe09116..dfbf0bc06 100644 --- a/build/gaia/etc/systemd/system-preset/50-gaia.preset +++ b/build/gaia/etc/systemd/system-preset/50-gaia.preset @@ -1,3 +1,2 @@ disable gaia.service -disable gaia-server.service diff --git a/build/gaia/etc/systemd/system/gaia-server.service b/build/gaia/etc/systemd/system/gaia-server.service deleted file mode 100644 index ef0f65cab..000000000 --- a/build/gaia/etc/systemd/system/gaia-server.service +++ /dev/null @@ -1,24 +0,0 @@ -[Unit] -Description=Gaia server -Requires=network-online.target -BindTo=gaia.service -PartOf=gaia.service -Before=gaia.service -After=network-online.target -PropagatesReloadTo=gaia.service -ReloadPropagatedFrom=gaia.service - -[Service] -Environment="TMHOME=/etc/gaia" -Restart=on-failure -User=gaia -Group=gaia -PermissionsStartOnly=true -ExecStart=/usr/bin/tendermint node -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target -Also=gaia.service - diff --git a/build/gaia/etc/systemd/system/gaia.service b/build/gaia/etc/systemd/system/gaia.service index 6d7057874..372fe9343 100644 --- a/build/gaia/etc/systemd/system/gaia.service +++ b/build/gaia/etc/systemd/system/gaia.service @@ -1,27 +1,17 @@ [Unit] Description=Gaia -#propagates activation, deactivation and activation fails. Requires=network-online.target -#propagates activation, deactivation, activation fails and stops -BindTo=gaia-server.service -#propagates stop and restart (one-way) -PartOf=gaia-server.service -#order -After=network-online.target gaia-server.service -#propagates reload -PropagatesReloadTo=gaia-server.service -ReloadPropagatedFrom=gaia-server.service +After=network-online.target [Service] Restart=on-failure User=gaia Group=gaia PermissionsStartOnly=true -ExecStart=/usr/bin/gaia node start --without-tendermint --home=/etc/gaia +ExecStart=/usr/bin/gaia node start --home=/etc/gaia ExecReload=/bin/kill -HUP $MAINPID KillSignal=SIGTERM [Install] -WantedBy=multi-user.target gaia-server.service -Also=gaia-server.service +WantedBy=multi-user.target diff --git a/build/spectemplates/app-template.spec b/build/spectemplates/app-template.spec index a622d1b4c..a035fbe8f 100644 --- a/build/spectemplates/app-template.spec +++ b/build/spectemplates/app-template.spec @@ -35,18 +35,11 @@ cd %{name}-%{version}-%{release} %{__cp} -a * %{buildroot} %post -sudo -Hu %{name} tendermint init --home %{_sysconfdir}/%{name} sudo -Hu %{name} %{name} node init --home %{_sysconfdir}/%{name} 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - -#Temporary until https://github.com/tendermint/basecoin/issues/123 -rm -f %{_sysconfdir}/%{name}/key.json -rm -f %{_sysconfdir}/%{name}/key2.json - systemctl daemon-reload %preun systemctl stop %{name} 2> /dev/null || : -systemctl stop %{name}-service 2> /dev/null || : %postun systemctl daemon-reload diff --git a/build/spectemplates/cosmos-sdk.data b/build/spectemplates/cosmos-sdk.data deleted file mode 100644 index 3b2da23ca..000000000 --- a/build/spectemplates/cosmos-sdk.data +++ /dev/null @@ -1,5 +0,0 @@ -PACKAGE_SUMMARY="cosmos-sdk is a Proof-of-Stake framework" -PACKAGE_URL="https://cosmos.network/" -PACKAGE_ADDITIONAL_HEADER="Provides: basecoin" -PACKAGE_DESCRIPTION="Cosmos-SDK is a general purpose framework for the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency." - diff --git a/build/spectemplates/trackomatron.data b/build/spectemplates/trackomatron.data deleted file mode 100644 index daaad64b3..000000000 --- a/build/spectemplates/trackomatron.data +++ /dev/null @@ -1,5 +0,0 @@ -PACKAGE_SUMMARY="Trackomatron - Track invoices on the blockchain" -PACKAGE_URL="https://tendermint.com/" -PACKAGE_ADDITIONAL_HEADER="" -PACKAGE_DESCRIPTION="This software is intended to create a space to easily send invoices between and within institutions. Firstly, the commands of trackmatron are separated into two broad categories: submitting information to the blockchain (transactions), and retrieving information from the blockchain (query)." - diff --git a/build/spectemplates/trackomatron.spec b/build/spectemplates/trackomatron.spec deleted file mode 100644 index 1c952411e..000000000 --- a/build/spectemplates/trackomatron.spec +++ /dev/null @@ -1,63 +0,0 @@ -Version: @VERSION@ -Release: @BUILD_NUMBER@ - -%define __spec_install_post %{nil} -%define debug_package %{nil} -%define __os_install_post %{nil} - -Name: @PACKAGE_NAME@ -Summary: @PACKAGE_SUMMARY@ -License: Apache 2.0 -URL: @PACKAGE_URL@ -Packager: Greg Szabo -Requires: tendermint >= 0.11.0 -@PACKAGE_ADDITIONAL_HEADER@ - -%description -@PACKAGE_DESCRIPTION@ - -%pre -if ! %{__grep} -q '^%{name}:' /etc/passwd ; then - useradd -r -b %{_sysconfdir} %{name} - mkdir -p %{_sysconfdir}/%{name} - chmod 755 %{_sysconfdir}/%{name} - chown %{name}.%{name} %{_sysconfdir}/%{name} -fi - -%prep -# Nothing to do here. - It is done in the Makefile. - -%build -# Nothing to do here. - -%install -cd %{name}-%{version}-%{release} -%{__cp} -a * %{buildroot} - -%post -sudo -Hu %{name} tendermint init --home %{_sysconfdir}/%{name} -sudo -Hu %{name} tracko init --home %{_sysconfdir}/%{name} 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - -#Temporary until https://github.com/tendermint/basecoin/issues/123 -rm -f %{_sysconfdir}/%{name}/key.json -rm -f %{_sysconfdir}/%{name}/key2.json - -systemctl daemon-reload - -%preun -systemctl stop %{name} 2> /dev/null || : -systemctl stop %{name}-service 2> /dev/null || : - -%postun -systemctl daemon-reload - -%files -%ghost %attr(0755, %{name}, %{name}) %dir %{_sysconfdir}/%{name} -%{_bindir}/* -%{_sysconfdir}/systemd/system/* -%{_sysconfdir}/systemd/system-preset/* -%dir %{_datadir}/%{name} -%{_datadir}/%{name}/* -%dir %{_defaultlicensedir}/%{name} -%doc %{_defaultlicensedir}/%{name}/LICENSE - From e31150398eb070fcfbd73096aafaf93a2a1497d0 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 19 Feb 2018 19:49:26 -0500 Subject: [PATCH 46/60] Removed unused files, removed tendermint package dependency --- build/basecoin/DEBIAN/control | 1 - build/cosmos-sdk/DEBIAN/changelog | 6 --- build/cosmos-sdk/DEBIAN/compat | 1 - build/cosmos-sdk/DEBIAN/control | 15 ------ build/cosmos-sdk/DEBIAN/copyright | 21 -------- build/cosmos-sdk/DEBIAN/postinst | 46 ------------------ build/cosmos-sdk/DEBIAN/postrm | 41 ---------------- build/cosmos-sdk/DEBIAN/preinst | 38 --------------- build/cosmos-sdk/DEBIAN/prerm | 39 --------------- .../system-preset/50-cosmos-sdk.preset | 3 -- .../systemd/system/cosmos-sdk-server.service | 23 --------- .../etc/systemd/system/cosmos-sdk.service | 29 ----------- .../cosmos-sdk/usr/share/cosmos-sdk/key.json | 12 ----- .../cosmos-sdk/usr/share/cosmos-sdk/key2.json | 12 ----- build/gaia/DEBIAN/control | 1 - build/spectemplates/app-template.spec | 1 - build/trackomatron/DEBIAN/changelog | 6 --- build/trackomatron/DEBIAN/compat | 1 - build/trackomatron/DEBIAN/control | 15 ------ build/trackomatron/DEBIAN/copyright | 21 -------- build/trackomatron/DEBIAN/postinst | 48 ------------------- build/trackomatron/DEBIAN/postrm | 41 ---------------- build/trackomatron/DEBIAN/preinst | 38 --------------- build/trackomatron/DEBIAN/prerm | 39 --------------- .../system-preset/50-trackomatron.preset | 3 -- .../system/trackomatron-server.service | 24 ---------- .../etc/systemd/system/trackomatron.service | 27 ----------- .../usr/share/trackomatron/key.json | 12 ----- .../usr/share/trackomatron/key2.json | 12 ----- 29 files changed, 576 deletions(-) delete mode 100644 build/cosmos-sdk/DEBIAN/changelog delete mode 100644 build/cosmos-sdk/DEBIAN/compat delete mode 100644 build/cosmos-sdk/DEBIAN/control delete mode 100644 build/cosmos-sdk/DEBIAN/copyright delete mode 100644 build/cosmos-sdk/DEBIAN/postinst delete mode 100644 build/cosmos-sdk/DEBIAN/postrm delete mode 100644 build/cosmos-sdk/DEBIAN/preinst delete mode 100644 build/cosmos-sdk/DEBIAN/prerm delete mode 100644 build/cosmos-sdk/etc/systemd/system-preset/50-cosmos-sdk.preset delete mode 100644 build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service delete mode 100644 build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service delete mode 100644 build/cosmos-sdk/usr/share/cosmos-sdk/key.json delete mode 100644 build/cosmos-sdk/usr/share/cosmos-sdk/key2.json delete mode 100644 build/trackomatron/DEBIAN/changelog delete mode 100644 build/trackomatron/DEBIAN/compat delete mode 100644 build/trackomatron/DEBIAN/control delete mode 100644 build/trackomatron/DEBIAN/copyright delete mode 100644 build/trackomatron/DEBIAN/postinst delete mode 100644 build/trackomatron/DEBIAN/postrm delete mode 100644 build/trackomatron/DEBIAN/preinst delete mode 100644 build/trackomatron/DEBIAN/prerm delete mode 100644 build/trackomatron/etc/systemd/system-preset/50-trackomatron.preset delete mode 100644 build/trackomatron/etc/systemd/system/trackomatron-server.service delete mode 100644 build/trackomatron/etc/systemd/system/trackomatron.service delete mode 100644 build/trackomatron/usr/share/trackomatron/key.json delete mode 100644 build/trackomatron/usr/share/trackomatron/key2.json diff --git a/build/basecoin/DEBIAN/control b/build/basecoin/DEBIAN/control index c5857eb5d..e74091263 100644 --- a/build/basecoin/DEBIAN/control +++ b/build/basecoin/DEBIAN/control @@ -3,7 +3,6 @@ Section: net Priority: optional Maintainer: Greg Szabo Build-Depends: debhelper (>=9) -Depends: tendermint (>=0.11.0) Standards-Version: 3.9.6 Homepage: https://tendermint.com Package: basecoin diff --git a/build/cosmos-sdk/DEBIAN/changelog b/build/cosmos-sdk/DEBIAN/changelog deleted file mode 100644 index 13eb09125..000000000 --- a/build/cosmos-sdk/DEBIAN/changelog +++ /dev/null @@ -1,6 +0,0 @@ -cosmos-sdk (@VERSION@) @STABILITY@; urgency=medium - - * Automatic build. See https://github.com/cosmos/cosmos-sdk for more information. - - -- Greg Szabo @DATETIMESTAMP@ - diff --git a/build/cosmos-sdk/DEBIAN/compat b/build/cosmos-sdk/DEBIAN/compat deleted file mode 100644 index ec635144f..000000000 --- a/build/cosmos-sdk/DEBIAN/compat +++ /dev/null @@ -1 +0,0 @@ -9 diff --git a/build/cosmos-sdk/DEBIAN/control b/build/cosmos-sdk/DEBIAN/control deleted file mode 100644 index bf4e0229a..000000000 --- a/build/cosmos-sdk/DEBIAN/control +++ /dev/null @@ -1,15 +0,0 @@ -Source: cosmos-sdk -Section: net -Priority: optional -Maintainer: Greg Szabo -Build-Depends: debhelper (>=9) -Depends: tendermint (>=0.11.0) -Standards-Version: 3.9.6 -Homepage: https://tendermint.com -Package: cosmos-sdk -Architecture: amd64 -Version: @VERSION@ -Installed-Size: @INSTALLEDSIZE@ -Description: cosmos-sdk is a Proof-of-Stake framework - Cosmos-SDK is a general purpose framework for the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. - diff --git a/build/cosmos-sdk/DEBIAN/copyright b/build/cosmos-sdk/DEBIAN/copyright deleted file mode 100644 index ddb9d0272..000000000 --- a/build/cosmos-sdk/DEBIAN/copyright +++ /dev/null @@ -1,21 +0,0 @@ -Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: cosmos-sdk -Source: https://github.com/cosmos/cosmos-sdk - -Files: * -Copyright: 2017 All In Bits, Inc. -License: Apache-2.0 - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - . - On Debian systems, the full text of the Apache License 2.0 can be found - in the file `/usr/share/common-licenses/Apache-2.0'. diff --git a/build/cosmos-sdk/DEBIAN/postinst b/build/cosmos-sdk/DEBIAN/postinst deleted file mode 100644 index 7f179b0eb..000000000 --- a/build/cosmos-sdk/DEBIAN/postinst +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/sh -# postinst script for cosmos-sdk -# - -set -e - -# summary of how this script can be called: -# * `configure' -# * `abort-upgrade' -# * `abort-remove' `in-favour' -# -# * `abort-remove' -# * `abort-deconfigure' `in-favour' -# `removing' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - configure) - chown cosmos-sdk.cosmos-sdk /etc/cosmos-sdk - sudo -Hu cosmos-sdk basecoin init --home /etc/cosmos-sdk 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - #The above command generates a genesis.json file that contains validators. This is wrong, the validator part should be empty. https://github.com/tendermint/basecoin/issues/124 - sudo -Hu cosmos-sdk tendermint init --home /etc/cosmos-sdk/tendermint - #The above command might need some kind of additional option in the future. https://github.com/tendermint/tendermint/issues/542 - chmod 755 /etc/cosmos-sdk/tendermint - chown cosmos-sdk.cosmos-sdk /etc/cosmos-sdk/tendermint - systemctl daemon-reload - ;; - - abort-upgrade|abort-remove|abort-deconfigure) - ;; - - *) - echo "postinst called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/cosmos-sdk/DEBIAN/postrm b/build/cosmos-sdk/DEBIAN/postrm deleted file mode 100644 index e23f777d1..000000000 --- a/build/cosmos-sdk/DEBIAN/postrm +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -# postrm script for cosmos-sdk -# - -set -e - -# summary of how this script can be called: -# * `remove' -# * `purge' -# * `upgrade' -# * `failed-upgrade' -# * `abort-install' -# * `abort-install' -# * `abort-upgrade' -# * `disappear' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - upgrade|failed-upgrade|abort-upgrade) - systemctl daemon-reload - ;; - - purge|remove|abort-install|disappear) - systemctl daemon-reload - ;; - - *) - echo "postrm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/cosmos-sdk/DEBIAN/preinst b/build/cosmos-sdk/DEBIAN/preinst deleted file mode 100644 index f7108e5d6..000000000 --- a/build/cosmos-sdk/DEBIAN/preinst +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# preinst script for cosmos-sdk -# - -set -e - -# summary of how this script can be called: -# * `install' -# * `install' -# * `upgrade' -# * `abort-upgrade' -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - install|upgrade) - if ! grep -q '^cosmos-sdk:' /etc/passwd ; then - useradd -k /dev/null -r -m -b /etc cosmos-sdk - chmod 755 /etc/cosmos-sdk - fi - ;; - - abort-upgrade) - ;; - - *) - echo "preinst called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/cosmos-sdk/DEBIAN/prerm b/build/cosmos-sdk/DEBIAN/prerm deleted file mode 100644 index d7a07ab8f..000000000 --- a/build/cosmos-sdk/DEBIAN/prerm +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh -# prerm script for cosmos-sdk -# - -set -e - -# summary of how this script can be called: -# * `remove' -# * `upgrade' -# * `failed-upgrade' -# * `remove' `in-favour' -# * `deconfigure' `in-favour' -# `removing' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - remove|upgrade|deconfigure) - systemctl stop cosmos-sdk 2> /dev/null || : - systemctl stop cosmos-sdk-service 2> /dev/null || : - ;; - - failed-upgrade) - ;; - - *) - echo "prerm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/cosmos-sdk/etc/systemd/system-preset/50-cosmos-sdk.preset b/build/cosmos-sdk/etc/systemd/system-preset/50-cosmos-sdk.preset deleted file mode 100644 index 7f9e2f450..000000000 --- a/build/cosmos-sdk/etc/systemd/system-preset/50-cosmos-sdk.preset +++ /dev/null @@ -1,3 +0,0 @@ -disable cosmos-sdk.service -disable cosmos-sdk-server.service - diff --git a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service deleted file mode 100644 index d1d929ba6..000000000 --- a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service +++ /dev/null @@ -1,23 +0,0 @@ -[Unit] -Description=Cosmos SDK Basecoin Tendermint server -Requires=network-online.target -BindTo=cosmos-sdk.service -PartOf=cosmos-sdk.service -After=network-online.target cosmos-sdk.service -PropagatesReloadTo=cosmos-sdk.service -ReloadPropagatedFrom=cosmos-sdk.service - -[Service] -Environment="TMHOME=/etc/cosmos-sdk" -Restart=on-failure -User=cosmos-sdk -Group=cosmos-sdk -PermissionsStartOnly=true -ExecStart=/usr/bin/tendermint node -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target -Also=cosmos-sdk.service - diff --git a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service deleted file mode 100644 index 9d142195e..000000000 --- a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service +++ /dev/null @@ -1,29 +0,0 @@ -[Unit] -Description=Cosmos-SDK Basecoin -#propagates activation, deactivation and activation fails. -Requires=network-online.target -#propagates activation, deactivation, activation fails and stops -BindTo=cosmos-sdk-server.service -#propagates stop and restart (one-way) -PartOf=cosmos-sdk-server.service -#order -Before=cosmos-sdk-server.service -After=network-online.target -#propagates reload -PropagatesReloadTo=cosmos-sdk-server.service -ReloadPropagatedFrom=cosmos-sdk-server.service - -[Service] -Environment="BCHOME=/etc/cosmos-sdk" -Restart=on-failure -User=cosmos-sdk -Group=cosmos-sdk -PermissionsStartOnly=true -ExecStart=/usr/bin/basecoin start --without-tendermint -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target cosmos-sdk-server.service -Also=cosmos-sdk-server.service - diff --git a/build/cosmos-sdk/usr/share/cosmos-sdk/key.json b/build/cosmos-sdk/usr/share/cosmos-sdk/key.json deleted file mode 100644 index bdefe8fd4..000000000 --- a/build/cosmos-sdk/usr/share/cosmos-sdk/key.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "address": "1B1BE55F969F54064628A63B9559E7C21C925165", - "priv_key": { - "type": "ed25519", - "data": "C70D6934B4F55F1B7BC33B56B9CA8A2061384AFC19E91E44B40C4BBA182953D1619D3678599971ED29C7529DDD4DA537B97129893598A17C82E3AC9A8BA95279" - }, - "pub_key": { - "type": "ed25519", - "data": "619D3678599971ED29C7529DDD4DA537B97129893598A17C82E3AC9A8BA95279" - } -} - diff --git a/build/cosmos-sdk/usr/share/cosmos-sdk/key2.json b/build/cosmos-sdk/usr/share/cosmos-sdk/key2.json deleted file mode 100644 index ddfc6809b..000000000 --- a/build/cosmos-sdk/usr/share/cosmos-sdk/key2.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "address": "1DA7C74F9C219229FD54CC9F7386D5A3839F0090", - "priv_key": { - "type": "ed25519", - "data": "34BAE9E65CE8245FAD035A0E3EED9401BDE8785FFB3199ACCF8F5B5DDF7486A8352195DA90CB0B90C24295B90AEBA25A5A71BC61BAB2FE2387241D439698B7B8" - }, - "pub_key": { - "type": "ed25519", - "data": "352195DA90CB0B90C24295B90AEBA25A5A71BC61BAB2FE2387241D439698B7B8" - } -} - diff --git a/build/gaia/DEBIAN/control b/build/gaia/DEBIAN/control index 521a7cdba..55d1cd5dd 100644 --- a/build/gaia/DEBIAN/control +++ b/build/gaia/DEBIAN/control @@ -3,7 +3,6 @@ Section: net Priority: optional Maintainer: Greg Szabo Build-Depends: debhelper (>=9) -Depends: tendermint (>=0.11.0) Standards-Version: 3.9.6 Homepage: https://cosmos.network Package: gaia diff --git a/build/spectemplates/app-template.spec b/build/spectemplates/app-template.spec index a035fbe8f..6cb8145bb 100644 --- a/build/spectemplates/app-template.spec +++ b/build/spectemplates/app-template.spec @@ -10,7 +10,6 @@ Summary: @PACKAGE_SUMMARY@ License: Apache 2.0 URL: @PACKAGE_URL@ Packager: Greg Szabo -Requires: tendermint >= 0.11.0 @PACKAGE_ADDITIONAL_HEADER@ %description diff --git a/build/trackomatron/DEBIAN/changelog b/build/trackomatron/DEBIAN/changelog deleted file mode 100644 index aab92cc02..000000000 --- a/build/trackomatron/DEBIAN/changelog +++ /dev/null @@ -1,6 +0,0 @@ -trackomatron (@VERSION@) @STABILITY@; urgency=medium - - * Automatic build. See https://github.com/tendermint/trackomatron for more information. - - -- Greg Szabo @DATETIMESTAMP@ - diff --git a/build/trackomatron/DEBIAN/compat b/build/trackomatron/DEBIAN/compat deleted file mode 100644 index ec635144f..000000000 --- a/build/trackomatron/DEBIAN/compat +++ /dev/null @@ -1 +0,0 @@ -9 diff --git a/build/trackomatron/DEBIAN/control b/build/trackomatron/DEBIAN/control deleted file mode 100644 index a71d02ace..000000000 --- a/build/trackomatron/DEBIAN/control +++ /dev/null @@ -1,15 +0,0 @@ -Source: trackomatron -Section: net -Priority: optional -Maintainer: Greg Szabo -Build-Depends: debhelper (>=9) -Depends: tendermint (>=0.11.0) -Standards-Version: 3.9.6 -Homepage: https://tendermint.com -Package: trackomatron -Architecture: amd64 -Version: @VERSION@ -Installed-Size: @INSTALLEDSIZE@ -Description: Trackomatron - Track invoices on the blockchain - This software is intended to create a space to easily send invoices between and within institutions. Firstly, the commands of trackmatron are separated into two broad categories: submitting information to the blockchain (transactions), and retrieving information from the blockchain (query). - diff --git a/build/trackomatron/DEBIAN/copyright b/build/trackomatron/DEBIAN/copyright deleted file mode 100644 index 32a1921d5..000000000 --- a/build/trackomatron/DEBIAN/copyright +++ /dev/null @@ -1,21 +0,0 @@ -Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: trackomatron -Source: https://github.com/tendermint/trackomatron - -Files: * -Copyright: 2017 All In Bits, Inc. -License: Apache-2.0 - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - . - http://www.apache.org/licenses/LICENSE-2.0 - . - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - . - On Debian systems, the full text of the Apache License 2.0 can be found - in the file `/usr/share/common-licenses/Apache-2.0'. diff --git a/build/trackomatron/DEBIAN/postinst b/build/trackomatron/DEBIAN/postinst deleted file mode 100644 index 9aac7fc78..000000000 --- a/build/trackomatron/DEBIAN/postinst +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -# postinst script for trackomatron -# - -set -e - -# summary of how this script can be called: -# * `configure' -# * `abort-upgrade' -# * `abort-remove' `in-favour' -# -# * `abort-remove' -# * `abort-deconfigure' `in-favour' -# `removing' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - configure) - chown trackomatron.trackomatron /etc/trackomatron - sudo -Hu trackomatron tracko init --home /etc/trackomatron 2B24DEE2364762300168DF19B6C18BCE2D399EA2 - #The above command generates a genesis.json file that contains validators. This is wrong, the validator part should be empty. https://github.com/tendermint/basecoin/issues/124 - sudo -Hu trackomatron tendermint init --home /etc/trackomatron/tendermint - #The above command might need some kind of additional option in the future. https://github.com/tendermint/tendermint/issues/542 - - chown trackomatron.trackomatron /etc/trackomatron/tendermint - chmod 755 /etc/trackomatron/tendermint - - systemctl daemon-reload - ;; - - abort-upgrade|abort-remove|abort-deconfigure) - ;; - - *) - echo "postinst called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/trackomatron/DEBIAN/postrm b/build/trackomatron/DEBIAN/postrm deleted file mode 100644 index 445d4fbd8..000000000 --- a/build/trackomatron/DEBIAN/postrm +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -# postrm script for trackomatron -# - -set -e - -# summary of how this script can be called: -# * `remove' -# * `purge' -# * `upgrade' -# * `failed-upgrade' -# * `abort-install' -# * `abort-install' -# * `abort-upgrade' -# * `disappear' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - upgrade|failed-upgrade|abort-upgrade) - systemctl daemon-reload - ;; - - purge|remove|abort-install|disappear) - systemctl daemon-reload - ;; - - *) - echo "postrm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/trackomatron/DEBIAN/preinst b/build/trackomatron/DEBIAN/preinst deleted file mode 100644 index ac866587a..000000000 --- a/build/trackomatron/DEBIAN/preinst +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# preinst script for trackomatron -# - -set -e - -# summary of how this script can be called: -# * `install' -# * `install' -# * `upgrade' -# * `abort-upgrade' -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - install|upgrade) - if ! grep -q '^trackomatron:' /etc/passwd ; then - useradd -k /dev/null -r -m -b /etc trackomatron - chmod 755 /etc/trackomatron - fi - ;; - - abort-upgrade) - ;; - - *) - echo "preinst called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/trackomatron/DEBIAN/prerm b/build/trackomatron/DEBIAN/prerm deleted file mode 100644 index e18afec04..000000000 --- a/build/trackomatron/DEBIAN/prerm +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh -# prerm script for trackomatron -# - -set -e - -# summary of how this script can be called: -# * `remove' -# * `upgrade' -# * `failed-upgrade' -# * `remove' `in-favour' -# * `deconfigure' `in-favour' -# `removing' -# -# for details, see https://www.debian.org/doc/debian-policy/ or -# the debian-policy package - - -case "$1" in - remove|upgrade|deconfigure) - systemctl stop trackomatron 2> /dev/null || : - systemctl stop trackomatron-service 2> /dev/null || : - ;; - - failed-upgrade) - ;; - - *) - echo "prerm called with unknown argument \`$1'" >&2 - exit 1 - ;; -esac - -# dh_installdeb will replace this with shell code automatically -# generated by other debhelper scripts. - -#DEBHELPER# - -exit 0 diff --git a/build/trackomatron/etc/systemd/system-preset/50-trackomatron.preset b/build/trackomatron/etc/systemd/system-preset/50-trackomatron.preset deleted file mode 100644 index 7ddca4019..000000000 --- a/build/trackomatron/etc/systemd/system-preset/50-trackomatron.preset +++ /dev/null @@ -1,3 +0,0 @@ -disable trackomatron.service -disable trackomatron-server.service - diff --git a/build/trackomatron/etc/systemd/system/trackomatron-server.service b/build/trackomatron/etc/systemd/system/trackomatron-server.service deleted file mode 100644 index cb7ef8768..000000000 --- a/build/trackomatron/etc/systemd/system/trackomatron-server.service +++ /dev/null @@ -1,24 +0,0 @@ -[Unit] -Description=Trackomatron server -Requires=network-online.target -BindTo=trackomatron.service -PartOf=trackomatron.service -Before=trackomatron.service -After=network-online.target -PropagatesReloadTo=trackomatron.service -ReloadPropagatedFrom=trackomatron.service - -[Service] -Environment="TMHOME=/etc/trackomatron" -Restart=on-failure -User=trackomatron -Group=trackomatron -PermissionsStartOnly=true -ExecStart=/usr/bin/tendermint node -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target -Also=trackomatron.service - diff --git a/build/trackomatron/etc/systemd/system/trackomatron.service b/build/trackomatron/etc/systemd/system/trackomatron.service deleted file mode 100644 index 2ebcae4a9..000000000 --- a/build/trackomatron/etc/systemd/system/trackomatron.service +++ /dev/null @@ -1,27 +0,0 @@ -[Unit] -Description=Trackomatron -#propagates activation, deactivation and activation fails. -Requires=network-online.target -#propagates activation, deactivation, activation fails and stops -BindTo=trackomatron-server.service -#propagates stop and restart (one-way) -PartOf=trackomatron-server.service -#order -After=network-online.target trackomatron-server.service -#propagates reload -PropagatesReloadTo=trackomatron-server.service -ReloadPropagatedFrom=trackomatron-server.service - -[Service] -Restart=on-failure -User=trackomatron -Group=trackomatron -PermissionsStartOnly=true -ExecStart=/usr/bin/tracko start --without-tendermint --home /etc/trackomatron -ExecReload=/bin/kill -HUP $MAINPID -KillSignal=SIGTERM - -[Install] -WantedBy=multi-user.target trackomatron-server.service -Also=trackomatron-server.service - diff --git a/build/trackomatron/usr/share/trackomatron/key.json b/build/trackomatron/usr/share/trackomatron/key.json deleted file mode 100644 index bdefe8fd4..000000000 --- a/build/trackomatron/usr/share/trackomatron/key.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "address": "1B1BE55F969F54064628A63B9559E7C21C925165", - "priv_key": { - "type": "ed25519", - "data": "C70D6934B4F55F1B7BC33B56B9CA8A2061384AFC19E91E44B40C4BBA182953D1619D3678599971ED29C7529DDD4DA537B97129893598A17C82E3AC9A8BA95279" - }, - "pub_key": { - "type": "ed25519", - "data": "619D3678599971ED29C7529DDD4DA537B97129893598A17C82E3AC9A8BA95279" - } -} - diff --git a/build/trackomatron/usr/share/trackomatron/key2.json b/build/trackomatron/usr/share/trackomatron/key2.json deleted file mode 100644 index ddfc6809b..000000000 --- a/build/trackomatron/usr/share/trackomatron/key2.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "address": "1DA7C74F9C219229FD54CC9F7386D5A3839F0090", - "priv_key": { - "type": "ed25519", - "data": "34BAE9E65CE8245FAD035A0E3EED9401BDE8785FFB3199ACCF8F5B5DDF7486A8352195DA90CB0B90C24295B90AEBA25A5A71BC61BAB2FE2387241D439698B7B8" - }, - "pub_key": { - "type": "ed25519", - "data": "352195DA90CB0B90C24295B90AEBA25A5A71BC61BAB2FE2387241D439698B7B8" - } -} - From e3d403e6b78fe7911f886955db8a28ba73b3901d Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 19 Feb 2018 20:05:43 -0500 Subject: [PATCH 47/60] Re-added tendermint binary installation for show_validator command (temporarily) --- ansible/roles/install/tasks/centos.yml | 2 ++ ansible/roles/install/tasks/debian.yml | 3 +++ 2 files changed, 5 insertions(+) diff --git a/ansible/roles/install/tasks/centos.yml b/ansible/roles/install/tasks/centos.yml index dc8b86b57..06db3ba21 100644 --- a/ansible/roles/install/tasks/centos.yml +++ b/ansible/roles/install/tasks/centos.yml @@ -46,6 +46,8 @@ - python-virtualenv - unzip - tar +#For show_validator command: + - tendermint - name: Install toml when: ansible_os_family == "RedHat" diff --git a/ansible/roles/install/tasks/debian.yml b/ansible/roles/install/tasks/debian.yml index d92a8c3ed..706f53fd0 100644 --- a/ansible/roles/install/tasks/debian.yml +++ b/ansible/roles/install/tasks/debian.yml @@ -29,3 +29,6 @@ - python-toml - unzip - tar +#For show_validator command: + - tendermint + From de4022dcce8eb0258a64f4c952e7843c84eb7811 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 19 Feb 2018 20:16:14 -0500 Subject: [PATCH 48/60] config.toml extensions --- ansible/roles/config/templates/config.toml.j2 | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 6ebc28ed4..4d955352c 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -211,3 +211,15 @@ peer_query_maj23_sleep_duration = 2000 # 2) "kv" - the simplest possible indexer, backed by key-value storage (defaults to levelDB; see DBBackend). indexer = "kv" +# Comma-separated list of tags to index (by default the only tag is tx hash) +# +# It's recommended to index only a subset of tags due to possible memory +# bloat. This is, of course, depends on the indexer's DB and the volume of +# transactions. +index_tags = "" + +# When set to true, tells indexer to index all tags. Note this may be not +# desirable (see the comment above). IndexTags has a precedence over +# IndexAllTags (i.e. when given both, IndexTags will be indexed). +index_all_tags = false + From 77cbccdd55c64a4a3ebe2900139b8cdd96d36056 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Mon, 19 Feb 2018 21:41:47 -0500 Subject: [PATCH 49/60] show_validator fix --- ansible/roles/config/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/config/tasks/main.yml b/ansible/roles/config/tasks/main.yml index 50ebe1001..4b62fe089 100644 --- a/ansible/roles/config/tasks/main.yml +++ b/ansible/roles/config/tasks/main.yml @@ -3,7 +3,7 @@ - name: gather tendermint public keys 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}}/config --log_level error" + command: "/usr/bin/tendermint show_validator --home /etc/{{service}} --log_level error" register: pubkeys changed_when: false From a7c9de49c0394b8f48968ecb84d1571de9066434 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 23 Feb 2018 08:44:39 -0500 Subject: [PATCH 50/60] unsafe reset fix --- ansible/roles/unsafe_reset/tasks/main.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/ansible/roles/unsafe_reset/tasks/main.yml b/ansible/roles/unsafe_reset/tasks/main.yml index e6f21da68..7cf8aebf8 100644 --- a/ansible/roles/unsafe_reset/tasks/main.yml +++ b/ansible/roles/unsafe_reset/tasks/main.yml @@ -2,12 +2,9 @@ when: "service == 'ethermint'" become_user: ethermint -- shell: "export BCHOME=/etc/basecoin ; basecoin unsafe_reset_all" - when: "service == 'basecoin'" - become_user: basecoin - -- shell: "export TMHOME=/etc/{{service}} ; tendermint unsafe_reset_all" +- command: "{{service}} node unsafe_reset_all --home=/etc/{{service}}" become_user: "{{service}}" -- file: "path=/etc/{{service}}/data state=absent" +- file: "path=/etc/{{service}}/config/addrbook.json state=absent" + From 0192e101ce344a56fbb43a58440ab7a53229ae73 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 27 Feb 2018 18:14:09 -0500 Subject: [PATCH 51/60] Quick, temporary fix for basecoin rename --- build/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/Makefile b/build/Makefile index 650771dc2..2433fede8 100644 --- a/build/Makefile +++ b/build/Makefile @@ -88,7 +88,7 @@ build-basecoin: git-branch gopath-setup go get -d -u github.com/cosmos/cosmos-sdk/examples/basecoin/cmd/basecoind cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps build - cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoin $(GOPATH)/bin + cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoind $(GOPATH)/bin/basecoin @echo "*** Built basecoin from cosmos-sdk" ### From 82106913f1fef9beb2891a848e197c2f77e9b07d Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 2 Mar 2018 20:36:37 -0500 Subject: [PATCH 52/60] basecoin - basecoind rename --- build/Makefile | 26 +++++++++---------- build/basecoin/DEBIAN/changelog | 6 ----- build/basecoin/DEBIAN/control | 14 ---------- .../systemd/system-preset/50-basecoin.preset | 2 -- build/basecoind/DEBIAN/changelog | 6 +++++ build/{basecoin => basecoind}/DEBIAN/compat | 0 build/basecoind/DEBIAN/control | 14 ++++++++++ .../{basecoin => basecoind}/DEBIAN/copyright | 4 +-- build/{basecoin => basecoind}/DEBIAN/postinst | 6 ++--- build/{basecoin => basecoind}/DEBIAN/postrm | 0 build/{basecoin => basecoind}/DEBIAN/preinst | 8 +++--- build/{basecoin => basecoind}/DEBIAN/prerm | 2 +- .../systemd/system-preset/50-basecoind.preset | 2 ++ .../etc/systemd/system/basecoind.service} | 4 +-- .../usr/share/basecoind}/key.json | 0 .../usr/share/basecoind}/key2.json | 0 build/spectemplates/basecoin.data | 5 ---- build/spectemplates/basecoind.data | 5 ++++ 18 files changed, 52 insertions(+), 52 deletions(-) delete mode 100644 build/basecoin/DEBIAN/changelog delete mode 100644 build/basecoin/DEBIAN/control delete mode 100644 build/basecoin/etc/systemd/system-preset/50-basecoin.preset create mode 100644 build/basecoind/DEBIAN/changelog rename build/{basecoin => basecoind}/DEBIAN/compat (100%) create mode 100644 build/basecoind/DEBIAN/control rename build/{basecoin => basecoind}/DEBIAN/copyright (91%) rename build/{basecoin => basecoind}/DEBIAN/postinst (83%) rename build/{basecoin => basecoind}/DEBIAN/postrm (100%) rename build/{basecoin => basecoind}/DEBIAN/preinst (79%) rename build/{basecoin => basecoind}/DEBIAN/prerm (94%) create mode 100644 build/basecoind/etc/systemd/system-preset/50-basecoind.preset rename build/{basecoin/etc/systemd/system/basecoin.service => basecoind/etc/systemd/system/basecoind.service} (82%) rename build/{basecoin/usr/share/basecoin => basecoind/usr/share/basecoind}/key.json (100%) rename build/{basecoin/usr/share/basecoin => basecoind/usr/share/basecoind}/key2.json (100%) delete mode 100644 build/spectemplates/basecoin.data create mode 100644 build/spectemplates/basecoind.data diff --git a/build/Makefile b/build/Makefile index 2433fede8..a47644b63 100644 --- a/build/Makefile +++ b/build/Makefile @@ -35,12 +35,12 @@ endif # Here comes the real deal ### -binaries = tendermint basecoin ethermint gaia -build-binaries = build-tendermint build-basecoin build-ethermint build-gaia -package-rpm = package-rpm-tendermint package-rpm-basecoin package-rpm-ethermint package-rpm-gaia -install-rpm = install-rpm-tendermint install-rpm-basecoin install-rpm-ethermint install-rpm-gaia -package-deb = package-deb-tendermint package-deb-basecoin package-deb-ethermint package-deb-gaia -install-deb = install-deb-tendermint install-deb-basecoin install-deb-ethermint install-deb-gaia +binaries = tendermint basecoind ethermint gaia +build-binaries = build-tendermint build-basecoind build-ethermint build-gaia +package-rpm = package-rpm-tendermint package-rpm-basecoind package-rpm-ethermint package-rpm-gaia +install-rpm = install-rpm-tendermint install-rpm-basecoind install-rpm-ethermint install-rpm-gaia +package-deb = package-deb-tendermint package-deb-basecoind package-deb-ethermint package-deb-gaia +install-deb = install-deb-tendermint install-deb-basecoind install-deb-ethermint install-deb-gaia all: $(binaries) build: $(build-binaries) @@ -83,13 +83,13 @@ build-gaia: git-branch gopath-setup export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/gaia get_vendor_deps install @echo "*** Built gaia" -build-basecoin: git-branch gopath-setup - @echo "*** Building basecoin from cosmos-sdk" +build-basecoind: git-branch gopath-setup + @echo "*** Building basecoind from cosmos-sdk" go get -d -u github.com/cosmos/cosmos-sdk/examples/basecoin/cmd/basecoind cd $(GOPATH)/src/github.com/cosmos/cosmos-sdk && git checkout "$(GIT_BRANCH)" && git pull export PATH=$(GOPATH)/bin:$(PATH) && $(MAKE) -C $(GOPATH)/src/github.com/cosmos/cosmos-sdk get_tools get_vendor_deps build - cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoind $(GOPATH)/bin/basecoin - @echo "*** Built basecoin from cosmos-sdk" + cp $(GOPATH)/src/github.com/cosmos/cosmos-sdk/build/basecoind $(GOPATH)/bin/basecoind + @echo "*** Built basecoind from cosmos-sdk" ### # Prepare package files @@ -119,7 +119,7 @@ prepare-ethermint = mkdir -p $(build_folder)/etc/ethermint && \ cp $(GOPATH)/src/github.com/tendermint/ethermint/setup/genesis.json $(build_folder)/etc/ethermint/genesis.json && \ cp -r $(GOPATH)/src/github.com/tendermint/ethermint/setup/keystore $(build_folder)/etc/ethermint prepare-gaia = -prepare-basecoin = cp $(GOPATH)/bin/basecoin $(build_folder)/usr/bin +prepare-basecoind = cp $(GOPATH)/bin/basecoind $(build_folder)/usr/bin ### # Package the binary for CentOS/RedHat (RPM) and Debian/Ubuntu (DEB) @@ -199,7 +199,7 @@ install-rpm-%: version-% cp ./RPM-GPG-KEY-Tendermint tmp/s3/7/os/x86_64/ cp ./tendermint.repo tmp/s3/7/os/x86_64/ rm -f tmp/s3/7/os/x86_64/repodata/*.bz2 tmp/s3/7/os/x86_64/repodata/*.gz tmp/s3/7/os/x86_64/repodata/repomd.xml.asc - createrepo tmp/s3/7/os/x86_64/Packages -u https://tendermint-packages.interblock.io/$(DEVOPS_PATH)centos/7/os/x86_64/Packages -o tmp/s3/7/os/x86_64 --update -S --repo Tendermint --content tendermint --content basecoin --content ethermint + createrepo tmp/s3/7/os/x86_64/Packages -u https://tendermint-packages.interblock.io/$(DEVOPS_PATH)centos/7/os/x86_64/Packages -o tmp/s3/7/os/x86_64 --update -S --repo Tendermint --content tendermint --content basecoind --content ethermint gpg --batch --passphrase "$(GPG_PASSPHRASE)" --detach-sign -a tmp/s3/7/os/x86_64/repodata/repomd.xml aws s3 sync tmp/s3/ s3://tendermint-packages/$(DEVOPS_PATH)centos/ --delete --acl public-read @echo "*** Uploaded $* to AWS $(DEVOPS_PATH)CentOS repository" @@ -281,7 +281,7 @@ distclean: clean rm -rf $(GOPATH)/src/github.com/cosmos/cosmos-sdk rm -rf $(GOPATH)/src/github.com/tendermint/ethermint rm -rf $(GOPATH)/bin/tendermint - rm -rf $(GOPATH)/bin/basecoin + rm -rf $(GOPATH)/bin/basecoind rm -rf $(GOPATH)/bin/ethermint rm -rf $(GOPATH)/bin/gaia diff --git a/build/basecoin/DEBIAN/changelog b/build/basecoin/DEBIAN/changelog deleted file mode 100644 index e316bcd35..000000000 --- a/build/basecoin/DEBIAN/changelog +++ /dev/null @@ -1,6 +0,0 @@ -basecoin (@VERSION@) @STABILITY@; urgency=medium - - * Automatic build. See https://github.com/tendermint/basecoin for more information. - - -- Greg Szabo @DATETIMESTAMP@ - diff --git a/build/basecoin/DEBIAN/control b/build/basecoin/DEBIAN/control deleted file mode 100644 index e74091263..000000000 --- a/build/basecoin/DEBIAN/control +++ /dev/null @@ -1,14 +0,0 @@ -Source: basecoin -Section: net -Priority: optional -Maintainer: Greg Szabo -Build-Depends: debhelper (>=9) -Standards-Version: 3.9.6 -Homepage: https://tendermint.com -Package: basecoin -Architecture: amd64 -Version: @VERSION@ -Installed-Size: @INSTALLEDSIZE@ -Description: basecoin is a Proof-of-Stake cryptocurrency and framework - Basecoin is an ABCI application designed to be used with the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. It also provides a general purpose framework for extending the feature-set of the cryptocurrency by implementing plugins. - diff --git a/build/basecoin/etc/systemd/system-preset/50-basecoin.preset b/build/basecoin/etc/systemd/system-preset/50-basecoin.preset deleted file mode 100644 index b35369c2d..000000000 --- a/build/basecoin/etc/systemd/system-preset/50-basecoin.preset +++ /dev/null @@ -1,2 +0,0 @@ -disable basecoin.service - diff --git a/build/basecoind/DEBIAN/changelog b/build/basecoind/DEBIAN/changelog new file mode 100644 index 000000000..260718eaf --- /dev/null +++ b/build/basecoind/DEBIAN/changelog @@ -0,0 +1,6 @@ +basecoind (@VERSION@) @STABILITY@; urgency=medium + + * Automatic build. See https://github.com/cosmos/cosmos-sdk for more information. + + -- Greg Szabo @DATETIMESTAMP@ + diff --git a/build/basecoin/DEBIAN/compat b/build/basecoind/DEBIAN/compat similarity index 100% rename from build/basecoin/DEBIAN/compat rename to build/basecoind/DEBIAN/compat diff --git a/build/basecoind/DEBIAN/control b/build/basecoind/DEBIAN/control new file mode 100644 index 000000000..c15d49110 --- /dev/null +++ b/build/basecoind/DEBIAN/control @@ -0,0 +1,14 @@ +Source: basecoind +Section: net +Priority: optional +Maintainer: Greg Szabo +Build-Depends: debhelper (>=9) +Standards-Version: 3.9.6 +Homepage: https://tendermint.com +Package: basecoind +Architecture: amd64 +Version: @VERSION@ +Installed-Size: @INSTALLEDSIZE@ +Description: basecoind is a Proof-of-Stake cryptocurrency and framework + Basecoind is an ABCI application designed to be used with the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. It also provides a general purpose framework for extending the feature-set of the cryptocurrency by implementing plugins. + diff --git a/build/basecoin/DEBIAN/copyright b/build/basecoind/DEBIAN/copyright similarity index 91% rename from build/basecoin/DEBIAN/copyright rename to build/basecoind/DEBIAN/copyright index 22340c79a..fe449650c 100644 --- a/build/basecoin/DEBIAN/copyright +++ b/build/basecoind/DEBIAN/copyright @@ -1,6 +1,6 @@ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: basecoin -Source: https://github.com/tendermint/basecoin +Upstream-Name: basecoind +Source: https://github.com/cosmos/cosmos-sdk Files: * Copyright: 2017 All In Bits, Inc. diff --git a/build/basecoin/DEBIAN/postinst b/build/basecoind/DEBIAN/postinst similarity index 83% rename from build/basecoin/DEBIAN/postinst rename to build/basecoind/DEBIAN/postinst index 9bdc58678..d7d8f4413 100644 --- a/build/basecoin/DEBIAN/postinst +++ b/build/basecoind/DEBIAN/postinst @@ -1,5 +1,5 @@ #!/bin/sh -# postinst script for basecoin +# postinst script for basecoind # set -e @@ -19,8 +19,8 @@ set -e case "$1" in configure) - chown basecoin.basecoin /etc/basecoin - sudo -Hu basecoin basecoin node init --home /etc/basecoin 2B24DEE2364762300168DF19B6C18BCE2D399EA2 + chown basecoind.basecoind /etc/basecoind + sudo -Hu basecoind basecoind node init --home /etc/basecoind 2B24DEE2364762300168DF19B6C18BCE2D399EA2 systemctl daemon-reload ;; diff --git a/build/basecoin/DEBIAN/postrm b/build/basecoind/DEBIAN/postrm similarity index 100% rename from build/basecoin/DEBIAN/postrm rename to build/basecoind/DEBIAN/postrm diff --git a/build/basecoin/DEBIAN/preinst b/build/basecoind/DEBIAN/preinst similarity index 79% rename from build/basecoin/DEBIAN/preinst rename to build/basecoind/DEBIAN/preinst index 8fc1ec82a..53124c0ce 100644 --- a/build/basecoin/DEBIAN/preinst +++ b/build/basecoind/DEBIAN/preinst @@ -1,5 +1,5 @@ #!/bin/sh -# preinst script for basecoin +# preinst script for basecoind # set -e @@ -15,9 +15,9 @@ set -e case "$1" in install|upgrade) - if ! grep -q '^basecoin:' /etc/passwd ; then - useradd -k /dev/null -r -m -b /etc basecoin - chmod 755 /etc/basecoin + if ! grep -q '^basecoind:' /etc/passwd ; then + useradd -k /dev/null -r -m -b /etc basecoind + chmod 755 /etc/basecoind fi ;; diff --git a/build/basecoin/DEBIAN/prerm b/build/basecoind/DEBIAN/prerm similarity index 94% rename from build/basecoin/DEBIAN/prerm rename to build/basecoind/DEBIAN/prerm index 389f40267..18ef42079 100644 --- a/build/basecoin/DEBIAN/prerm +++ b/build/basecoind/DEBIAN/prerm @@ -18,7 +18,7 @@ set -e case "$1" in remove|upgrade|deconfigure) - systemctl stop basecoin 2> /dev/null || : + systemctl stop basecoind 2> /dev/null || : ;; failed-upgrade) diff --git a/build/basecoind/etc/systemd/system-preset/50-basecoind.preset b/build/basecoind/etc/systemd/system-preset/50-basecoind.preset new file mode 100644 index 000000000..358334fc3 --- /dev/null +++ b/build/basecoind/etc/systemd/system-preset/50-basecoind.preset @@ -0,0 +1,2 @@ +disable basecoind.service + diff --git a/build/basecoin/etc/systemd/system/basecoin.service b/build/basecoind/etc/systemd/system/basecoind.service similarity index 82% rename from build/basecoin/etc/systemd/system/basecoin.service rename to build/basecoind/etc/systemd/system/basecoind.service index 27878ff71..438acfa69 100644 --- a/build/basecoin/etc/systemd/system/basecoin.service +++ b/build/basecoind/etc/systemd/system/basecoind.service @@ -1,10 +1,10 @@ [Unit] -Description=Basecoin +Description=Basecoind Requires=network-online.target After=network-online.target [Service] -Environment="BCHOME=/etc/basecoin" +Environment="BCHOME=/etc/basecoind" Restart=on-failure User=basecoin Group=basecoin diff --git a/build/basecoin/usr/share/basecoin/key.json b/build/basecoind/usr/share/basecoind/key.json similarity index 100% rename from build/basecoin/usr/share/basecoin/key.json rename to build/basecoind/usr/share/basecoind/key.json diff --git a/build/basecoin/usr/share/basecoin/key2.json b/build/basecoind/usr/share/basecoind/key2.json similarity index 100% rename from build/basecoin/usr/share/basecoin/key2.json rename to build/basecoind/usr/share/basecoind/key2.json diff --git a/build/spectemplates/basecoin.data b/build/spectemplates/basecoin.data deleted file mode 100644 index b5e0f3728..000000000 --- a/build/spectemplates/basecoin.data +++ /dev/null @@ -1,5 +0,0 @@ -PACKAGE_SUMMARY="basecoin is a Proof-of-Stake cryptocurrency and framework" -PACKAGE_URL="https://cosmos.network/" -PACKAGE_ADDITIONAL_HEADER="Provides: basecoin" -PACKAGE_DESCRIPTION="Basecoin is an ABCI application designed to be used with the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. It also provides a general purpose framework for extending the feature-set of the cryptocurrency by implementing plugins." - diff --git a/build/spectemplates/basecoind.data b/build/spectemplates/basecoind.data new file mode 100644 index 000000000..36b172ecf --- /dev/null +++ b/build/spectemplates/basecoind.data @@ -0,0 +1,5 @@ +PACKAGE_SUMMARY="basecoind is a Proof-of-Stake cryptocurrency and framework" +PACKAGE_URL="https://cosmos.network/" +PACKAGE_ADDITIONAL_HEADER="Provides: basecoind" +PACKAGE_DESCRIPTION="Basecoind is an ABCI application designed to be used with the Tendermint consensus engine to form a Proof-of-Stake cryptocurrency. It also provides a general purpose framework for extending the feature-set of the cryptocurrency by implementing plugins." + From 71e133553ed307eccfdc1cca5630f51fabe19360 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 2 Mar 2018 21:22:28 -0500 Subject: [PATCH 53/60] basecoind genesis fix --- ansible/roles/config/templates/genesis.json.j2 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ansible/roles/config/templates/genesis.json.j2 b/ansible/roles/config/templates/genesis.json.j2 index 4bf3b44c5..6ca0f876d 100644 --- a/ansible/roles/config/templates/genesis.json.j2 +++ b/ansible/roles/config/templates/genesis.json.j2 @@ -19,7 +19,11 @@ {% endif %} ], "app_hash":"", +{% if service == 'basecoind' %} + "app_state": { +{% else %} "app_options": { +{% endif %} {% if app_options_file is defined %} {% include app_options_file %} {% endif %} From e893f9bc1fd910546e833311a8c39fbf375f98aa Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 2 Mar 2018 21:38:54 -0500 Subject: [PATCH 54/60] basecoind service fix --- build/basecoind/etc/systemd/system/basecoind.service | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/basecoind/etc/systemd/system/basecoind.service b/build/basecoind/etc/systemd/system/basecoind.service index 438acfa69..68b46d84f 100644 --- a/build/basecoind/etc/systemd/system/basecoind.service +++ b/build/basecoind/etc/systemd/system/basecoind.service @@ -6,8 +6,8 @@ After=network-online.target [Service] Environment="BCHOME=/etc/basecoind" Restart=on-failure -User=basecoin -Group=basecoin +User=basecoind +Group=basecoind PermissionsStartOnly=true ExecStart=/usr/bin/basecoind start ExecReload=/bin/kill -HUP $MAINPID From 7d414cb7b2b3ce5057a128bceef8830de078f805 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 2 Mar 2018 22:50:30 -0500 Subject: [PATCH 55/60] node ID fix --- ansible/README.rst | 22 +++++++++++----------- ansible/group_vars/all | 4 ++-- ansible/roles/config/tasks/main.yml | 13 +++++++++++++ 3 files changed, 26 insertions(+), 13 deletions(-) diff --git a/ansible/README.rst b/ansible/README.rst index 24ca6f878..5c416c018 100644 --- a/ansible/README.rst +++ b/ansible/README.rst @@ -9,8 +9,8 @@ Using Ansible The playbooks in `our ansible directory `__ run ansible `roles `__ which: -- install and configure basecoin or ethermint -- start/stop basecoin or ethermint and reset their configuration +- install and configure basecoind or ethermint +- start/stop basecoind or ethermint and reset their configuration Prerequisites ------------- @@ -200,7 +200,7 @@ DigitalOcean DO_API_TOKEN="" TF_VAR_TESTNET_NAME="testnet-servers" - ansible-playbook -i inventory/digital_ocean.py install.yml -e service=basecoin + ansible-playbook -i inventory/digital_ocean.py install.yml -e service=basecoind Amazon AWS ~~~~~~~~~~ @@ -210,12 +210,12 @@ Amazon AWS AWS_ACCESS_KEY_ID='' AWS_SECRET_ACCESS_KEY='' TF_VAR_TESTNET_NAME="testnet-servers" - ansible-playbook -i inventory/ec2.py install.yml -e service=basecoin + ansible-playbook -i inventory/ec2.py install.yml -e service=basecoind Installing custom versions ~~~~~~~~~~~~~~~~~~~~~~~~~~ -By default ansible installs the tendermint, basecoin or ethermint binary +By default ansible installs the tendermint, basecoind or ethermint binary versions from the latest release in the repository. If you build your own version of the binaries, you can tell ansible to install that instead. @@ -223,11 +223,11 @@ instead. :: GOPATH="" - go get -u github.com/tendermint/basecoin/cmd/basecoin + go get -u github.com/tendermint/basecoin/cmd/basecoind DO_API_TOKEN="" TF_VAR_TESTNET_NAME="testnet-servers" - ansible-playbook -i inventory/digital_ocean.py install.yml -e service=basecoin -e release_install=false + ansible-playbook -i inventory/digital_ocean.py install.yml -e service=basecoind -e release_install=false Alternatively you can change the variable settings in ``group_vars/all``. @@ -237,15 +237,15 @@ Other commands and roles There are few extra playbooks to make life easier managing your servers. -- install.yml - Install basecoin or ethermint applications. (Tendermint +- install.yml - Install basecoind or ethermint applications. (Tendermint gets installed automatically.) Use the ``service`` parameter to - define which application to install. Defaults to ``basecoin``. + define which application to install. Defaults to ``basecoind``. - reset.yml - Stop the application, reset the configuration and data, then start the application again. You need to pass - ``-e service=``, like ``-e service=basecoin``. It will + ``-e service=``, like ``-e service=basecoind``. It will restart the underlying tendermint application too. - restart.yml - Restart a service on all nodes. You need to pass - ``-e service=``, like ``-e service=basecoin``. It will + ``-e service=``, like ``-e service=basecoind``. It will restart the underlying tendermint application too. - stop.yml - Stop the application. You need to pass ``-e service=``. diff --git a/ansible/group_vars/all b/ansible/group_vars/all index ea8ff4857..bd14134cc 100644 --- a/ansible/group_vars/all +++ b/ansible/group_vars/all @@ -9,8 +9,8 @@ ## install ## -## service variable defines which service is going to be managed. It can be set to basecoin or ethermint. -service: basecoin +## service variable defines which service is going to be managed. It can be set to basecoind or ethermint. +service: basecoind ## release_install indicates if the install role should look for a privately built binary after installing the service package. If set to false, the privately built binary in the GOPATH is going to override the binary on the target systems. #release_install: true diff --git a/ansible/roles/config/tasks/main.yml b/ansible/roles/config/tasks/main.yml index 4b62fe089..85c37e3b3 100644 --- a/ansible/roles/config/tasks/main.yml +++ b/ansible/roles/config/tasks/main.yml @@ -7,6 +7,13 @@ register: pubkeys changed_when: false +- name: gather tendermint peer IDs + when: genesis_file is not defined + tags: reconfig-toml + command: "/usr/bin/tendermint show_node_id --home /etc/{{service}} --log_level error" + register: nodeids + changed_when: false + - name: resetting permissions from root after gathering public keys tags: reconfig-toml,reconfig-genesis file: "path=/etc/{{service}} owner={{service}} group={{service}} recurse=yes" @@ -17,6 +24,12 @@ set_fact: "pubkey='{{pubkeys.stdout}}'" connection: local +- name: register node ids as host facts + when: genesis_file is not defined + tags: reconfig-toml + set_fact: "nodeid='{{nodeids.stdout}}'" + connection: local + - name: copy generated genesis.json - genesis_time will be updated when: (validators == true or validators == 'true') and (genesis_file is not defined) tags: reconfig-genesis From 2429cfb2b782b3b37337f3a059a48c1acb429d2a Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 2 Mar 2018 23:14:42 -0500 Subject: [PATCH 56/60] p2p ids in config.toml --- ansible/roles/config/templates/config.toml.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 4d955352c..9639697e7 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -84,7 +84,7 @@ laddr = "tcp://0.0.0.0:46656" # Comma separated list of seed nodes to connect to {% if validators == true or validators == 'true' %} -{% set comma = joiner(",") %}seeds = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" +{% set comma = joiner(",") %}seeds = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["nodeid"]}}@{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" {% else %} seeds = "{{ seeds | default() }}" {% endif %} From 426938e2b498e24884c252140fb607b607d97418 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sat, 3 Mar 2018 05:06:03 -0500 Subject: [PATCH 57/60] persistent_peers changes --- ansible/roles/config/defaults/main.yml | 1 + ansible/roles/config/templates/config.toml.j2 | 8 +++----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/ansible/roles/config/defaults/main.yml b/ansible/roles/config/defaults/main.yml index 4b9281a5e..79b01ab13 100644 --- a/ansible/roles/config/defaults/main.yml +++ b/ansible/roles/config/defaults/main.yml @@ -2,6 +2,7 @@ #genesis_file: "" app_options_file: "app_options_files/public_testnet" seeds: "" +persistent_peers: "" testnet_name: testnet1 validators: true diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 9639697e7..1965975a9 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -83,14 +83,12 @@ unsafe = false laddr = "tcp://0.0.0.0:46656" # Comma separated list of seed nodes to connect to -{% if validators == true or validators == 'true' %} -{% set comma = joiner(",") %}seeds = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["nodeid"]}}@{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" -{% else %} seeds = "{{ seeds | default() }}" -{% endif %} # Comma separated list of nodes to keep persistent connections to -persistent_peers = "" +{% set comma = joiner(",") %}persistent_peers = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["nodeid"]}}@{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" +{% else %} +persistent_peers = "{{ persistent_peers | default() }}" # Path to address book addr_book_file = "config/addrbook.json" From 5cb7e151fb57b60f70d555fb1135ef259ec4e866 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sat, 3 Mar 2018 05:06:53 -0500 Subject: [PATCH 58/60] persistent_peers fix --- ansible/roles/config/defaults/main.yml | 1 - ansible/roles/config/templates/config.toml.j2 | 2 -- 2 files changed, 3 deletions(-) diff --git a/ansible/roles/config/defaults/main.yml b/ansible/roles/config/defaults/main.yml index 79b01ab13..4b9281a5e 100644 --- a/ansible/roles/config/defaults/main.yml +++ b/ansible/roles/config/defaults/main.yml @@ -2,7 +2,6 @@ #genesis_file: "" app_options_file: "app_options_files/public_testnet" seeds: "" -persistent_peers: "" testnet_name: testnet1 validators: true diff --git a/ansible/roles/config/templates/config.toml.j2 b/ansible/roles/config/templates/config.toml.j2 index 1965975a9..020baf61e 100644 --- a/ansible/roles/config/templates/config.toml.j2 +++ b/ansible/roles/config/templates/config.toml.j2 @@ -87,8 +87,6 @@ seeds = "{{ seeds | default() }}" # Comma separated list of nodes to keep persistent connections to {% set comma = joiner(",") %}persistent_peers = "{% for host in ((groups[testnet_name]|default([]))+(groups['tag_Environment_'~(testnet_name|regex_replace('-','_'))]|default([])))|difference(inventory_hostname) %}{{ comma() }}{{hostvars[host]["nodeid"]}}@{{hostvars[host]["inventory_hostname"]}}:46656{% endfor %}" -{% else %} -persistent_peers = "{{ persistent_peers | default() }}" # Path to address book addr_book_file = "config/addrbook.json" From 043ba85a9e0343d4c2e4597819100c2dc433860b Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Fri, 30 Mar 2018 23:22:08 -0400 Subject: [PATCH 59/60] Added automated dockerfile --- docker/tendermint-automated/Dockerfile | 23 +++++++++++++++++++++++ docker/tendermint-automated/README.rst | 1 + 2 files changed, 24 insertions(+) create mode 100644 docker/tendermint-automated/Dockerfile create mode 100644 docker/tendermint-automated/README.rst diff --git a/docker/tendermint-automated/Dockerfile b/docker/tendermint-automated/Dockerfile new file mode 100644 index 000000000..e10518f96 --- /dev/null +++ b/docker/tendermint-automated/Dockerfile @@ -0,0 +1,23 @@ +FROM alpine:3.7 +MAINTAINER Greg Szabo + +#Default home for tendermint +ENV TMHOME /tendermint +RUN apk --no-cache update && \ + apk --no-cache upgrade && \ + apk add --no-cache bash curl jq openssl && \ + mkdir -p $TMHOME && \ + addgroup tmuser && \ + adduser -S -G tmuser tmuser && \ + chown -R tmuser:tmuser $TMHOME + +VOLUME [ $TMHOME ] +EXPOSE 46656 46657 +ENTRYPOINT ["/usr/bin/tendermint"] +CMD ["node", "--moniker=`hostname`"] +WORKDIR $TMHOME +STOPSIGNAL SIGTERM + +ARG BINARY=tendermint +COPY $BINARY /usr/bin/tendermint + diff --git a/docker/tendermint-automated/README.rst b/docker/tendermint-automated/README.rst new file mode 100644 index 000000000..f5582ce80 --- /dev/null +++ b/docker/tendermint-automated/README.rst @@ -0,0 +1 @@ +This is a temporary folder to contain the Dockerfile used for automated builds, until it is merged with the tendermint repository. From d73a7397b5b0359c0760349fe13c8aac55e617f6 Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Sat, 31 Mar 2018 00:34:32 -0400 Subject: [PATCH 60/60] Dockerfile update and fixes --- docker/tendermint-automated/Dockerfile | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/docker/tendermint-automated/Dockerfile b/docker/tendermint-automated/Dockerfile index e10518f96..73497c5a0 100644 --- a/docker/tendermint-automated/Dockerfile +++ b/docker/tendermint-automated/Dockerfile @@ -1,21 +1,19 @@ -FROM alpine:3.7 +FROM ubuntu:16.04 MAINTAINER Greg Szabo -#Default home for tendermint +#Default home for tendermint. The node command will look for $TMHOME/config/genesis.json at initialization. ENV TMHOME /tendermint -RUN apk --no-cache update && \ - apk --no-cache upgrade && \ - apk add --no-cache bash curl jq openssl && \ - mkdir -p $TMHOME && \ - addgroup tmuser && \ - adduser -S -G tmuser tmuser && \ - chown -R tmuser:tmuser $TMHOME +RUN apt-get -y update && \ + apt-get -y upgrade && \ + apt-get -y install curl jq && \ + adduser --system --home "$TMHOME" --group tmuser +USER tmuser VOLUME [ $TMHOME ] +WORKDIR $TMHOME EXPOSE 46656 46657 ENTRYPOINT ["/usr/bin/tendermint"] CMD ["node", "--moniker=`hostname`"] -WORKDIR $TMHOME STOPSIGNAL SIGTERM ARG BINARY=tendermint