Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Latest commit

 

History

History
80 lines (49 loc) · 2.47 KB

prerequisites_development_macos.md

File metadata and controls

80 lines (49 loc) · 2.47 KB

Lisk Service Development Dependencies for MacOS

Note that those requirements are needed only if you want to build the project from sources, without support for Docker. This is useful if you are going to develop the project for your own blockchain or you cannot run Docker on your target machine. In other scenarios such as running a stable version of Lisk Service against the mainnet network, it is highly recommended to follow the Docker-based instruction.

Prerequisites

These programs and resources are required to install and run Lisk Service.

Only on M1 Mac

Brew

Install Brew by following the most recent instruction.

If you already have Brew installed, make sure it is working and up-to-date.

brew update
brew doctor

Xcode

Install Xcode essentials coming from Apple.

This package provides the make command.

xcode-select --install

Tip: You can skip this point if you have already installed the full version of XCode.

Redis

  1. Redis is used for caching temporary data.
brew install redis

Note: During this step it is possible to change your port if you wish to have more Redis instances in the future. Remember to adjust the environment variables SERVICE_BROKER and SERVICE_CORE_REDIS accordingly.

MySQL

MySQL 8 is used for storing persistent data.

brew tap homebrew/services
brew install mysql@8
brew services start mysql@8

Node.js

  1. Node.js 18 serves as the underlying engine for code execution. We recommend using NVM to easily manage various Node.js versions locally.

Follow the official documentation to install the most recent version of NVM on macOS. After installing nvm, navigate to the lisk-service repository and use the following commands to install the necessary Node.js version and set it as default:

nvm install
nvm alias default 18
npm i -g yarn

Having Node.js installed makes it possible to install npm packages.

PM2

PM2 manages the node process for Lisk Service and handles log rotation.

npm install -g pm2

Next steps

If you have all dependencies installed properly, you can start the build process.