From 22501cd954ba480b05de1e62a5f51a614d6d2b43 Mon Sep 17 00:00:00 2001 From: 0xOzgur <29779769+0xOzgur@users.noreply.github.com> Date: Fri, 24 May 2024 23:12:49 +0300 Subject: [PATCH] add upgrade binary for amd64 --- install/install_binary.sh | 2 +- profile/.bash_profile | 33 +++++++++++++++++++++++++++ snapshot.sh | 2 +- updateV1.4.18.sh | 47 +++++++++++++++++++++++++++++++++++++++ 4 files changed, 82 insertions(+), 2 deletions(-) create mode 100644 profile/.bash_profile create mode 100644 updateV1.4.18.sh diff --git a/install/install_binary.sh b/install/install_binary.sh index 811815e..4612ba1 100644 --- a/install/install_binary.sh +++ b/install/install_binary.sh @@ -67,7 +67,7 @@ WantedBy=multi-user.target EOF # Step 7:Start the ceremonyclient service -echo "✅SStarting Ceremonyclient Service" +echo "✅Starting Ceremonyclient Service" sleep 2 # Add a 2-second delay systemctl enable ceremonyclient service ceremonyclient start diff --git a/profile/.bash_profile b/profile/.bash_profile new file mode 100644 index 0000000..355cc09 --- /dev/null +++ b/profile/.bash_profile @@ -0,0 +1,33 @@ +# .bash_profile + +# If .bash_profile exists, bash doesn't read .profile +if [[ -f ~/.profile ]]; then + . ~/.profile +fi + +# If the shell is interactive and .bashrc exists, get the aliases and functions +if [[ $- == *i* && -f ~/.bashrc ]]; then + . ~/.bashrc +fi + +export HISTTIMEFORMAT="%d/%m/%y %T " + + + +alias e="exit" +alias cm="ps -eo comm,pcpu --sort -pcpu | head -8; ps -eo comm,pmem --sort -pmem | head -8" +alias st='curl -s https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py | python3' +alias myip='curl icanhazip.com' +alias wttr='curl wttr.in' + +neofetch + + +alias peer-count='cd ~/ceremonyclient/node && grpcurl -plaintext -max-msg-sz 150000000 localhost:8337 quilibrium.node.node.pb.NodeService.GetPeerInfo | grep peerId | wc -l && cd ~' +alias node-info='cd ~/ceremonyclient/node && GOEXPERIMENT=arenas go run ./... -node-info && cd ~' +alias db-console='cd ~/ceremonyclient/node && - GOEXPERIMENT=arenas go run ./... --db-console && cd ~' +alias balance='cd ~/ceremonyclient/node && GOEXPERIMENT=arenas go run ./... -balance && cd ~' +alias nlog='sudo journalctl -u ceremonyclient.service -f --no-hostname -o cat' +alias nstart='service ceremonyclient start' +alias nrestart='service ceremonyclient restart' +alias nstop='service ceremonyclient stop' \ No newline at end of file diff --git a/snapshot.sh b/snapshot.sh index 62d4c90..255aecc 100644 --- a/snapshot.sh +++ b/snapshot.sh @@ -2,5 +2,5 @@ service ceremonyclient stop apt install unzip -y -wget -qO- https://snapshots.cherryservers.com/quilibrium/store.zip > /tmp/store.zip && unzip -j -o /tmp/store.zip -d $HOME/ceremonyclient/node/.config/store && rm /tmp/store.zip +rm -r $HOME/ceremonyclient/node/.config/store && wget -qO- https://snapshots.cherryservers.com/quilibrium/store.zip > /tmp/store.zip && unzip -j -o /tmp/store.zip -d $HOME/ceremonyclient/node/.config/store && rm /tmp/store.zip service ceremonyclient start \ No newline at end of file diff --git a/updateV1.4.18.sh b/updateV1.4.18.sh new file mode 100644 index 0000000..628848b --- /dev/null +++ b/updateV1.4.18.sh @@ -0,0 +1,47 @@ +#!/bin/bash + +# Stop the ceremonyclient service +service ceremonyclient stop + +# Step 0:Download Binary +echo "⏳ Downloading Binary" +sleep 2 # Add a 2-second delay +cd ~/ceremonyclient/node + +wget -O- https://github.com/QuilibriumNetwork/ceremonyclient/releases/download/v1.4.18/node-1.4.18-linux-amd64.bin > $HOME/ceremonyclient/node/node + +# Step 1:Make the file executable +echo "⏳ Making the Binary executable" +sleep 2 # Add a 2-second delay +chmod +x node + +# Step 3:Re-Create Ceremonyclient Service +echo "⏳ Re-Creating Ceremonyclient Service" +sleep 2 # Add a 2-second delay +rm /lib/systemd/system/ceremonyclient.service +sudo tee /lib/systemd/system/ceremonyclient.service > /dev/null <