-
Notifications
You must be signed in to change notification settings - Fork 36
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
Deployment scripts for Solana #688
Conversation
These changes include bash scripts and typescripts that are used to build and deploy programs on Solana. We also need to initalize these programs. More init work to come..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would leverage the Makefile more. But if it's easier for you to add commands to Anchor.toml, that looks fine to me, too.
- Moved init TS scripts to /deploy dir - Building programs with make build - Deploying programs with solana cli instead of anchor
Mapped Arbitrum, Optimism, Polygon and Base for testnet and mainnet. Added addresses to consts file. Added addresses of TBTC wrapped token.
cross-chain/solana/package.json
Outdated
"scripts": { | ||
"build": "anchor build", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would get rid of this since you have the Makefile specifying the build
command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, done in feb345b
cross-chain/solana/package.json
Outdated
"lint:fix": "prettier */*.js \"*/**/*{.js,.ts}\" -w", | ||
"lint": "prettier */*.js \"*/**/*{.js,.ts}\" --check" | ||
"lint": "prettier */*.js \"*/**/*{.js,.ts}\" --check", | ||
"test": "anchor test" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would get rid of this, too, since you have the Makefile specifying the test
command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, done in feb345b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just left a few notes for someone else wanting to do clean up in the package.json file.
Also if the shell scripts are supposed to have commented-out commands, everything looks good.
These changes include bash scripts and init scripts that are used to build, deploy and init
tbtc
&wormhole_gateway
programs on Solana.Usage:
./scripts/deploy.sh
- due to the nature of deployment on Solana, it is very tricky to do everything in one shot. Please read the comments. Certain parts of this script need to be uncommented one by one to deploy programs properly./scripts/transfer_authority.sh
- same as above, please read the comments and uncomment the parts one by one. Formainnet
use only.tbtc
on mainnet https://solscan.io/account/Gj93RRt6QB7FjmyokAD5rcMAku7pq3Fk2Aa8y6nNbwsVwormhole_gateway
on mainnet https://solscan.io/account/87MEvHZCXE3ML5rrmh5uX1FbShHmRXXS32xJDGbQ7h5tCommented-out commands in the bash scripts are intentional because it is tricky to deploy on Solana in one shot.