2022-07-14 01:03:36 -07:00
|
|
|
For deploying to mainnet,
|
|
|
|
|
2022-07-14 01:05:43 -07:00
|
|
|
If there are no breaking changes, simply running `release-to-mainnet.sh` should suffice.
|
2022-07-14 01:03:36 -07:00
|
|
|
|
|
|
|
- close accounts for recovering rent sol + allow creating them with new layout in future with same PDA address
|
2022-07-14 01:07:18 -07:00
|
|
|
|
|
|
|
- close mango account `ts/client/src/scripts/mb-example1-close-account.ts`,
|
|
|
|
note: for whatever reason if withdrawing tokens, or closing positions, etc. fails, just comment out everything else and just run the script with
|
|
|
|
`await client.closeMangoAccount(group, mangoAccount);`
|
|
|
|
- close all things setup by admin `ts/client/src/scripts/mb-example1-admin-close.ts`
|
|
|
|
note: the admin does get dust token balances, so no mainnet tokens are lost
|
2022-07-14 01:03:36 -07:00
|
|
|
|
|
|
|
- merge dev to main, and then `release-to-mainnet.sh` to deploy latest code to mainnet
|
|
|
|
- setup group and banks, etc. using `ts/client/src/scripts/mb-example1-admin.ts`
|
2022-07-14 01:05:43 -07:00
|
|
|
- update ids json `ts/client/src/scripts/mb-example1-ids-json.ts`
|
2022-07-14 01:12:47 -07:00
|
|
|
- create mango account and deposit some tokens `ts/client/src/scripts/mb-example1-ids-json.ts`
|
|
|
|
|
|
|
|
tldr;
|
|
|
|
|
|
|
|
```
|
|
|
|
yarn ts-node ts/client/src/scripts/mb-example1-close-account.ts
|
|
|
|
yarn ts-node ts/client/src/scripts/mb-example1-admin-close.ts
|
|
|
|
./release-to-mainnet.sh
|
|
|
|
yarn ts-node ts/client/src/scripts/mb-example1-admin.ts
|
|
|
|
yarn ts-node ts/client/src/scripts/mb-example1-ids-json.ts
|
|
|
|
yarn ts-node ts/client/src/scripts/mb-example1-ids-json.ts
|
|
|
|
```
|
2022-07-14 01:13:58 -07:00
|
|
|
|
|
|
|
TODO:
|
2022-07-14 01:14:23 -07:00
|
|
|
- consolidate devnet+mainnet-beta scripts into single scripts
|
|
|
|
- consolidate release scripts
|