Skip to main content

VM on Golem Discovery Service - Central hub for provider discovery and resource matching

Project description

Golem VM Discovery Server

The Discovery Server acts as the central hub for the Golem Network, enabling requestors to find providers with matching resources.

Installation

pip install golem-vm-discovery

Running the Server

The Discovery Server comes with sensible defaults and can be run immediately after installation:

golem-discovery

The server will start with the following default configuration:

  • Listen on all interfaces (0.0.0.0) port 9001
  • Store data in SQLite at ~/.golem/discovery/discovery.db
  • Rate limit to 100 requests per minute per IP
  • Clean up expired advertisements every minute
  • Require provider advertisement refresh every 5 minutes

Configuration

All settings have built-in defaults and can be optionally overridden using environment variables:

# Override only what you need:

# Change the port
GOLEM_DISCOVERY_PORT=8000

# Enable debug mode
GOLEM_DISCOVERY_DEBUG=true

# Use a different database location
GOLEM_DISCOVERY_DATABASE_DIR="/custom/path"

Default Settings

Setting Default Environment Variable Description
Host 0.0.0.0 GOLEM_DISCOVERY_HOST Listen interface
Port 9001 GOLEM_DISCOVERY_PORT Listen port
Debug false GOLEM_DISCOVERY_DEBUG Enable debug mode
Database Dir ~/.golem/discovery GOLEM_DISCOVERY_DATABASE_DIR Database directory
Database Name discovery.db GOLEM_DISCOVERY_DATABASE_NAME Database filename
Rate Limit 100 GOLEM_DISCOVERY_RATE_LIMIT_PER_MINUTE Requests per minute per IP
Ad Expiry 5 GOLEM_DISCOVERY_ADVERTISEMENT_EXPIRY_MINUTES Minutes until ads expire
Cleanup Interval 60 GOLEM_DISCOVERY_CLEANUP_INTERVAL_SECONDS Seconds between cleanups

API Endpoints

  • GET /health - Health check endpoint
  • GET /api/v1/advertisements - List available providers
  • POST /api/v1/advertisements - Register a provider

Environment Variables

All settings can be configured through environment variables:

Variable Description Default
GOLEM_DISCOVERY_HOST Server host 0.0.0.0
GOLEM_DISCOVERY_PORT Server port 9001
GOLEM_DISCOVERY_DEBUG Enable debug mode false
GOLEM_DISCOVERY_DATABASE_DIR Database directory ~/.golem/discovery
GOLEM_DISCOVERY_DATABASE_NAME Database filename discovery.db
GOLEM_DISCOVERY_RATE_LIMIT_PER_MINUTE Rate limit per IP 100
GOLEM_DISCOVERY_ADVERTISEMENT_EXPIRY_MINUTES Advertisement TTL 5
GOLEM_DISCOVERY_CLEANUP_INTERVAL_SECONDS Cleanup interval 60

Development

To run the server in development mode:

GOLEM_DISCOVERY_DEBUG=true golem-discovery

This will enable auto-reload on code changes and more detailed logging.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

golem_vm_discovery-0.1.23.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

golem_vm_discovery-0.1.23-py3-none-any.whl (11.3 kB view details)

Uploaded Python 3

File details

Details for the file golem_vm_discovery-0.1.23.tar.gz.

File metadata

  • Download URL: golem_vm_discovery-0.1.23.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.9.21 Linux/6.8.0-1021-azure

File hashes

Hashes for golem_vm_discovery-0.1.23.tar.gz
Algorithm Hash digest
SHA256 d09789ebabbb479f476e5167b24be27f20f94961e244c6e9fb098cf5a6039569
MD5 419516337b6d81c68f7283b5bab2e525
BLAKE2b-256 c8bcb15981b4c0b381f83580a0603214fcc1b12675e6023cdcadd16df49f0261

See more details on using hashes here.

File details

Details for the file golem_vm_discovery-0.1.23-py3-none-any.whl.

File metadata

  • Download URL: golem_vm_discovery-0.1.23-py3-none-any.whl
  • Upload date:
  • Size: 11.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.9.21 Linux/6.8.0-1021-azure

File hashes

Hashes for golem_vm_discovery-0.1.23-py3-none-any.whl
Algorithm Hash digest
SHA256 720188b1f8b248b34ad6ac7ce5a2baa456fca6dd01b707e7e0aea4656c53d5cc
MD5 274285f124ba47f50319be360a254d9b
BLAKE2b-256 aa94d7290a80cf20fda2ba7f5aa17d5a17761b1c4869372ee8bffa8b4c860454

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page