Git Product home page Git Product logo

soular-blockchain's Introduction

Compile blockchain code

Compiling the contract run truffle-compile cd build/contract and extract the abi and contract address from Energy.json

Sign up an account with Infura

Sign up an account with Infura (https://infura.io/) and create a project In Infura, go to settings and extract the ‘PROJECT ID’ and select an ‘ENDPOINT’ and select an ethereum net that the project is using (in this project, it is using Kovan Test Net) Update the ‘PROJECT ID’ and contract address https://github.com/busukxuan/soular-microservices/blob/master/common/blockchain.ts Login to either Ganache or a current crypto wallet and input the ’WALLETADDRESS’

Deploying in any testnet you like

npm run start:<kovan>

After deployment

After a successful buy/sell is triggered, go to https://kovan.etherscan.io/ and enter the contract address in the search. A transaction will be updated to the contract address within 15 seconds of triggering from the application

Credits

https://blog.ippon.tech/creating-your-first-truffle-project-part-2-of-2/ https://medium.com/coinmonks/step-by-step-approach-to-create-dapp-using-ethereum-reactjs-ipfs-part-3-final-851187ca9c24 https://www.freecodecamp.org/news/hands-on-get-started-with-infura-and-ipfs-on-ethereum-b63635142af0/

soular-blockchain's People

Contributors

phangster avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.