/marketplace

Contributions marketplace backend services

Primary LanguageTypeScriptMIT LicenseMIT

Marketplace

Marketplace monorepo

⚠️ WARNING! ⚠️

This repo contains highly experimental code. Expect rapid iteration.

Global architecture

Global architecture

Github indexing

Github indexing

Data Diagram

Data Diagram

Development

🎗️ Prerequisites

Make sure Rust 1.70 is used:

rustup default 1.70

Usage

First, prepare your local environment by configuring your .env. Copy the .env.e2e file and replace the values tagged with REPLACE_AT_INSTALLATION according to your personal accounts.

cp .env.e2e .env

To run the whole stack:

yarn e2e:env:up

To execute e2e tests:

yarn e2e:run

To reset the whole stack (including clearing DB data):

yarn e2e:env:reset

To run / shutdown the backend (including infra):

yarn backend:up
yarn backend:down

Many other commands are available in the package.json file. Please check it.

📚 Storybook

To view components in isolation using Storybook

yarn --cwd ./frontend storybook

🕸 GraphQL codegen

To generate types from the Hasura GraphQL schema during development

yarn --cwd ./frontend generate

📚 Update list of supported languages

You'll need yq and jq

brew install yq jq

To update the list of supported languages (taken from Github) used to autocomplete technologies in the profile edit form

yarn --cwd ./frontend update-languages

Migrate database

  • To create a new migration, start running
diesel migration generate <your-migration-name>
  • Edit the generated files with your SQL code for up.sql and down.sql
  • Test your migration up and down by running
diesel migration run
diesel migration revert
diesel migration run
  • The file schema.rs should be then automatically updated

Security

To activate the GitGuardian pre-commit, you need first to connect to GitGuardian :

Then, install GitGuardian pre-commit hook to check if some secrets are leaked inside the code base :

run pre-commit install

Monitoring

We use Datadog as a monitoring solution. Datadog agents and drains are configured using Terraform.

📄 License

marketplace is released under MIT.