This repo is a price prediction contracts on Secret Network.
| Name | Address |
|---|---|
| Oracle | secret19hd5ywtp9uqczw8e40vq0psgn9zefey02n806e |
| SCRT prediction | secret1aaxgtpzv8a3pdkznmwkyh4w99uylj4x4232lg7 |
- Install npm dependencies by using
npm ioryarn add - Run local node
docker run -it -p 9091:9091 -p 1337:1337 --name secretjs-testnet enigmampc/secret-network-sw-dev:v1.2.2-1-
Update
accounts/local.jsfile with the seed accounts of local node. -
Create
.envfile and addTESTNET_ADDRESS,TESTNET_MENMONIC,MAINNET_ADDRESS,MAINNET_MNEMONIC. These are required to deploy contracts on testnet and mainnet.
yarn compile
yarn test
- Complete
.envfile. scripts/deployOracle.jswill deploy oracle contract, and register SCRT native token and set owner address as a feeder. So before run this, please update asset info, and feeder address.- Run the following commands
polar run scripts/deployOracle.js --network testnet
- Complete
.envfile. - Update config in
scripts/deployPrediction.js. - Run the following commands
polar run scripts/deployPrediction.js --network testnet