Code Monkey home page Code Monkey logo

www's Introduction

ARCHIVED





Archived Content (below)

www

www repository contains Rchain websites. These websites are:

The open-source RChain project is building a decentralized, economic, censorship-resistant, public compute infrastructure and blockchain. It will host and execute programs popularly referred to as “smart contracts”. It will be trustworthy, scalable, concurrent, with proof-of-stake consensus and content delivery.

  +------------------------------------------------------------------------+
  |                            Rchain K8 Cluster                           |
  |------------------------------------------------------------------------|
  |                                 +------------+                         |
  |                             +---|rchain-coop |                         |
  |  +-------+                  |   +------------+                         |
  |  | certs |                  |   +------------+                         |
  |  +-------+      +---+       |   |developer-  |          +------------+ |
  |  +-------+      | I |       +---|rchain-coop |<-------- | postgreSQL | |
  |  |issuer |<---->| n |       |   +------------+          +------------+ |
  |  +-------+      | g |<----->|   +------------+          +------------+ |
  |                 | e |       +---| wordpress  |<-------- |mysql       | |
  |  +-------+      | s |       |   +------------+          +------------+ |
  |  | cert- |      | s |       |   +-------+                              |
  |  | mgr   |      +---+       +---|rsong  |                              |
  |  +-------+                  |   +-------+                              |
  +------------------------------------------------------------------------+

Installation

Install

Content developers may use any additional content tool of their choice.

Developers will require additional tooling, see Development setup

Contributing

All work must have a corresponding work order, JIRA ticket. To contribute:

  • Fork the repo
  • Create your feature branch (git checkout -b feature/fooBar)
  • Commit your changes as outlined in Committing your work
  • Push to the branch (git push origin feature/fooBar)
  • Create a new Pull Request
  • Select a Reviewer

Note: All pull request must be reviewed before merging to master branch

Releasing your changes to Production

www is a CI/CD project.
Once pull requests are reviewed and merged to master branch, Cloud Build is triggered to:

Committing your work

Prefix git commit messages with one or more of prefixes as outlined here:

Annotation Description Example
[INTERNAL] used for internal stuff git commit -m "[INTERNAL] my internal change"
[FIX] contains bug fix git commit -m "[FIX] my fix change"
[FEATURE] contains a new feature git commit -m "[FEATURE] my new feature"
[DOC] contains documentation git commit -m "[DOC] my documentation change"

Generating change logs and release

Change logs and release notes are generated on demand. To generate to notes from the root of the project folder:

./changelog.sh

Development setup

The websites are dockerized and deployed to kubernetes-cluster. You may build your own image by executing make from each sub-project folder:

cd rchain-coop && make
cd developer-rchain-coop && make
cd rsong && make

You may also run the official docker image from from GCP RChain Container Registry provided that you have sufficient access

Note: this is a private registry

Installation requirements

Installing rchain.coop

git clone [email protected]:kayvank/www.git  ## replace kayvan with your git-user-id
cd www
cd rchain-coop
npm install
npm prune
gulp  ## transpiles the rchain.coop
npm start ## to execute the site

To test the rchain.coop locally point your browser to localhost:3000

curl -v localhsot:3000

To create, publish and execute a docker image:

cd www
cd rchain-coop
make
docker images | grep rchain-coop
docker run -p3000:3000 <MY-DOCKER-ID>/rchain-coop:v1.0<SHORT-SHA>

Installing developer.rchain.coop

To install and run developer.rchain.coop locally, pre-populated postgreSQL is required. The project contains a [PostgreSQL docker-compose] that you may use. To use the docker-compose file, make sure you have setup your environment variables as outlined in Project environment variables section

git clone [email protected]:kayvank/www.git  ## replace kayvan with your git-user-id
cd www
cd developer-rchain-coop
npm install
npm prune
cd test
docker-compose up -d
docker inspect `docker ps | grep postgres | awk '{print $1}'` | grep IPAddress
## modify the DB_IP environment variable to match the postgres ip
gulp 
npm start ## to execute the site

To test the rchain.coop locally point your browser to localhost:3000

curl -v localhost:3000

Installing rsong

git clone [email protected]:kayvank/www.git  ## replace kayvan with your git-user-id
cd www
cd rsong
make
docker images | grep rsong
docker run -p80:80 <MY-DOCKER-ID>/rsong:v1.0<SHORT-SHA>

To test the rchain.coop locally point your browser to $DOCKER_IP, see environment variables.

curl -v $DOCKER_IP

Environment variables

To build and run the projects locally configure your environment as such:

export DOCKER_USER= my_docker_username
export DOCKER_PASS=my_docker_secret_password
export SHA=`git rev-parse --short HEAD`
export SHORT_SHA=$SHA

export PGUSER='rock_user'
export PGPASSWORD='pg_secret_password'
export PGDB=$PGUSER
export DOCKER_IP='172.24.0.3' ## may have to be modified depending on docker inspect output
export DB_IP=$DOCKER_IP
export DB_URL="postgresql://$PGUSER:$PGPASSWORD@$DB_IP:5432/$PGDB"

export MYSQL_USER=user123
export MYSQL_PASS='password-123'
export MYSQL_ROOT_PASSWORD='my-root-password'
export K8_NAMESPACE='dev-blog'

Although not required, consider using direnv

www's People

Contributors

corollari avatar dckc avatar derekberes avatar ian-bloom avatar jamesmoc avatar kayvank avatar kentshikama avatar leithaus avatar zsluedem avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

www's Issues

Create FAQ site at faq.rchain.coop

After some discussion on Discord, we are proceeding to set up a self-hosted FAQ service where we can collect authoritative replies to frequently asked questions.

Individual FAQ items should have their own links that we can provide to anyone asking a related question in a chat or social media channel.

In the future, this faq site could be upgraded to utilize the open-source StackEdit engine and provide a richer experience that could support developer Q&A.

Migrate Co-op Sites to gh-pages & external host

Why

  • Current hosting is too expensive (approx $5/day)
  • Current hosting is complex and hard to maintain

What

How

Static Sites

Since moving away from Pyrofex, I've stripped out all non-static components from the www & dev sites. @dckc demonstrated simple static site migration using wget on the www site, and I've had similar success on the dev site.

These sites can be hosted as gh-pages, optionally to be placed behind a cheap CDN. Version control, CI/CD, and SSL could then be handled negatively by GitHub instead of using our current complex wiring.

Wordpress Sites

Migration of the blog site somewhat complicated because it is a "MultiSite" configuration with content that we've generated through 3rd party plugins and a deeply integrated "Divy builder framework". It is doable, but may take some time to sort out 3rd party licensing , reconfigure podcast rss builder, and re-create Divy-Builder content. The faq.rchain.coop WP site is underutilized and can be recreated elsewhere as a GitHub markdown or web page.

Consider future work of migrating blog content over to gh-pages and collapsing the blog subdomain into rchain.coop/blog) There are other free or cheap ways to host the podcast RSS feed that using the Seriously Simple Podcasting WP Plugin. Note, we've also been using the WP Yeost plugin to generate pretty badges for our Social Media posts.

Collapse dev site into www

The Subdomain vs Subdirectory issue is no longer complicated by having the www site hosted on Squarespace. With both www and dev hosted as static gh-pages it will be much easier to collapse the dev site into rchain.coop/dev.

To redirect old links, we can create additional gh-pages for www and dev that point to the new site.

Sequence

  • Migrate WP blog to another host
  • Copy www & dev into gh-pages branches
  • Configure www & dev rewrite repos
  • DNS changes
  • Tear down rchain/www Kubernetes and CI/CD

Q2, Q3 roadmap updates

In telegram, someone asked

What is a plan for future (Q3, Q4 2020)?

@MaximilianR writes in reply:

Within Q2, finish last finalized state, which greatly reduces time it takes to launch a new node to catch up with the network, and finish block merge, which allows the network to have a DAG structure as intented, which improves the throughput of the network as validators can work in parallel you could say.

For Q3 it is finishing sharding and getting Rholang 1.1 out which greatly improves the UX of the language, making it easier for developers to build

Max, where did you get that info? Please cite a source in telegram.

It should be in the Roadmap section of https://developer.rchain.coop/ ; please make a PR to update that section (including citing sources).

The REV Issuance page on the developer site needs updating to remove confusing statements

Most of the page can very easily be fixed by for instance changing a word from "will" to "was".

For instance, this section in the top paragraph

At the launch of main net, planned for February 4, 2020, there will be an issuance of REV at a 1:1 ratio based on a holder’s RHOC balance. REV will be the currency of the RChain blockchain. Among other things, REV will allow you to bond a validator’s stake, pay transaction fees, and deploy smart contracts on the new RChain blockchain. If you’re interested in building your own RChain-based dApp, you will need to acquire REV in order to do so.

could be rephrased to

At the launch of main net, which occured February 25th, 2020, there was an issuance of REV at a 1:1 ratio based on a holder’s RHOC balance. REV is the currency of the RChain blockchain. Among other things, REV allows you to bond a validator’s stake, pay transaction fees, and deploy smart contracts on the new RChain blockchain. If you’re interested in building your own RChain-based dApp, you will need to acquire REV in order to do so.

Certain entries in the FAQ-box needs updating in a similar way. The Key Milestones-box should be updated with the accurate main net launch date as well.

rsong broken links

rsong.rchain.coop & rsong.org blog links should point to

blog.rchain.coop/...
not rchain.coop/blog/...

Derek dev branch #31

Updated /platform page, removing animated gifs, fixing grammatical errors for clarity.

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.