Search icon
Subscription
0
Cart icon
Close icon
You have no products in your basket yet
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Blockchain By Example

You're reading from  Blockchain By Example

Product type Book
Published in Nov 2018
Publisher Packt
ISBN-13 9781788475686
Pages 528 pages
Edition 1st Edition
Languages
Concepts
Authors (3):
Bellaj Badr Bellaj Badr
Profile icon Bellaj Badr
Richard Horrocks Richard Horrocks
Profile icon Richard Horrocks
Xun (Brian) Wu Xun (Brian) Wu
Profile icon Xun (Brian) Wu
View More author details

Table of Contents (13) Chapters

Preface 1. Say Hello to Blockchain 2. Building a Bitcoin Payment System 3. Building Your Own Cryptocurrency 4. Peer-to-Peer Auctions in Ethereum 5. Tontine Game with Truffle and Drizzle 6. Blockchain-Based Futures System 7. Blockchains in Business 8. Creating an ICO 9. Distributed Storage IPFS and Swarm 10. Supply Chain on Hyperledger 11. Letter of Credit (LC) Hyperledger 12. Other Books You May Enjoy

Running the auction DApp

At this level, you should have already deployed your contract on one of the deployment environments presented beforehand. To try what we have built so far, follow these instructions:

  1. In auction.js, define your RPC and port provider: web3.setProvider(new web3.providers.HttpProvider("http://<IP>:<port>"));.
  2. Change the contract's address: var contractAddress = "your contract address";.
  3. Afterwards, open the index.html file directly in your browser or by using a web server. The loaded web page looks as follows:

To start interacting with this DApp, the easiest method is to use MetaMask connected to Ganache. In this case, we'll need to import some of the accounts created by Ganache into MetaMask. To do that, we copy the private key from the Ganache interface and in MetaMask, we import the corresponding accounts by...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}