flightctl

module
v1.3.0-rc2 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2026 License: Apache-2.0

README

Flight Control

Declarative management of fleets of edge devices and their workloads.

Lint Unit Tests Integration Tests OpenAPI Lint Go version Quay.io

User DocumentationDeveloper DocumentationContributing


Overview

Flight Control aims to provide simple, scalable, and secure management of edge devices and applications. Users declare the operating system version, host configuration, and set of applications they want to run on an individual device or a whole fleet of devices, and Flight Control rolls out the target configuration to devices. A device agent running on each device automatically applies changes and reports progress and health status back.

Flight Control is designed for modern, container-centric toolchains and operational best practices. It works best on image-based Linux operating systems running bootc or ostree, with container workloads running on Podman/Docker or Kubernetes (MicroShift). APIs are Kubernetes-like, so they instantly feel familiar to Kubernetes users and allow reuse of existing tools and toolchains.

Demo

Watch the demo

Architecture

Flight Control high-level architecture

The Flight Control Service exposes two API endpoints — a user-facing HTTPS endpoint (authenticated via JWT from an external OIDC provider) and an agent-facing mTLS endpoint (authenticated via device certificates bootstrapped from hardware root-of-trust). The Flight Control Agent runs on each managed device, calls home, polls for target configuration, applies updates autonomously, and reports status back.

Key Features

  • Declarative / GitOps API — Kubernetes-like API lets you store fleet and device configuration in Git; ResourceSync polls repositories or receives webhooks.
  • Fleet management — Define a device template and rollout policy once; it automatically applies to all current and future member devices. Supports disruption budgets and staged rollouts.
  • Secure device lifecycle — Friction-free enrollment, automatic certificate rotation, TPM-backed attestation, and decommissioning.
  • OS image updates — OTA updates via bootc or rpm-ostree with transactional rollback (Greenboot integration). The agent downloads assets before applying, so updates survive network interruptions.
  • Container and VM workloads — Podman containers (docker-compose, Quadlets), MicroShift/Kubernetes workloads (Helm, kustomize).
  • OS image buildingImageBuild produces bootc container images with the embedded agent; ImageExport exports to qcow2, vmdk, or iso.
  • Remote console — Live console sessions to managed devices directly from the CLI or UI.
  • Pluggable auth and RBAC — Keycloak, generic OIDC, OpenShift OAuth, AAP, PAM; SpiceDB or Kubernetes RBAC for authorization.
  • Observability — Prometheus metrics, Alertmanager integration, OpenTelemetry telemetry gateway, and a CVE view at device and fleet level.
  • Web UI — Browser-based dashboard for device inventory, fleet management, and ClickOps workflows.

Quick Start

The fastest path to a running local environment uses kind (Kubernetes in Docker):

# 1. Build all binaries
make build

# 2. Deploy to a local kind cluster (builds containers, installs Helm chart)
make deploy

# 3. Authenticate with the CLI
# The server URL is written to ~/.flightctl/client.yaml by make deploy
bin/flightctl login $(cat ~/.flightctl/client.yaml | grep server | awk '{print $2}') --web --certificate-authority ~/.flightctl/certs/ca.crt

# 4. Apply an example fleet and verify
bin/flightctl apply -f examples/fleet.yaml
bin/flightctl get fleets
bin/flightctl get devices

For a Linux-native setup using systemd + Podman (no Kubernetes required):

make deploy-quadlets

Certificates and client configuration are written to ~/.flightctl/.

Prerequisites

Tool Minimum version Notes
go 1.25 Required to build
make any Build orchestration
podman any Container builds and integration tests
openssl / openssl-devel any TLS certificate generation
buildah any Container image builds
pam-devel any PAM issuer build
kind ≥ 0.31.0 Local Kubernetes cluster (make deploy)
kubectl any Kubernetes interaction

For agent development, enable the Podman socket:

systemctl --user enable --now podman.socket

Build & Test

Make target Description
make build Build all binaries
make generate Re-generate API client code and mocks
make generate-proto Re-generate gRPC protobuf bindings
make unit-test Run unit tests (requires gotestsum)
make integration-test Run integration tests (requires Podman; starts Postgres, Redis, Alertmanager via testcontainers)
make e2e-test Run end-to-end tests against a kind cluster
make lint Run golangci-lint (installs automatically)
make lint-openapi Lint OpenAPI specs
make lint-docs Lint user documentation (markdownlint)
make tidy Tidy go.mod files
make clean Remove containers and volumes
make clean-all Full cleanup including bin/

Install test tooling:

go install gotest.tools/gotestsum@latest
go install go.uber.org/mock/mockgen@v0.4.0

Integration tests accept these environment variables: INTEGRATION_PROCS=N for parallelism, TEST_DIR=./test/integration/store for a specific suite, INTEGRATION_GINKGO_FOCUS="pattern" for individual tests.

Deployment Options

Method Command / Notes
Kind (local dev) make deploy — builds containers, deploys Helm chart to a kind cluster
Quadlets (Linux/systemd) make deploy-quadlets or install the flightctl-services RPM and systemctl start flightctl.target
Kubernetes / OpenShift helm install my-flightctl oci://quay.io/flightctl/charts/flightctl — requires Gateway API and cert-manager
MicroShift Same Helm chart; see installing on Kubernetes
Disconnected / air-gapped See disconnected OpenShift install guide
Linux RPM sudo dnf config-manager --add-repo https://rpm.flightctl.io/flightctl-epel.repo && sudo dnf install -y flightctl-services

Pre-built container images are published to quay.io/flightctl/ for each release. Helm charts are published to oci://quay.io/flightctl/charts/flightctl.

CLI Reference

The flightctl CLI communicates with the Flight Control Service to manage resources.

Command Description
login Authenticate (OIDC web flow, token, or PAM)
get List or describe resources (devices, fleets, enrollmentrequests, …)
apply Create or update resources from a YAML file
edit Open a resource in your editor for interactive editing
delete Delete resources
approve / deny Approve or deny enrollment requests
decommission Decommission a device
console Open a remote console session to a device
certificate Manage certificates
logs Stream logs from an ImageBuild or ImageExport
download Download an ImageExport artifact
cancel Cancel a running operation
version Print CLI and server versions
completion Generate shell completion scripts

Output formats: table (default), json, yaml, wide. Configuration defaults to ~/.config/flightctl/client.yaml.

For the full reference see CLI documentation.

Core Concepts

Concept Description
Device A (real or virtual) machine together with its OS and application workloads.
Fleet A group of devices governed by a common device template and management policies.
Device Template A template for device specifications that controls configuration drift across a fleet.
Labels Key-value pairs for organizing devices (e.g. region=emea, site=factory-berlin).
ResourceSync Polls a Git repository (or receives a webhook) and syncs Fleet/Device resources from it.
Agent The Flight Control Agent process that runs on each managed device, enrolls it, applies updates, and reports status.

See Introduction for a full explanation of all concepts.

Documentation

Area Link
User documentation (install, configure, use) docs/user/README.md
Developer documentation (build, run, architecture) docs/developer/README.md
Installing on Kubernetes / OpenShift docs/user/installing/
Installing the agent docs/user/installing/installing-agent.md
API resources reference docs/user/references/api-resources.md
Architecture docs/developer/architecture/
Enhancement proposals (FEPs) docs/developer/enhancements/

Contributing

Contributions are welcome! Please read CONTRIBUTING.md for the full workflow and then docs/developer/README.md for build and development setup.

Key rules:

  • Signed commits are required (GPG or SSH).
  • Commit message prefix — use a Jira issue key (EDM-1234: description) or NO-ISSUE: for trivial changes.
  • Before pushing — run make unit-test, make integration-test, and make lint. Fix any failures.
  • API changes — edit OpenAPI YAML and hand-maintained types, then run make generate. Do not edit *.gen.go by hand.

For larger changes, consider opening a Flight Control Enhancement Proposal (FEP) under docs/developer/enhancements/ before implementing.

License

Flight Control is licensed under the Apache License 2.0.

Directories

