Skip to content

DO-Solutions/DI-grabber

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DigitalOcean Dedicated Inference Grabber

A Node.js application that automatically provisions DigitalOcean Dedicated Inference deployments when GPU capacity becomes available. It periodically checks available Dedicated Inference capacity and creates deployments up to your desired global count.

Features

  • Automatic provisioning for Dedicated Inference
  • Periodic polling for current capacity
  • Desired count management (global across configured regions)
  • Multi-region failover by checking/trying regions in order
  • Webhook notifications for provisioning events
  • Docker support for worker-style deployment

Prerequisites

  • DigitalOcean API token with Dedicated Inference permissions
  • Node.js 22+ (for direct execution)
  • Existing VPC UUID in your target region(s)

Usage

With Node.js

  1. Install dependencies:
npm install
  1. Run:
DO_API_TOKEN="your-do-token" npm start -- \
  --region="tor1,nyc2" \
  --model_slug="mistral/mistral-7b-instruct-v3" \
  --accelerator_slug="gpu-mi300x1-192gb" \
  --vpc_uuid="your-vpc-uuid" \
  --desired_count=1 \
  --accelerator_scale=1 \
  --accelerator_type="prefill_decode" \
  --enable_public_endpoint=true \
  --check_interval_seconds=30 \
  --name_prefix="my-di"

Optional flags:

  • --hugging_face_token (for gated Hugging Face models)
  • --webhook_url (notifications, including Slack incoming webhook support)

With Docker

docker build -t di-grabber .

docker run -d \
  -e DO_API_TOKEN="your-do-token" \
  -e REGION="tor1,nyc2" \
  -e MODEL_SLUG="mistral/mistral-7b-instruct-v3" \
  -e ACCELERATOR_SLUG="gpu-mi300x1-192gb" \
  -e VPC_UUID="your-vpc-uuid" \
  -e DESIRED_COUNT="1" \
  -e ACCELERATOR_SCALE="1" \
  -e ACCELERATOR_TYPE="prefill_decode" \
  -e ENABLE_PUBLIC_ENDPOINT="true" \
  -e CHECK_INTERVAL_SECONDS="30" \
  -e NAME_PREFIX="my-di" \
  -e WEBHOOK_URL="https://webhook.site/<id>" \
  --name do-di-grabber \
  di-grabber

How it works

Every polling cycle, the application:

  1. Lists existing Dedicated Inference deployments in the configured regions
  2. Counts deployments it manages (name prefix + model + accelerator match)
  3. Checks /v2/dedicated-inferences/sizes for currently enabled region/GPU capacity
  4. Attempts to create additional deployments until desired_count is met

This gives behavior similar to slug-grabber, but for Dedicated Inference capacity.

Configuration reference

Parameter Description
DO_API_TOKEN DigitalOcean API token (required)
region / REGION Comma-separated regions to check in order (required)
model_slug / MODEL_SLUG Dedicated Inference model slug (required)
accelerator_slug / ACCELERATOR_SLUG GPU slug to request (required)
vpc_uuid / VPC_UUID VPC UUID for deployment (required)
desired_count / DESIRED_COUNT Global desired managed deployment count (required)
accelerator_scale / ACCELERATOR_SCALE Accelerator scale per deployment (default: 1)
accelerator_type / ACCELERATOR_TYPE Accelerator type (default: prefill_decode)
enable_public_endpoint / ENABLE_PUBLIC_ENDPOINT Enable public endpoint (default: true)
hugging_face_token / HUGGING_FACE_TOKEN Optional Hugging Face token for gated models
check_interval_seconds / CHECK_INTERVAL_SECONDS Polling interval in seconds (default: 30)
webhook_url / WEBHOOK_URL Optional webhook notification URL
name_prefix / NAME_PREFIX Name prefix for managed deployments (default: di-grabber)

API references

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors