Skip to content
Snippets Groups Projects
Unverified Commit bd49181f authored by Dmitriy A. Gerasimov's avatar Dmitriy A. Gerasimov Committed by GitHub
Browse files

Merge pull request #51 from osetrovich/f2323-debian-deploy

F2323-debian-deploy
parents c86030f0 8868c4e4
No related branches found
No related tags found
1 merge request!1Master
...@@ -14,16 +14,17 @@ script: ...@@ -14,16 +14,17 @@ script:
- cd build - cd build
- cmake -DBUILD_KELVIN_NODE_TESTS=ON ../ - cmake -DBUILD_KELVIN_NODE_TESTS=ON ../
- make - make
- ctest --verbose - ctest
- cpack - cpack
- dpkg -i *.deb - sudo dpkg -i *.deb
- /opt/kelvin-node/bin/kelvin-node-tool cert create cert0 sig_tesla - ls -laR /opt/kelvin-node
- service kelvin-node start - sudo /opt/kelvin-node/bin/kelvin-node-tool cert create cert0 sig_tesla
- systemctl is-runnig kelvin-node - sudo service kelvin-node start
- /opt/kelvin-node/bin/kelvin-node-cli wallet new -w wallet0 - sudo systemctl status kelvin-node
- /opt/kelvin-node/bin/kelvin-node-cli token_decl -net private -chain gdb token TOK1 total_supply 1000000000000000000000000 signs_total 1 signs_emission 1 certs cert0 - sudo /opt/kelvin-node/bin/kelvin-node-cli wallet new -w wallet0
- /opt/kelvin-node/bin/kelvin-node-cli token_emit -net private -chain_emission gdb -chain_base_tx gdb -addr `/opt/kelvin-node/bin/kelvin-node-cli wallet list| grep addr | awk '{print $3}' |tr -d "\n"` -token TOK1 -certs cert0 -emission_value 123000000000000 - sudo /opt/kelvin-node/bin/kelvin-node-cli token_decl -net private -chain gdb token TOK1 total_supply 1000000000000000000000000 signs_total 1 signs_emission 1 certs cert0
- /opt/kelvin-node/bin/kelvin-node-cli mempool_proc -net private -chain gdb - sudo /opt/kelvin-node/bin/kelvin-node-cli token_emit -net private -chain_emission gdb -chain_base_tx gdb -addr $(sudo /opt/kelvin-node/bin/kelvin-node-cli wallet list| grep addr | awk '{print $2}' |tr -d "\n") -token TOK1 -certs cert0 -emission_value 123000000000000
- sudo /opt/kelvin-node/bin/kelvin-node-cli mempool_proc -net private -chain gdb
addons: addons:
apt: apt:
sources: sources:
...@@ -35,9 +36,6 @@ addons: ...@@ -35,9 +36,6 @@ addons:
- libldb-dev - libldb-dev
- libtevent-dev - libtevent-dev
- libcurl4-gnutls-dev - libcurl4-gnutls-dev
- debconf-utils
- dconf-cli
- pv
...@@ -39,12 +39,22 @@ else ...@@ -39,12 +39,22 @@ else
systemctl --system enable $DAP_PREFIX/share/$DAP_APP_NAME.service systemctl --system enable $DAP_PREFIX/share/$DAP_APP_NAME.service
# systemctl --system start $DAP_APP_NAME # systemctl --system start $DAP_APP_NAME
fi fi
USERMAN=`users | awk '{print $1}'` #USERMAN=`users | awk '{print $1}'`
#groupadd $DAP_CHAINS_NAME groupadd $DAP_CHAINS_NAME
#usermod -aG $DAP_CHAINS_NAME `users | awk '{print $1}'` #usermod -aG $DAP_CHAINS_NAME `users | awk '{print $1}'`
for username in $(cat /etc/passwd | grep "/home" | cut -d ':' -f1); do
usermod -aG $DAP_CHAINS_NAME $username
done
mkdir -p $DAP_PREFIX/var/{run,lib/ca,lib/wallet,lib/global_db} mkdir -p $DAP_PREFIX/var/{run,lib/ca,lib/wallet,lib/global_db}
touch $DAP_PREFIX/var/run/kelvin-node.pid touch $DAP_PREFIX/var/run/kelvin-node.pid
chown -R $USERMAN:$USERMAN $DAP_PREFIX #chown -R $USERMAN:$USERMAN $DAP_PREFIX
chmod 0775 $DAP_PREFIX/var/{run,lib/ca,lib/wallet,lib/global_db} for filename in $(find $DAP_PREFIX); do
if [ -d $filename ]; then
chmod 0775 $filename
else
chmod 0664 $filename
fi
done
chmod 0774 $DAP_PREFIX/bin/*
echo "For start $DAP_APP_NAME - run 'systemctl start $DAP_APP_NAME'" echo "For start $DAP_APP_NAME - run 'systemctl start $DAP_APP_NAME'"
...@@ -3,5 +3,13 @@ if [ "$1" == "purge" ] && [ -e /usr/share/debconf/confmodule ] ; then ...@@ -3,5 +3,13 @@ if [ "$1" == "purge" ] && [ -e /usr/share/debconf/confmodule ] ; then
. /usr/share/debconf/confmodule . /usr/share/debconf/confmodule
db_purge db_purge
fi fi
usermod -G $(groups $(id -nu) | sed 's/kelvin//') GROUP_RM="kelvin"
systemctl stop kelvin-node
systemctl disable kelvin-node
for username in (cat /etc/passwd | grep "/home" | cut -d ':' -f1); do
gpasswd -d $username $GROUP_RM
done
rm -r /opt/kelvin-node
groupdel kelvin groupdel kelvin
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment