Skip to content

Commit

Permalink
Fix deploy.sh script on Mac
Browse files Browse the repository at this point in the history
  • Loading branch information
fridrik01 committed Apr 22, 2024
1 parent 3dcf690 commit 189b072
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion ipc/provider/src/manager/evm/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -573,7 +573,7 @@ impl SubnetManager for EthSubnetManager {
from: Address,
amount: TokenAmount,
) -> Result<ChainEpoch> {
log::debug!("approve token, subnet: {subnet}, amount: {amount}, from: {from}");
tracing::debug!("approve token, subnet: {subnet}, amount: {amount}, from: {from}");

let value = fil_amount_to_eth_amount(&amount)?;

Expand Down
2 changes: 1 addition & 1 deletion scripts/deploy_subnet_under_calibration_net/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ To run this script locally, you need to first manually prepare the environment a
3. Run `deploy.sh local` to deploy IPC locally.

Please also notice that
1. The `deploy.sh` is only for running on Linux. If you are using a Mac, you need to disable all `apt` based dependency installation. You may also need to install bash (version >= 5) to run this script since the script isn't fully compatible with zsh (default shell on Mac).
1. The `deploy.sh` is only for running on Linux. If you are using a Mac, you need to disable all `apt` based dependency installation. You may also need to install bash (version >= 5) to run this script since the script isn't fully compatible with zsh (default shell on Mac). Also, make sure you habe openssl packages installed (`brew install openssl@3`).
2. The automated dependency installation isn't guarantee to work 100% time. If you encountered any dependency installation issue, please refer to the script and retry. Usually you can resolve the issues by creating a new terminal, sourcing `~/.bash.rc`, etc.
3. Depends on the RPC endpoint's quality of service for the calibration net, your command may or may not succeed when interacting with the RPC endpoint. Sometimes you will get rate limited. In that case, you can choose a different calibration provider URL from [Chainlist](https://chainlist.org/?search=calibration&testnets=true) to replace the value of `RPC_URL` variable in the script, then retry it.
4. You need to manually install nodejs and npm. The reason is that we need to use very recent version of nodejs and it's usually not included with the Linux distribution. It's recommended that you use nvm (Node version manager) to manage your nodejs installation.
Expand Down
8 changes: 5 additions & 3 deletions scripts/deploy_subnet_under_calibration_net/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,11 @@ else
fi

# Make sure we re-read the latest env before finishing dependency installation.
set +u
source ${HOME}/.bashrc
set -u
if test -f ${HOME}/.bashrc; then
set +u
source ${HOME}/.bashrc
set -u
fi

# Step 2: Prepare code repo and build ipc-cli
if ! $local_deploy ; then
Expand Down

0 comments on commit 189b072

Please sign in to comment.