Skip to content
This repository has been archived by the owner on Nov 9, 2024. It is now read-only.

Commit

Permalink
Add lava-testnet-2 deployment && Cosmovisor integration
Browse files Browse the repository at this point in the history
  • Loading branch information
YakupAltay committed Feb 23, 2024
1 parent 0228c1e commit 347bbe6
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions src-tauri/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -621,14 +621,26 @@ fn update_node(latest_version: String, exception: String) -> Result<(), String>
sudo make install;
systemctl restart $EXECUTE;'"
),
"lavad" => format!(
"bash -c -l '
cd $PROJECT_FOLDER;
git pull;
git checkout {latest_version};
export LAVA_BINARY=lavad;
make build;
mkdir -p $HOME/$SYSTEM_FOLDER/cosmovisor/upgrades/{latest_version}/bin;
mv $(which $EXECUTE) $HOME/$SYSTEM_FOLDER/cosmovisor/upgrades/{latest_version}/bin/;
rm -rf build;'"
),
_ => format!(
"bash -c -l 'systemctl stop $EXECUTE;
"bash -c -l '
cd $PROJECT_FOLDER;
git fetch --tags;
git pull;
git checkout {latest_version};
make build;
sudo make install;
systemctl restart $EXECUTE;'"
mkdir -p $HOME/$SYSTEM_FOLDER/cosmovisor/upgrades/{latest_version}/bin;
mv $(which $EXECUTE) $HOME/$SYSTEM_FOLDER/cosmovisor/upgrades/{latest_version}/bin/;
rm -rf build;'"
),
};
channel.exec(&command).map_err(|e| e.to_string())?;
Expand Down

0 comments on commit 347bbe6

Please sign in to comment.