A platform for easily building and running distributed, unstoppable apps.
The main components (packages) of the Mainframe Platform are as follows:
daemon: a background daemon process that communicates with decentralized services
launcher: the Mainframe application installing, launching and running sandboxed apps
In addition, there are several auxiliary packages:
app-manifest: an utility library for app manifests creation an validation
app-permissions: an utility library for distributed app permissions
cli: a command-line interface to communicate with the daemon
client: a library used by the CLI & launcher to communicate with the daemon
config: shared configuration utilities used by several packages
data-types: shared data primitives
toolbox: a set of functions that both the launcher and the cli use
In order to make it easier to share code among packages, this project uses lerna. Whenever code changes, it's expected that you run
yarn run build from the root of the project directory, and it will kick off the necessary
lerna build processes in the package folders.
This project is in alpha, lots of breaking changes are to be expected between releases. It is using libraries and services that are themselves still in early stages of development. The cryptography and overall security have not been audited, no guarantees should be expected from this project at this stage.
sudo apt install -y libudev-dev libtool libusb-1.0-0-dev build-essential
npm install --global --production windows-build-tools`
Each package contains (or will contain) a readme with further information pertaining to setup. A shortcut guide is as follows:
In the root of the project, install node dependencies:
yarn install yarn build
Next, a local environment must be created. An environment contains references to all the vaults created and stores the downloaded application contents. To create a new environment, run the following command:
Or on Windows
This first environment should be created with the
development type and set as default environment.
The newly created environment then needs to be configured using the CLI:
packages/cli/bin/run daemon:setup --bin-path=./packages/daemon/bin/run
Or on Windows
"packages/cli/bin/run.cmd" daemon:setup --bin-path="packages/daemon/bin/run.cmd"
Building the code
Whenever code changes in any other package than the launcher, you should build everything (via
yarn run build
Now, in one terminal tab, run the daemon:
./packages/cli/bin/run daemon:start -e <your_env_name>
Or on Windows
"packages/cli/bin/run.cmd" daemon:start -e <your_env_name>
Then, in another tab, run the launcher:
MAINFRAME_ENV=<your_env_name> cd packages/launcher && yarn deps:build && yarn run dev
Building Mainframe Apps
Information and guides for building MainframeOS apps can be found in our developer docs.