Make sure you've install the prerequisites.
## If you haven't installed the agoric-sdk already
cd agoric-sdk
git checkout 65d3f14c8102993168d2568eed5e6acbcba0c48a
yarn && yarn build
yarn link-cli ~/bin/agoric
## Install the Dapp
git clone _PATH_TO_YOUR_REPO_CREATED_FROM_THE_TEMPLATE_
cd agoric-week-1
agoric install
## Start simulated blockchain
agoric start --reset --verbose
cd agoric-week-1
## Deploy the contract
agoric deploy contract/deploy.js api/deploy.js
## Open Wallet UI
agoric open --repl
Make sure to execute below commands after the commands in Termianl 3
are finished executing.
## Start Dapp UI
cd agoric-week-1/ui
yarn start
Our sample dapp demonstrates an auction for baseball cards. Users will place their bids on the cards they want and after the bid duration ends the highest bidding user will receive the baseball card in their wallet. The bid duration is 5 mins.
-
Open http://localhost:3000 from your browser. You should see something like below:
-
Then go to the page automatically opened when you execute
agoric open --repl
command. Approve the dapp from the dashboard. -
Once the approval is successful you should see the list of baseball cards available.
-
Click on one of the cards and place your bid.
-
Go to your wallet UI and approve the offer.
-
Wait for 5 mins then see your baseball card in your
cardStore.Card
purse.