Ops
  • Introduction
  • Getting Started
  • Basic Usage
  • Configuration
  • Examples
  • Images
  • Instances
  • Volumes
  • Networking
  • Packages
  • Klibs
  • GPU
  • Hardware Acceleration
  • Clouds
    • Azure
    • AWS
    • Digital Ocean
    • Google Cloud Integration
    • IBM
    • Linode
    • OCI
    • UpCloud
    • Vultr
  • Hypervisors
    • Bhyve
    • Compose
    • Docker
    • Firecracker
    • OpenVMM
    • Hyper-V
    • Onprem
    • OpenStack
    • ProxMox
    • Virtual Box
    • VSphere
    • WorkStation
    • Terraform
    • Kubernetes
    • Bare Metal
    • Integrations
    • Debugging
    • CrossBuilding
    • MacOS
    • Deploy
    • FAQ
    • Benchmarking
  • Tools
    • Visual Studio Code Extension
  • Developer
    • Env Setup
    • Install from Source
Powered by GitBook
On this page
  • Image Operations
  • Create Image
  • List Images
  • Delete Image
  • Instance Operations
  • Create Instance
  • List Instances
  • Start Instance
  • Stop Instance
  • Get Logs for Instance
  • Delete Instance
  • Networking

Was this helpful?

  1. Hypervisors

ProxMox

OPS works perfectly fine with Proxmox.

You'll want to create an API token on the datacenter in the proxmox UI.

You'll also want to ensure you have the correct permissions for that user's token on both the datacenter and storage for the operations you'd like to perform.

The default node name is set to 'pve' but you can reset this through the environment variable of 'NODE_NAME':

export NODE_NAME='somethingelse'
package main

import (
  "fmt"
  "net/http"
)

func main() {
  fmt.Println("hello world!")

  http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
    fmt.Fprintf(w, "Welcome to my website!")
  })

  fs := http.FileServer(http.Dir("static/"))
  http.Handle("/static/", http.StripPrefix("/static/", fs))

  http.ListenAndServe("0.0.0.0:8080", nil)
}

Image Operations

Create Image

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"
ops image create g -t proxmox -c config.json

List Images

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"

ops image list -t proxmox

Delete Image

Instance Operations

Create Instance

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"
ops instance create g.img -t proxmox

List Instances

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"
ops instance list -t proxmox

Start Instance

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"
ops instance start 100 -t proxmox

Stop Instance

export API_URL="https://172.16.41.133:8006"
export TOKEN_ID="myuser@pam!tokenid"
export SECRET="some-uuid-goes-here"
ops instance stop 100 -t proxmox

Get Logs for Instance

Delete Instance

Networking

Proxmox has support for assigning multiple nics to the instance. By default DHCP is used but static ip addresses can be set as well. Proxmox is the only target that we support multiple nics for currently.

A config could look like so:

{
  "RunConfig": {
    "Nics": [
      {
        "BridgeName": "vmbr0",
        "IPAddress": "1.2.3.4",
        "IPv6Address": "",
        "Netmask": "",
        "Gateway": "",
      },
      {
        "BridgeName": "vmbr0"
      }
    ]
  }
}

Notes:

If you are running through nested virtualization such as using VMWare Fusion there is a known bug where you need to disable KVM on your instances.

PreviousOpenStackNextVirtual Box

Last updated 2 years ago

Was this helpful?