Skip to content
/ portal Public

Service deployed on VM instances to launch browsers

License

Notifications You must be signed in to change notification settings

crybapp/portal

Repository files navigation

Cryb OSS

@cryb/portal - VM instance

GitHub contributors License Patreon Donate Chat on Discord

Docs

Info

@cryb/portal is the instance deployed onto VM machines to act as the 'Virtual browser'.

@cryb/portal connect to @cryb/portals over WS to send and recieve updates like controller events and health updates.

Status

@cryb/portal has been actively developed internally since September 2019, and is now open source as of October 2019.

Codebase

The codebase for @cryb/portal is written in JavaScript, utilising TypeScript and Node.js.

Code Style

We ask that you follow our code style guidelines when contributing to this repository.

We use TSLint in order to lint our code. Run yarn lint before committing any code to ensure it's clean.

Note: while we have most rules covered in our tslint.json config, it's good practice to familarise yourself with our code style guidelines

Folder Structure

cryb/portal/
└──┐ src # The core source code
   ├── browser # Class used to start services on the VM, such as Chromium and ffmpeg
   ├── clients # Our Express.js setup and WebSocket setup
   ├── config # Services such as queue management, etc
   └── utils # Helper methods

First time setup

First, clone the @cryb/portal repository locally:

git clone https://github.com/crybapp/portal.git

Installation

The following services need to be installed for @cryb/portal to function:

  • @cryb/portals
  • @cryb/aperture or Janus WebRTC Server

We recommend that you run the following services alongside @cryb/portal, but it's not required.

  • @cryb/api
  • @cryb/web
  • @cryb/aperture or Janus WebRTC Server

You also need to install the required dependencies by running yarn

Ensure that .env.example is either copied and renamed to .env, or is simply renamed to .env.

In this file, you'll need some values. Documentation is available in the .env.example file.

Running the app locally

Background Services

Make sure @cryb/portals is running on port 5000 and that you have setup @cryb/aperture or Janus WebRTC Server.

Starting @cryb/portal

We recommend that you use a service like Docker to start an instance of @cryb/portal.

To run @cryb/portal in development mode on Docker, run yarn docker:dev.

Use yarn docker:build to build an image for deployment in production.

Questions / Issues

If you have an issues with @cryb/portal, please either open a GitHub issue, contact a maintainer or join the Cryb Discord Server and ask in #tech-support.

License

FOSSA Status

About

Service deployed on VM instances to launch browsers

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published