Skip to main content
Version: v3.9.0

LocalAgent fields

Reference for kind: LocalAgent. Deploy flow is on Local node.

Deploy
apiVersion: datasance.com/v3 # required, string
kind: LocalAgent # required, string
metadata:
name: local # no, string. Empty becomes local
namespace: my-ecn # no, string. Must match -n when both are set
tags: [] # no, list of string
spec:
host: 127.0.0.1 # no, string. spec.config.host wins for the Controller host
controllerEndpoint: https://127.0.0.1:51121 # no, string
airgap: false # no, bool
package: # no, object. Same keys as Agent
version: "1.1.0" # no, string
container:
image: ghcr.io/datasance/edgelet:1.1.0 # no, string
registry: registry.example.com # no, string
username: pull-user # no, string
password: pull-token # no, string
wasm:
edgelet-wasmtime: # no, object. The key is the handler name
url: https://example.com/shim.tar.gz # no, string. Keep url or path
path: /opt/shims/edgelet-wasmtime.tar.gz # no, string. Keep url or path
sha256: "<sha256>" # no, string
scripts: # no, object. dir is required when this block is set
dir: /opt/bootstrap # required when scripts is set, string
deps:
entrypoint: deps.sh # no, string
args: [] # no, list
install:
entrypoint: install.sh # no, string
args: [] # no, list
uninstall:
entrypoint: uninstall.sh # no, string
args: [] # no, list
config:
description: Local node # no, string
location: desk # no, string
latitude: 0.0 # no, float
longitude: 0.0 # no, float
arch: amd64 # recommended, string
host: 127.0.0.1 # no, string
deploymentType: native # no, string, default native
containerEngine: edgelet # no, string, default edgelet
containerEngineUrl: unix:///run/edgelet/containerd.sock # no, string
networkInterface: lo0 # no, string
diskLimit: 10 # no, int64
diskDirectory: /var/lib/edgelet # no, string
memoryLimit: 1024 # no, int64
cpuLimit: 100 # no, int64
logLimit: 100 # no, int64
logDirectory: /var/log/edgelet # no, string
logFileCount: 5 # no, int64
statusFrequency: 10 # no, float
changeFrequency: 10 # no, float
watchdogEnabled: true # no, bool
logLevel: info # no, string
pruningFrequency: 60 # no, float
availableDiskThreshold: 80 # no, float
timeZone: UTC # no, string
gpsMode: off # no, string
gpsScanFrequency: 0 # no, float
gpsDevice: /dev/ttyUSB0 # no, string
edgeGuardFrequency: 0 # no, float. 0 disables
upstreamRouters: # no, list of string
- default-router
routerConfig:
routerMode: edge # no, string, default edge
messagingPort: 5671 # no, int, default 5671
edgeRouterPort: 45671 # no, int. Interior mode only
interRouterPort: 55671 # no, int. Interior mode only
upstreamNatsServers: # no, list of string
- default-nats-hub
natsConfig:
natsMode: leaf # no, string, default leaf
natsServerPort: 4222 # no, int, default 4222
natsLeafPort: 7422 # no, int, default 7422
natsClusterPort: 6222 # no, int. Server mode only
natsMqttPort: 8883 # no, int, default 8883
natsHttpPort: 8222 # no, int, default 8222
jsStorageSize: 10G # no, string, default 10G
jsMemoryStoreSize: 1G # no, string, default 1G

Not deployed​

These fields come back from describe. Leave them out of the file you pass to deploy.

uuid: "<uuid>" # describe only, string
created: "<timestamp>" # describe only, string

metadata.namespace, when set, must match -n. If metadata.name is empty, the name becomes local.

Fields specific to LocalAgent​

FieldTypeRequiredDescription
hoststringNoLegacy host. spec.config.host wins for the Controller host.
controllerEndpointstringNoOverride Controller URL for provision
airgapboolNoSame as a remote Agent
uuidstringNoSet after deploy
createdstringNoSet after deploy

There is no ssh block. Bootstrap runs on the local machine.

For a non-system node, potctl rejects deploy when TCP 54321 is already in use. That port is the default local system node layout.

spec.package and spec.scripts​

Package and scripts match Agent fields. Local bootstrap sets LOCAL_INSTALL=1, so the remote sudo check does not run. See Bootstrap.

spec.config​

Same structure as Agent.spec.config. Paths below are under spec.config.

Host resolution for provision and the Controller API:

  1. spec.config.host when it is non-empty
  2. spec.host
  3. localhost

Identity and geo​

FieldTypeRequiredDescription
config.descriptionstringNoFree text
config.locationstringNoLocation label
config.latitudefloatNoGeo latitude
config.longitudefloatNoGeo longitude
config.archstringRecommendedamd64, arm64, arm, riscv64. Synced to archId.

Runtime​

FieldTypeDefault (edge)Description
config.hoststringSee precedence aboveController host
config.deploymentTypestringnativenative or container
config.containerEnginestringedgeletedgelet, docker, or podman
config.containerEngineUrlstringEngine defaultSocket URL for the engine
config.networkInterfacestringBind interface

Desktop container on macOS or Windows skips host config materialization. See Desktop container.

Resource limits and logging​

FieldTypeDescription
config.diskLimitint64Disk quota (GiB)
config.diskDirectorystringData directory
config.memoryLimitint64Memory limit (MiB)
config.cpuLimitint64CPU limit (%)
config.logLimitint64Log size limit
config.logDirectorystringLog directory
config.logFileCountint64Rotated log files
config.statusFrequencyfloatStatus interval
config.changeFrequencyfloatChange interval
config.watchdogEnabledboolWatchdog
config.logLevelstringLog level
config.pruningFrequencyfloatPrune interval
config.availableDiskThresholdfloatDisk threshold (%)
config.timeZonestringTimezone

GPS and EdgeGuard​

FieldTypeDescription
config.gpsModestringFor example auto or off
config.gpsScanFrequencyfloatGPS scan interval
config.gpsDevicestringGPS device
config.edgeGuardFrequencyfloat0 disables. See EdgeGuard.

Router​

FieldTypeDescription
config.upstreamRouters[]stringUpstream router node names. Resolved to UUIDs at deploy.
FieldTypeDefault (edge)Description
config.routerConfig.routerModestringedgeedge, interior, or none
config.routerConfig.messagingPortint5671Messaging port
config.routerConfig.edgeRouterPortintInterior only
config.routerConfig.interRouterPortintInterior only

NATS​

FieldTypeDescription
config.upstreamNatsServers[]stringNATS server node names. Resolved to UUIDs at deploy.
FieldTypeDefault (edge)Description
config.natsConfig.natsModestringleafleaf, server, or none
config.natsConfig.natsServerPortint4222Client port
config.natsConfig.natsLeafPortint7422Leaf port
config.natsConfig.natsClusterPortintServer only
config.natsConfig.natsMqttPortint8883MQTT
config.natsConfig.natsHttpPortint8222Monitoring HTTP
config.natsConfig.jsStorageSizestring10GJetStream storage
config.natsConfig.jsMemoryStoreSizestring1GJetStream memory

Defaults, validation, and deploy processing match Agent fields.

configure agent​

Not supported for LocalAgent. The SSH configure command applies to remote nodes only. See Lifecycle.

Group 3See anything wrong with the document? Help us improve it!