Skip to content

phpcws/server_bee-backend

 
 

Repository files navigation

Language : 🇺🇸 English | 🇨🇳 简体中文

server_bee-backend

Backend for iOS application named ServerBee

ServerBee - Monitor and manage all your desktop systems | Product Hunt

GitHub release (latest by date) GitHub Workflow Status GitHub last commit

Overview

  • module web provide data from server
  • module deploy provide AutoLaunchAutoUpdateDownloadWebModule

Features

  • CPU load
  • load average
  • memory usage
  • uptime / boot time
  • filesystem mounts (and disk usage)
  • disk I/O statistics
  • network interfaces
  • network traffic statistics
  • process list
  • detail process
  • kill process
  • sub process

Dashboard for web

overview process disk&network settings

Interactive install

interactive install

How to use

Installation

Docker

The installation tutorial is located in the documentation 👉 Docker

docker run -d \
  -v /proc:/proc \
  --privileged=true \
  --restart unless-stopped \
  --network=host \
  --name=serverbee-web \
  zingerbee/serverbee-web -p 9527

Linux、macOS

👇 The installation tutorial is located in the documentation

From Release Page get the latest version download address

# (optional)
mkdir serverbee
cd serverbee

# tips: download the corresponding version according to the system architecture
# macOS
wget https://github.com/ZingerLittleBee/server_bee-backend/releases/download/v1.2.6/serverbee-deploy-x86_64-apple-darwin.zip
unzip serverbee-deploy-x86_64-apple-darwin.zip

# Linux
wget https://github.com/ZingerLittleBee/server_bee-backend/releases/download/v1.2.6/serverbee-deploy-x86_64-unknown-linux-musl.zip
unzip serverbee-deploy-x86_64-unknown-linux-musl.zip

# default port is 9527
./serverbee-deploy

Windows

The installation tutorial is located in the documentation 👉 Windows

  1. Download the latest version serverbee-deploy-x86_64-pc-windows-gnu.zip from Release Page

  2. unzip serverbee-deploy-x86_64-pc-windows-gnu.zip

  3. double-click to run serverbee-deploy.exe

More settings

Allow downloading of pre-release versions

By default, only stable versions will be downloaded

If you want to download pre-release versions, you can use the --pre-release parameter

./serverbee-deploy --pre-release

Interactive install

./serverbee-deploy -i

Use custom port

./serverbee-deploy -p 8081
# for unused deploy module
./serverbee-web -p 8081

Enable auto launch (default is enable)

./serverbee-deploy -a true

Disable auto launch

./serverbee-deploy -a false

Examples

./serverbee-deploy -p 8081 -a false -u true

Configuration related API

The following interfaces can only be accessed from localhost

View all configurations

curl http://localhost:9527/local/config

The response is as follows:

{
    "success": true,
    "data": {
        "web_server": {
            "port": 9527
        },
        "server": {
            "token": "token",
            "host": "serverhub.app",
            "disable_ssl": false
        },
        "app": {
            "token": "token"
        }
    }
}

View web_server config

Related configuration of web server, including port number

curl http://localhost:9527/local/config/web_server

The response is as follows:

{
  "success": true,
  "data": {
    "port": 9527
  }
}

Update the web_server configuration

curl -X POST -H "Content-Type: application/json" -d '{"port": 9527}' http://127.0.0.1:9527/local/config/web_server

The response is as follows:

{
  "success": true
}

View app config

App-related configurations, including communication keys

curl http://localhost:9527/local/config/app

The response is as follows:

{
  "success": true,
  "data": {
    "token": "token"
  }
}

Update app config

curl -X POST -H "Content-Type: application/json" -d '{"token": "newToken"}' http://localhost:9527/local/config/app

The response is as follows:

{
  "success": true
}

View server config

Server related configuration, including communication key, server address, whether to disable SSL

curl http://localhost:9527/local/config/server

The response is as follows:

{
  "success": true,
  "data": {
    "token": "token",
    "host": "serverhub.app",
    "disable_ssl": false
  }
}

Update server config

curl -X POST -H "Content-Type: application/json" -d '{"token": "newToken", "host": "serverhub.app", "disable_ssl": false}' http://127.0.0.1:9527/local/config/server

The response is as follows:

{
  "success": true
}

Compile from source

1. Build the front-end source code

Need to install nodejs, pnpm

pnpm -C view install
pnpm -C view build

The build product is in the view/dist directory

2. Build web, deploy module source code

Need to install rust

cargo build --release

and then you can find the binary file in target/release

Found an issue or have a proposal

Create an issue

Release Notes

SEE CHANGELOG

Read More

Office Website

Document

App Store

About

Backend for ServerBee

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 58.3%
  • Rust 38.3%
  • JavaScript 2.6%
  • Other 0.8%