Development Guide
We use yarn workspaces, please use yarn.

Add .env configuration to services

Add .env file with the following contents:
1
# packages/director/.env
2
EXECUTION_DRIVER="../execution/mongo/driver"
3
SCREENSHOTS_DRIVER="../screenshots/minio.driver"
4
MINIO_ACCESS_KEY='MW32h3gd6HvjBEgTRx'
5
MINIO_SECRET_KEY=t6NgQWUcEyG2AzaDCVkN6sbWcvDCVkN6sGiZ7
6
MINIO_ENDPOINT='storage'
7
MINIO_URL='http://localhost'
8
MINIO_PORT='9000'
9
MINIO_USESSL='false'
10
MINIO_BUCKET=sorry-cypress
11
12
# packages/dashboard/.env
13
GRAPHQL_SCHEMA_URL=http://api.sc.com:4000
Copied!

Override localhost network

Add the following entries to /etc/hosts or an equivalent file on Windows
1
127.0.0.1 storage
2
127.0.0.1 api.sc.com
Copied!

Start minio and mongo background services

1
docker-compose -f ./docker-compose.minio.yml up -d storage mongo createbuckets
Copied!
Make sure that associated services are available on the localhost - e.g. mongo, minio

Start all the services in dev mode

yarn dev
Send new tests to dashboard using this command:
1
CYPRESS_API_URL=http://localhost:1234/ \
2
cy2 run --record --key whatever --parallel --ci-build-id `date +%s`
Copied!

Prevent CI

Add [skip ci] to commit message to skip running CI.

Releasing a new version

We use semver standard.
Every commit to master triggers CI via GH Actions, which builds new docker images, assign tags and pusher the new images to DockerHub.
After pushing a new tagged please go ahead and create a new Github release with a summary and attributions.

Releasing latest tag

Pushing to master automatically created new docker images with latest tags

Releasing tagged version e.g. v1.0.0-beta.4

  1. 1.
    Run yarn release to create a new release.
  2. 2.
    Push to master. Push to master, together with tags git push origin master --tags. Pushing to master will trigger CI that will actually update dockerhub.
Pushing a properly formatted (semver) git tag starts release of dockerhub images tagged accordingly. E.g. v0.5.2 will release dockerhub tags v0, v0.5, v0.5.2.
The script does the following behind the scenes:
  • Update all package.json files (we release all together and do not increase / release individual packages version)
  • Commit with message, e.g. v0.5.2
  • Add git tag, e.g. git tag v0.5.2
Last modified 4mo ago