deploy

package
v0.1.9 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2026 License: Apache-2.0 Imports: 7 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 deploy bridges Conductor's connection config into the environment of the language-specific (Python/TypeScript) deploy subprocess, and abstracts subprocess execution behind an interface. The env-var names are named constants — never inline literals — and the server URL/token come from config, not hardcoded values.

Index

Constants

View Source
const (
	EnvServerURL = "AGENTSPAN_SERVER_URL"
	EnvAuthToken = "AGENTSPAN_AUTH_TOKEN"
	EnvAutoStart = "AGENTSPAN_AUTO_START_SERVER"
)

Subprocess environment variables the AgentSpan SDKs read.

Variables

This section is empty.

Functions

This section is empty.

Types

type EnvBuilder

type EnvBuilder struct {
	BaseURL string
	Tokens  TokenSource // nil => anonymous
	BaseEnv []string    // typically os.Environ(); injected for testability
}

EnvBuilder builds the subprocess environment from Conductor's connection config: it strips inherited AGENTSPAN_* vars, sets the server URL, disables the SDK's embedded-server auto-start, and forwards the resolved JWT as AGENTSPAN_AUTH_TOKEN.

Cross-component note (design §7): forwarding the JWT — rather than a legacy API key — requires the Python/TypeScript SDKs to authenticate with AGENTSPAN_AUTH_TOKEN. This is the single cross-component dependency of the port.

func (EnvBuilder) Build

func (b EnvBuilder) Build(ctx context.Context) ([]string, error)

Build returns the child-process environment.

type Runner

type Runner interface {
	Run(ctx context.Context, env []string, name string, args ...string) ([]byte, error)
}

Runner executes a language subprocess and captures stdout, forwarding stderr to the user. It is an interface so the deploy command can be tested without spawning processes.

func NewRunner

func NewRunner() Runner

NewRunner returns the default subprocess Runner.

type TokenSource

type TokenSource interface {
	Token(ctx context.Context) (string, error)
}

TokenSource yields the JWT to forward to the subprocess. It matches transport.TokenProvider structurally, so the shared transport's provider can be passed directly.

Jump to

Keyboard shortcuts

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