Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add deploy scripts for sp #54

Merged
merged 4 commits into from
Feb 16, 2023
Merged

Conversation

jingjunLi
Copy link
Contributor

@jingjunLi jingjunLi commented Feb 15, 2023

Description

add deploy storage provider function for localup.sh

Example

  1. ./deployment/localup/localup.sh all 1 3
    start validator & add 3 sps join the chain.

  2. after about 4-5 mins, use ./deployment/localup/localup.sh sp_check 3 check whether sp added success.


n=0
while [ $n -le 360 ]; do
approval_cnt=("$(${bin} query sp storage-providers --node http://localhost:26750 | grep approval_address | wc -l)")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why approval cnt?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fix it to cnt, means the sp cnt added to chain.

@@ -7,6 +7,10 @@ source ${workspace}/utils.sh
bin_name=gnfd
bin=${workspace}/../../build/bin/${bin_name}

function build() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need to add this.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

@@ -150,11 +154,124 @@ function stop() {
ps -ef | grep ${bin_name} | grep validator | awk '{print $2}' | xargs kill
}

function validator_deploy() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a little bit confusing about this function name. why need sp_size when deploy validator?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed, add sp_join & sp_check, these two functions only use sp_size。

@unclezoro unclezoro merged commit 92a4481 into develop Feb 16, 2023
@unclezoro unclezoro deleted the add_deploy_scripts_for_sp branch April 18, 2023 09:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants