Skip to content

Source based Start Guide

ByoungSeob Kim edited this page Mar 19, 2026 · 7 revisions

CB-Spider Source-based Start Guide

CB-Spider — One unified API to control multiple clouds. This guide shows you how to build CB-Spider from source and start the server.


Prerequisites

This guide is based on a Linux environment (Ubuntu 24.04 LTS recommended).

  • Build Tools: make, gcc, git, snapd
  • Go: 1.23 or later (sudo snap install go --channel=1.23/stable --classic)
  • Swag: for Swagger doc generation (go install github.com/swaggo/swag/cmd/swag@latest)
  • curl / jq: for API verification (sudo apt install -y curl jq)

Step 1: Build from Source

# Install dependencies
sudo apt update && sudo apt install -y make gcc snapd git jq
sudo snap install go --channel=1.23/stable --classic
go install github.com/swaggo/swag/cmd/swag@latest

# Clone and build
git clone https://github.com/cloud-barista/cb-spider.git $HOME/cb-spider
cd $HOME/cb-spider
make

Step 2: Start Server

Open Terminal 1 and run:

vi $HOME/cb-spider/setup.env    # Set SPIDER_USERNAME and SPIDER_PASSWORD
source ./setup.env && source ./develop.env
cd $CBSPIDER_ROOT/bin && ./start.sh

⚠️ You must set both SPIDER_USERNAME and SPIDER_PASSWORD in setup.env. The server will not start without both credentials.

Wait for output:

<CB-Spider> Multi-Cloud Unified Interface Framework >> One-Code, Multi-Cloud
   - AdminWeb: http://localhost:1024/spider/adminweb
   - Swagger UI: http://localhost:1024/spider/api

Server management commands:

./status.sh   # Check status
./stop.sh     # Stop server
./start.sh    # Start again

📖 Server Configuration | Authentication Guide


Step 3: Verify Server

Open Terminal 2 and verify:

curl -sX GET http://localhost:1024/spider/readyz
# List all supported cloud providers
curl -sX GET -u admin:your-password \
  http://localhost:1024/spider/cloudos | jq '.cloudos'

Health check endpoints (/readyz, /healthcheck, /health, /ping) do not require authentication.
All other REST API calls require Basic Auth (e.g. -u admin:your-password).

Output includes: "AWS", "GCP", "AZURE", and more.


Managing the Server

Stop Server

cd $CBSPIDER_ROOT/bin && ./stop.sh

View Logs

tail -f $HOME/cb-spider/log/cblogs.log

Reset Metadata

# Removes all registered clouds/resources
cd $CBSPIDER_ROOT/bin && ./stop.sh && rm -rf ${HOME}/cb-spider/meta_db/*

Troubleshooting

Problem Cause Solution
Server won't start Missing credentials Set SPIDER_USERNAME and SPIDER_PASSWORD in setup.env or as environment variables
Build fails Go version too old Ensure Go 1.23+ (go version)
Port conflict Port 1024 in use sudo lsof -i :1024 then stop the conflicting process

Table of contents




Clone this wiki locally