package version

import "github.com/open-policy-agent/opa/internal/version"

Package version implements helper functions for the stored version.

Index

Variables

var UserAgent = fmt.Sprintf("Open Policy Agent/%s (%s, %s)", version.Version, runtime.GOOS, runtime.GOARCH)

UserAgent defines the current OPA instances User-Agent default header value.

Functions

func Write

func Write(ctx context.Context, store storage.Store, txn storage.Transaction) error

Write the build version information into storage. This makes the version information available to the REPL and the HTTP server.

Source Files

version.go

Version
v1.5.1 (latest)
Published
Jun 4, 2025
Platform
js/wasm
Imports
5 packages
Last checked
1 day ago

Tools for package owners.