From bed33467b143693f9379f1edd607c6c6282c864c Mon Sep 17 00:00:00 2001 From: Greg Szabo Date: Tue, 12 Sep 2017 18:01:29 -0400 Subject: [PATCH] cosmos-sdk RPM package fixes --- build/cosmos-sdk/DEBIAN/changelog | 2 +- build/cosmos-sdk/DEBIAN/postinst | 10 +++++----- build/cosmos-sdk/DEBIAN/preinst | 6 +++--- .../etc/systemd/system/cosmos-sdk-server.service | 6 +++--- build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service | 6 +++--- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/build/cosmos-sdk/DEBIAN/changelog b/build/cosmos-sdk/DEBIAN/changelog index 0b56180ec..13eb09125 100644 --- a/build/cosmos-sdk/DEBIAN/changelog +++ b/build/cosmos-sdk/DEBIAN/changelog @@ -1,6 +1,6 @@ cosmos-sdk (@VERSION@) @STABILITY@; urgency=medium - * Automatic build. See https://github.com/tendermint/basecoin for more information. + * Automatic build. See https://github.com/cosmos/cosmos-sdk for more information. -- Greg Szabo @DATETIMESTAMP@ diff --git a/build/cosmos-sdk/DEBIAN/postinst b/build/cosmos-sdk/DEBIAN/postinst index 39471823f..7f179b0eb 100644 --- a/build/cosmos-sdk/DEBIAN/postinst +++ b/build/cosmos-sdk/DEBIAN/postinst @@ -19,13 +19,13 @@ set -e case "$1" in configure) - chown basecoin.basecoin /etc/basecoin - sudo -Hu basecoin basecoin init --home /etc/basecoin 2B24DEE2364762300168DF19B6C18BCE2D399EA2 + 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 basecoin tendermint init --home /etc/basecoin/tendermint + 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/basecoin/tendermint - chown basecoin.basecoin /etc/basecoin/tendermint + chmod 755 /etc/cosmos-sdk/tendermint + chown cosmos-sdk.cosmos-sdk /etc/cosmos-sdk/tendermint systemctl daemon-reload ;; diff --git a/build/cosmos-sdk/DEBIAN/preinst b/build/cosmos-sdk/DEBIAN/preinst index 308cfb1e7..f7108e5d6 100644 --- a/build/cosmos-sdk/DEBIAN/preinst +++ b/build/cosmos-sdk/DEBIAN/preinst @@ -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 '^cosmos-sdk:' /etc/passwd ; then + useradd -k /dev/null -r -m -b /etc cosmos-sdk + chmod 755 /etc/cosmos-sdk fi ;; diff --git a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service index 85fd602cf..bbda97350 100644 --- a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service +++ b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk-server.service @@ -8,10 +8,10 @@ PropagatesReloadTo=cosmos-sdk.service ReloadPropagatedFrom=cosmos-sdk.service [Service] -Environment="TMHOME=/etc/basecoin/tendermint" +Environment="TMHOME=/etc/cosmos-sdk/tendermint" Restart=on-failure -User=basecoin -Group=basecoin +User=cosmos-sdk +Group=cosmos-sdk PermissionsStartOnly=true ExecStart=/usr/bin/tendermint node ExecReload=/bin/kill -HUP $MAINPID diff --git a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service index 868531af7..2091e5592 100644 --- a/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service +++ b/build/cosmos-sdk/etc/systemd/system/cosmos-sdk.service @@ -14,10 +14,10 @@ PropagatesReloadTo=cosmos-sdk-server.service ReloadPropagatedFrom=cosmos-sdk-server.service [Service] -Environment="BCHOME=/etc/basecoin" +Environment="BCHOME=/etc/cosmos-sdk" Restart=on-failure -User=basecoin -Group=basecoin +User=cosmos-sdk +Group=cosmos-sdk PermissionsStartOnly=true ExecStart=/usr/bin/basecoin start --without-tendermint ExecReload=/bin/kill -HUP $MAINPID