runtimebootstrap

package
v0.0.14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2026 License: MIT Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package runtimebootstrap owns the Provider-to-Runtime connection input. Providers deliver this document as a private file; only Runtime interprets it.

Index

Constants

View Source
const MaxBytes = 16 * 1024
View Source
const PublicWorkspace = "/workspace"

PublicWorkspace is the workspace path applications and Core use for a hosted Environment. The Runtime maps it to its bound workspace directory.

View Source
const RuntimeWorkspace = "/environment/workspace"

RuntimeWorkspace is the workspace directory of the packaged Runtime layout.

View Source
const SuspendControlFile = "/run/oac/daemon-suspend.json"

SuspendControlFile is where the Runtime daemon publishes its suspend control. Its directory is private to the Runtime user. The Runtime publishes it exactly when the bootstrap sets SuspendControl, and Core's wake command reads it.

View Source
const Version = 4

Variables

View Source
var ErrInvalid = errors.New("invalid Runtime bootstrap input")

Functions

This section is empty.

Types

type Connection

type Connection struct {
	Version        int    `json:"version"`
	CoreURL        string `json:"core_url"`
	DeviceID       string `json:"device_id"`
	Credential     string `json:"credential"`
	EnvironmentID  string `json:"environment_id"`
	Workspace      string `json:"workspace"`
	SuspendControl bool   `json:"suspend_control"`
}

Connection is a current-version launch input, not Runtime's private auth store. CoreURL includes the machine API base path. The provider owns delivery and file permissions; Runtime owns validation and its authentication representation. EnvironmentID and Workspace bind the Runtime to its Environment. SuspendControl is true exactly when the Provider declares checkpoint support.

func Decode

func Decode(raw []byte) (Connection, error)

Decode accepts one exact object. Unknown, duplicate, missing and case-aliased fields reject instead of introducing alternate spellings of this contract.

func (Connection) Marshal

func (c Connection) Marshal() ([]byte, error)

func (Connection) Validate

func (c Connection) Validate() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL