Coder Social home page Coder Social logo

tkuhrt / citizens-pulse Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hyperledger-labs/citizens-pulse

0.0 1.0 0.0 9.85 MB

A fully distributed citizens pulse platform for state/city councils - with Hyperledger Fabric

Home Page: https://wiki.hyperledger.org/pages/viewpage.action?pageId=29036032

License: Apache License 2.0

Dockerfile 0.05% JavaScript 34.98% Shell 11.27% Kotlin 0.02% Swift 0.06% Objective-C 0.01% Dart 4.57% Go 5.20% HTML 0.38% CSS 22.98% SCSS 20.49%

citizens-pulse's Introduction

Hyperledger Citizens Pulse

license

A fully distributed platform for state/city councils to propose plans and garner voices of the public, built with Hyperledger Fabric.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. The following commands assume the operating system to be a Linux based distribution.

Prerequisites

Following are a few dependencies that need to be installed:

  • Git
  • Docker, Docker Compose
  • Go release, version 1.13 or greater
  • Node: any 12.x version starting with v12.0.0 or greater

Installing

  1. Clone the repository
    git clone https://github.com/hyperledger-labs/citizens-pulse.git
    
  2. Install fabric-binaries by running the following command.
    ./binaries.sh -d -s # if you only want to install the binaries
    ./binaries.sh -s # if you want to install the docker images as well as binaries
    
  3. cd into the network directory. Delete any previous running containers, images or network instances
    ./generate.sh delNet
    
  4. Bring up the project i.e. the Hyperledger Fabric network, the API and Web Server. The network entails creation of channel having two Orgs, deployment of chaincode on all peers of both the organisations. The API server is to interacts with the network once up, while the Web server delivers pages to client-side thus enabling the user to send requests.
    ./generate.sh projectUp
    
    In case of a failure, try bringing up the containers individually, as follows:
    ./generate.sh createChannel
    ./generate.sh deployCC       # deploys the chaincode
    ./generate.sh api            # starts the API server, runs on localhost:5000
    ./generate.sh webui          # starts the Web server, runs on localhost:3000
    
    The CouchDB GUI showing all the databases and documents can be viewed at http://localhost:5984/\_utils/. To make sure that the private-collections (meant for plan data persistence) have been created, check-out the mychannel_plan$c$c\$$pcollection$plan and mychannel_plan$c$c\$$pcollection$plan$private$details documents.
  5. Navigate to http://localhost:3000/ in your browser. Signup user to Org1 as a dummy user mandatorily.

Testing (Manual)

Web

Mobile

  • To test with an Android emulator, follow the following steps:

    1. Start the emulator/AVD
    2. Add a device which supports API 28 (at the time of writing)
    3. Drag and Drop the .apk file on top of the device and accept for installation
    4. Login via the above dummy user by providing credentials user/test.
  • To testing with a real device: This is to handle times when you do not have a device to test the mobile part.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests.

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

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.