Workflows

September 26, 2024 ยท View on GitHub

There are some pipelines to make sure everything works fine, here is an idea about them:

Grid Clients

Build

On Pull Request, and Push to development branch: It will do a clean install of node dependencies, cache/restore them to make the process faster, and build the source code using lerna run build --no-private.

Publish

On Release: It will do a clean install of node dependencies, cache/restore them to make the process faster, and build the source code using lerna run build --no-private then publish the latest version to npm. Also it build a docker image for grid client from the released version.

Lint

On Pull Request, and Push to development branch: It will check if the code formatted well using Eslint and Prettier.

Grid Client Tests

Runs daily for the last code and installs dependencies, runs tests and checks if tests passes or not.

Grid Client Nightly

Runs daily on all networks for the relevant release and it will check if the latest version runs without errors.

Playground

Build

On Pull Request, and Push to development branch that has changes in the playground package: It will do a clean install of node dependencies, cache/restore them to make the process faster, and build the source code using yarn build.

Docker

On Release published: It will build and push a new docker image based on project release tag.

We are using VERSION, and NETWORK arguments in this workflow that will be propagated into the builds config, The values of those arguments could be as follows:

NETWORK = "dev" | "qa" | "test" | "main" (default: dev)
VERSION = "release tag or the first 7 chars of commit hash"

CD

On Push to the development branch, this workflow will do the following:

  • clean install of node dependencies
  • cache/restore dependencies
  • build source code
  • copy artifacts to staging.dashboard.dev.grid.tf using SSH
  • deploy to the staging server

NOTE: If any changes are made to the dashboard's dependencies, this workflow must be manually triggered to apply the updates to the dashboard.

Stats

Build

On Pull Request, and Push to development branch that has changes in the stats package: It will do a clean install of node dependencies, cache/restore them to make the process faster, and build the source code using yarn workspace @threefold/stats build.

Docker

On Release published: It will build and push a new docker image based on project release tag.

Threefold UI

Build

On Pull Request, and Push to development branch: It will do a clean install of node dependencies, cache/restore them to make the process faster, and build the source code using lerna run build --no-private.