Path Synopsis
api
agent/v1beta1
Package v1beta1 provides primitives to interact with the openapi HTTP API.
Package v1beta1 provides primitives to interact with the openapi HTTP API.
core/v1alpha1
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
core/v1beta1
Package v1beta1 provides primitives to interact with the openapi HTTP API.
Package v1beta1 provides primitives to interact with the openapi HTTP API.
grpc/v1
Package grpc_v1 is a generated GoMock package.
Package grpc_v1 is a generated GoMock package.
imagebuilder/v1alpha1
Package imagebuilder provides the types and client for the Flight Control Image Builder API.
Package imagebuilder provides the types and client for the Flight Control Image Builder API.
pam-issuer/v1beta1
Package pam_issuer provides primitives to interact with the PAM Issuer openapi HTTP API.
Package pam_issuer provides primitives to interact with the PAM Issuer openapi HTTP API.
cmd
aux-service command
devicesimulator command
flightctl command
flightctl-agent command
flightctl-alertmanager-proxy command
flightctl-alertmanager-proxy is a lightweight reverse proxy for Alertmanager that integrates with FlightControl's existing authentication and authorization system.
flightctl-alertmanager-proxy is a lightweight reverse proxy for Alertmanager that integrates with FlightControl's existing authentication and authorization system.
flightctl-api command
deploy
internal
agent/client
Package client is a generated GoMock package.
Package client is a generated GoMock package.
agent/device/applications
Package applications is a generated GoMock package.
Package applications is a generated GoMock package.
agent/device/applications/console
Package console is a generated GoMock package.
Package console is a generated GoMock package.
agent/device/applications/helm
Package helm provides utilities for working with Helm charts and rendered manifests.
Package helm provides utilities for working with Helm charts and rendered manifests.
agent/device/applications/lifecycle
Package lifecycle is a generated GoMock package.
Package lifecycle is a generated GoMock package.
agent/device/applications/provider
Package provider is a generated GoMock package.
Package provider is a generated GoMock package.
agent/device/console
Package console is a generated GoMock package.
Package console is a generated GoMock package.
agent/device/dependency
Package dependency is a generated GoMock package.
Package dependency is a generated GoMock package.
agent/device/fileio
Package fileio is a generated GoMock package.
Package fileio is a generated GoMock package.
agent/device/hook
Package hook is a generated GoMock package.
Package hook is a generated GoMock package.
agent/device/image_pruning
Package imagepruning is a generated GoMock package.
Package imagepruning is a generated GoMock package.
agent/device/lifecycle
Package lifecycle is a generated GoMock package.
Package lifecycle is a generated GoMock package.
agent/device/os
Package os is a generated GoMock package.
Package os is a generated GoMock package.
agent/device/policy
Package policy is a generated GoMock package.
Package policy is a generated GoMock package.
agent/device/resource
Package resource is a generated GoMock package.
Package resource is a generated GoMock package.
agent/device/spec
Package spec is a generated GoMock package.
Package spec is a generated GoMock package.
agent/device/spec/audit
Package audit provides structured audit logging for device spec transitions.
Package audit provides structured audit logging for device spec transitions.
agent/device/status
Package status is a generated GoMock package.
Package status is a generated GoMock package.
agent/device/systemd
Package systemd is a generated GoMock package.
Package systemd is a generated GoMock package.
agent/device/systeminfo
Package systeminfo is a generated GoMock package.
Package systeminfo is a generated GoMock package.
agent/health
Package health provides health check functionality for the flightctl-agent.
Package health provides health check functionality for the flightctl-agent.
agent/identity
Package identity is a generated GoMock package.
Package identity is a generated GoMock package.
api/client
Package client provides primitives to interact with the openapi HTTP API.
Package client provides primitives to interact with the openapi HTTP API.
api/client/agent
Package client provides primitives to interact with the openapi HTTP API.
Package client provides primitives to interact with the openapi HTTP API.
api/client/v1alpha1
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
api/convert
Package convert provides API version conversion infrastructure.
Package convert provides API version conversion infrastructure.
api/convert/v1alpha1
Package v1alpha1 provides converters between v1alpha1 API types and domain types.
Package v1alpha1 provides converters between v1alpha1 API types and domain types.
api/convert/v1beta1
Package v1beta1 provides converters for v1beta1 API types.
Package v1beta1 provides converters for v1beta1 API types.
api/imagebuilder/client
Package client provides primitives to interact with the openapi HTTP API.
Package client provides primitives to interact with the openapi HTTP API.
api/server
Package server provides primitives to interact with the openapi HTTP API.
Package server provides primitives to interact with the openapi HTTP API.
api/server/agent
Package server provides primitives to interact with the openapi HTTP API.
Package server provides primitives to interact with the openapi HTTP API.
api/server/v1alpha1
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
Package v1alpha1 provides primitives to interact with the openapi HTTP API.
auth
Package auth is a generated GoMock package.
Package auth is a generated GoMock package.
auth/common
Package common is a generated GoMock package.
Package common is a generated GoMock package.
cli
cli/display
Package display contains helpers for formatting FlightCTL resources into different CLI output formats.
Package display contains helpers for formatting FlightCTL resources into different CLI output formats.
domain
Package domain defines the internal model types for flightctl.
Package domain defines the internal model types for flightctl.
imagebuilder_api/api/server
Package server provides primitives to interact with the openapi HTTP API.
Package server provides primitives to interact with the openapi HTTP API.
migration
Package migration provides database migration functionality for Flight Control.
Package migration provides database migration functionality for Flight Control.
oci
org
restore
Package restore is a generated GoMock package.
Package restore is a generated GoMock package.
service/authprovider
Package authprovider is a generated GoMock package.
Package authprovider is a generated GoMock package.
service/canary
Package canary is a generated GoMock package.
Package canary is a generated GoMock package.
service/catalog
Package catalog is a generated GoMock package.
Package catalog is a generated GoMock package.
service/certificatesigningrequest
Package certificatesigningrequest is a generated GoMock package.
Package certificatesigningrequest is a generated GoMock package.
service/checkpoint
Package checkpoint is a generated GoMock package.
Package checkpoint is a generated GoMock package.
service/dependencyref
Package dependencyref is a generated GoMock package.
Package dependencyref is a generated GoMock package.
service/device
Package device is a generated GoMock package.
Package device is a generated GoMock package.
service/enrollmentrequest
Package enrollmentrequest is a generated GoMock package.
Package enrollmentrequest is a generated GoMock package.
service/event
Package event is a generated GoMock package.
Package event is a generated GoMock package.
service/fleet
Package fleet is a generated GoMock package.
Package fleet is a generated GoMock package.
service/organization
Package organization is a generated GoMock package.
Package organization is a generated GoMock package.
service/repository
Package repository is a generated GoMock package.
Package repository is a generated GoMock package.
service/resourcesync
Package resourcesync is a generated GoMock package.
Package resourcesync is a generated GoMock package.
service/syncstate
Package syncstate is a generated GoMock package.
Package syncstate is a generated GoMock package.
service/templateversion
Package templateversion is a generated GoMock package.
Package templateversion is a generated GoMock package.
service/vulnerabilityfinding
Package vulnerabilityfinding is a generated GoMock package.
Package vulnerabilityfinding is a generated GoMock package.
ssh
tpm
Package tpm is a generated GoMock package.
Package tpm is a generated GoMock package.
trustify/v2
Package trustifyv2 provides primitives to interact with the openapi HTTP API.
Package trustifyv2 provides primitives to interact with the openapi HTTP API.
worker_client
Package worker_client is a generated GoMock package.
Package worker_client is a generated GoMock package.
pkg
aap
certmanager
certificate_reconciler.go
certificate_reconciler.go
executer
Package executer is a generated GoMock package.
Package executer is a generated GoMock package.
k8sclient
Package k8sclient is a generated GoMock package.
Package k8sclient is a generated GoMock package.
log
queues
Package queues is a generated GoMock package.
Package queues is a generated GoMock package.
scripts
air-gap/generate-embed command
generate-embed is the build-time manifest generator for flightctl-mirror-images.
generate-embed is the build-time manifest generator for flightctl-mirror-images.
air-gap/mirror-images command
Code generated by scripts/air-gap/generate-embed.
Code generated by scripts/air-gap/generate-embed.
air-gap/pkg/manifest
Package manifest defines the schema for the build-time resolved mirror manifest that is embedded in the flightctl-mirror-images binary.
Package manifest defines the schema for the build-time resolved mirror manifest that is embedded in the flightctl-mirror-images binary.
test
cmd/dev-vm command
Command flightctl-dev-vm is a developer tool for starting, connecting to, and deleting a single flightctl agent VM.
Command flightctl-dev-vm is a developer tool for starting, connecting to, and deleting a single flightctl agent VM.
e2e/infra
Package infra provides testcontainers-based infrastructure for E2E tests.
Package infra provides testcontainers-based infrastructure for E2E tests.
e2e/infra/auxiliary
Package auxiliary provides shared testcontainer-based services for E2E tests.
Package auxiliary provides shared testcontainer-based services for E2E tests.
e2e/infra/k8s
Package k8s provides Kubernetes-specific implementations of the infra providers.
Package k8s provides Kubernetes-specific implementations of the infra providers.
e2e/infra/quadlet
Package quadlet provides Quadlet/systemd-specific implementations of the infra providers.
Package quadlet provides Quadlet/systemd-specific implementations of the infra providers.
e2e/infra/redis
Package redis provides Redis and queue helpers for e2e tests using infra providers.
Package redis provides Redis and queue helpers for e2e tests using infra providers.
e2e/infra/setup
Package setup provides provider factory and default-providers for e2e tests.
Package setup provides provider factory and default-providers for e2e tests.
e2e/resources
Package resources provides utilities for creating and managing FlightCtl resources in e2e tests.
Package resources provides utilities for creating and managing FlightCtl resources in e2e tests.
harness/containers
Package containers provides shared testcontainers runtime setup (Podman/Docker socket, Ryuk, API version) for integration preflight and e2e auxiliary services.
Package containers provides shared testcontainers runtime setup (Podman/Docker socket, Ryuk, API version) for integration preflight and e2e auxiliary services.
integration/integrationstack
Package integrationstack starts or stops the named Postgres and Alertmanager testcontainers used by integration tests.
Package integrationstack starts or stops the named Postgres and Alertmanager testcontainers used by integration tests.
integration/preflight command
Command preflight starts or stops testcontainers used by integration tests (Postgres, Redis, Alertmanager).
Command preflight starts or stops testcontainers used by integration tests (Postgres, Redis, Alertmanager).
util/testdb
Package testdb provides shared test database utilities
Package testdb provides shared test database utilities

Jump to

Keyboard shortcuts

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