Skip to content

This repository contains simple web3 application with automated CI/CD.

License

Notifications You must be signed in to change notification settings

piotrjwegrzyn/cyrograf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cyrograf

This repository contains simple web3 application with automated CI/CD.

Project structure

The repository consists of couple different parts divided into folders:

  • .github/workflows/ – definitions of CI/CD pipelines,
  • eth/ – smart contract for backend,
  • integration/ - current smart contract ABI and integration tests,
  • ui – frontend of web3 app.

Frontend

The frontend is build in pure HTML, CSS and JavaScript. It utilizes the web3 library.

ui

The following diagram presents the usage of application:

usage_diagram

Backend

The backend is basend on Ethereum's smart contract written in Solidity. There are also unit tests for contract.

The contract handles two requests:

  • getBackground() – returns Background object which represent RGB values of two corners in the UI and wallet address of last setter,
  • setBackground() – takes two tuples of RGB colour values and stores them in a ledger.

CI/CD

The Continuous Integration and Continuous Testing is divided into couple of stages visualized in picture:

cicd

With each pull request merged with changes of smart contract the integration tests are performed and new PR with ABI update for frontend is automatically opened by github-bot.

External links

Implemented CI/CD workflow is based on following pipelines:

License

All software in this repository is published under GNU General Public License v3. See LICENSE file.