This project is a simple blockchain-based certification management system built using Truffle, Ganache, and Node.js. It allows users to add, retrieve, and verify certificates stored on the Ethereum blockchain.
To run this project on your machine, you need to have the following prerequisites installed:
- Node.js
- Truffle
- Ganache
-
Clone the Repository:
git clone https://github.com/Shricastic7/certification-using-blockchain
-
Install Dependencies:
Navigate into the project directory and install the necessary dependencies using npm:
cd certification-using-blockchain npm install
-
Start Ganache:
Start Ganache, which provides a local blockchain environment:
- Open the Ganache application.
- Start a new workspace or use an existing one.
- Make note of the RPC server address (usually
http://127.0.0.1:7545
).
-
Compile Contracts:
Compile the smart contracts using Truffle:
truffle compile
-
Migrate Contracts:
Deploy the smart contracts to the local blockchain:
truffle migrate --network ganache
Replace
ganache
with the network configuration name in yourtruffle-config.js
ortruffle-config.json
. -
Start Node.js Backend:
Start the Node.js backend server:
npm run start
This will start the backend server and connect it to your local blockchain.
- Use the provided endpoints in your Node.js application to interact with the smart contracts.
- For example, you can add certificates, retrieve certificates, and verify certificate authenticity using the exposed endpoints.
Contributions are welcome! Feel free to open issues or submit pull requests.
This project is licensed under the MIT License.