runner

package
v1.0.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2026 License: Apache-2.0 Imports: 22 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 runner runs sessions as the host of a registered Beekeeper runner.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadCredential

func ReadCredential(path string) (string, error)

ReadCredential reads a single host-owned credential file.

func Run

func Run(ctx context.Context, cfg Config, exec executor.Executor, log *slog.Logger) error

Run holds one stream until ctx ends. Sessions belong to the process and keep reporting across stream reconnects and coordinator handoffs.

Types

type Config

type Config struct {
	ServerURL      string            `json:"serverURL"`
	KeyFile        string            `json:"keyFile"`
	HostTokenFile  string            `json:"hostTokenFile"`
	ReadingsFile   string            `json:"readingsFile"`
	ExecutorConfig json.RawMessage   `json:"executorConfig,omitempty"`
	ContextFiles   map[string]string `json:"contextFiles,omitempty"`
	Git            Git               `json:"git,omitempty"`
}

Config names the coordinator and files owned by this runner's host.

func Load

func Load(path string) (Config, error)

func (Config) ResolveContext

func (c Config) ResolveContext(_ context.Context, ref string) (json.RawMessage, error)

ResolveContext reads only a bundle explicitly mapped by the host.

type Git

type Git struct {
	// Access is none (the default), read or write.
	Access executor.GitAccess `json:"access,omitempty"`
}

Git bounds the host's git power in this runner's sessions.

type Readings

type Readings struct {
	Pressure *v1alpha1.Pressure `json:"pressure"`
	Usage    []api.UsageReport  `json:"usage,omitempty"`
}

Readings is the latest snapshot published by the host's pressure and subscription sources. Replacing it wakes an otherwise idle runner.

Jump to

Keyboard shortcuts

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