cubeca / cube

Repository for Cube Commons Client and Services
https://cubecommons.ca/
MIT License
3 stars 0 forks source link

Table of Contents - trying branch restrictions

CubeCommons

CubeCommons aggregates video, audio, digital publications, and activity booklets by arts organizations and artists across northern Turtle Island (Canada). This repository contains the front-end React app, Express services, and database schema details to run the project.

File Structure

/client

This is the front-end user interface in the form of a typical React application.

/services

This includes the cube-svc microservice that supports all operations. Additionally, there is a VTT service responsible for coordinating subtitle generation between GCP and OpenAI.

Project Infrastructure

Database

CubeCommons utilizes a serverless database solution called CockroachDB. Cockroach Labs offers a generous free tier that auto-scales based on demand. You may use any database solution you wish. The schema details are outlined below.

User Permissions

There is a small set of user permissions that are associated to the user record allowing actions to be taken. The thresholds are:

Cloud Infrastructure

The above services are packaged into Docker containers and deployed to Google Cloud Run for resource, instance, and scalability management. These docker containers can be deployed using any server structure that you wish.

Front-End Hosting

The built front-end React app is hosted on Cloudflare Pages. There is some light configuration in the tsconfig.json to support this deployment. Cloudflare Pages offers a generous free tier and automatic deployments and may be switched out for any alternative hosting option.

Governance

CubeCommons uses a third-party tool called Gov4Git to govern its' issues and pull requests. This Tool was developed by Digital Minister Audrey Tang (they/them) and their collaborators – architects of Taiwan’s internationally acclaimed digital democracy technology. Learn more about Audrey Tang: https://www.plurality.net/ Gov4git installation links and instructions can be found here: https://gitrules.ai/

Follow these steps to get started with Gov4Git for CubeCommons:

  1. Create a GitHub profile https://github.com/
  2. Download Gov4Git on MacOS or Windows using the links found here: https://github.com/gov4git/gov4git/blob/v2/README.md
  3. Once installed, open Gov4Git on your computer and follow the login and verification instructions using your GitHub account details.
    • Login with the Verify link, copy the verification code and enter it when prompted.
    • Once Verified, the Gove4Git desktop app should show a button called “Join a community”, this can always be found under settings. Under "Join Community" there is an input titled "Community URL". Paste this CubeCommons URL: “https://github.com/cubeca/cube
  4. Approval may take a few minutes.

Requesting Voting Tokens:

  1. Once approved, go back to your browser and login to your GitHub account (if you're not already), click on the GitHub logo - found in the top left corner (looks like a small cat) - this should take you to your dashboard.
  2. On the left hand side under repositories, you'll see the ‘cubeca’ repository that you’ve just joined.
  3. click on the 'cubeca' repository this will take you to a new page on Github.
  4. Under the Github logo in the top navigation bar is a secondary navigation bar with the buttons "code", "Issues", "Pull requests" etc. Click “Issues”, this will take you to a new page on GitHub
  5. On the right hand side of this new page, click a green button titled “New Issue” and create a request for voting tokens.

Formatting "New Issues" as Requests or Proposals:

Setup

1. Create Database Tables

2. Email Provider

Email notifications sent to users for activities like account creation or password management are coordinated with Brevo. Brevo assists with template management, newsletter campaigns, and is the mail server. CubeCommons uses Brevo's APIs to implement this functionality so a Brevo account is a requirement to proceed.

3. Configure Environment Variables

cd services/cube-svc/
cp .env.example .env
npm i
npm run start

The service will now be running on http://localhost:8080

4. Start the Client

cd client
cp .env.example .env
npm i
npm run start

Styleguide

Site styles can be referenced in the theme file.

Contributing

We welcome code contributions to CubeCommons! This can be new features or components that you have developed after forking our code. Please follow these steps to contribute:

  1. Fork the repository.
  2. Create a new branch for your feature or bugfix.
  3. Make your changes and commit them to your branch.
  4. Push your changes to your fork.
  5. Open a pull request to the main repository.
  6. Ensure that you add the gov4git:managed label to your PR to allow the Gov4Git bot to parse your request.

Please ensure your code follows the project's coding standards and includes appropriate tests.

More detailed instructions for contributing to the project can be found in README_CONTRIBUTIONS.md

License

This project is licensed under the MIT License. See the LICENSE file for more details.

Contact

For any questions or support, please contact us at support@cubecommons.ca.

Known Issues

A section to document any known issues or bugs.

Please report any new issues in the GitHub issues section.

Changelog

[Version 1.0.0]