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

Getting Started

Vlad White edited this page Jun 14, 2023 · 1 revision

Getting Started

To get started with the Ecko Backend, follow these steps:

Prerequisites

  • Node.js 20 (using NVM)
  • config.json file

Installation

  1. Install NVM (Node Version Manager) by following the instructions for your operating system:

    • Windows: Visit the NVM for Windows repository at https://github.com/coreybutler/nvm-windows and follow the installation guide.
    • Linux/macOS: Open your terminal and run the following command:
      curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash
  2. Close and reopen your terminal to start using NVM.

  3. Install Node.js 20 by running the following command:

    nvm install 20
  4. Verify that Node.js 20 is installed:

    node --version

Clone the Repository

  1. Clone the repository:
    git clone https://github.com/VladWhiteK/ecko-backend.git
  2. Navigate to the project directory:
    cd ecko-backend

Install Dependencies

  1. Install NPM packages:
    npm install

Configuration

  1. Rename the config.example.json file to config.json and update the necessary configurations according to your environment.

Usage

  1. Start the server as dev:
    npm run dev

Note: Running the server in with debug mode is recommended for the development branch. You can enable it from the config.json

...
"debug": true,
...
  1. Complete the first-time setup by providing the following data:

    Server Name: <Enter the name of your server>
    Server Location: <Enter the location of your server>
    Secret Length: <Enter the desired secret length for verifying the apiKey result (at least 64 characters and less than 256 characters)>
    Secret Phrase: <Enter a secret phrase for verifying the apiKey result (at least 16 characters)>

    Example GIF

  2. Access the backend API at http://localhost:8080.

Please note that the instructions assume you have NVM already installed. If you don't have NVM, you can follow the provided instructions to install it before proceeding with the Node.js 20 installation.

Additionally, make sure to have the config.json file in your project directory and rename the provided config.example.json file to config.json for proper configuration.

Clone this wiki locally