Skip to main content
Version: 0.12.0

Running it

On a workstation an application runs in the application form: the manager, yoke, writes what should run, and the account's guardian starts a Core for it. Nothing needs root, and the manager starts the guardian itself when none is answering.

The account's configuration​

The manager needs an install root it may write into, and finds the Core on the PATH. Installing Yoke gave your account one: the host's /var/lib/yoke/apps when Yoke was installed for the whole host and you are in yoke-apps, or a root of your own named in ~/.config/yoke/manager.conf when it was installed for your account alone (installing Yoke, configuration).

The instance's sockets are under XDG_RUNTIME_DIR, which a desktop session sets to /run/user/<uid>. A socket path has a ceiling of 107 characters, and the gate refuses a deployment that would produce a longer one, naming the path, so a runtime directory set by hand has to be short.

A run from the working directory​

yoke app run --from hello
hello-1 runs com.example.hello 0.1.0, an ephemeral instance; an interrupt stops it
from /home/you/hello, whose integrity is not verified
hello-1 is starting
hello-1 is observable
it says of itself: bundle.unverified at /home/you/hello

It runs the bundle as it is being written, with the same gate, the same Core and the same units as an installed one, and verifies nothing: the instance says so about itself. It follows the instance until it is interrupted, and the instance's record goes with it (instances). A line such as confinement.no_cgroup_delegation is the host saying what it could not do, not a refusal.

From a second terminal, ask the greeter through the channel, with the client:

./ask hello-1 cli greeter greeter.hello world
ask: scope.withheld: greeter.hello is declared and not granted to that plugin

The refusal is the model working. Both Plugins were admitted, each with what it declares withheld, because nobody has granted anything. Grant the two capabilities this application uses, one per Plugin, and restart the two units so that each is admitted again — a grant reaches a unit at its next admission:

yoke plugin grant com.example.greeter query.hello.answer
previously not granted
effective at the unit's next admission
consequence greeter incarnation 1: still under the scope of its admission, until it is admitted again
yoke plugin grant com.yoke.reference.clock query.now.answer
yoke unit restart greeter
yoke unit restart clock
./ask hello-1 cli greeter greeter.hello world
./ask hello-1 cli clock clock.now
hello, world
2026-11-02T21:07:45Z

A grant names a Plugin, not a unit: every unit launched from it in this instance is covered. The greeter's command and occurrence, and the clock's, stay withheld, and the two units run without them. yoke unit ask asks a unit the same question from the administrative side, without a channel.

A grant lasts as long as the instance, and the run's instance lasts as long as the run: the next yoke app run starts with nothing granted. An instance that lasts is the next step.

An instance​

yoke app install out/com.example.hello-0.1.0.yoke
yoke instance create com.example.hello --name dev
yoke instance start dev
installed at /home/you/yoke/apps/com.example.hello/0.1.0
created dev, pinned to com.example.hello 0.1.0
dev should be running, and the guardian is told
yoke plugin grant com.example.greeter query.hello.answer --instance dev
yoke plugin grant com.yoke.reference.clock query.now.answer --instance dev
yoke unit restart greeter --instance dev
yoke unit restart clock --instance dev
./ask dev cli clock clock.now
2026-11-02T21:08:56Z

Installing verifies the package and expands it; creating writes a record; starting asks the guardian (installing, instances). The grants are kept with the instance's state, so yoke instance stop dev and yoke instance start dev keep them. A new version of the application is a new package: install it, then yoke instance set-version dev <version> (updating and removal).

When something is wrong​

Look atWithIt says
the instancesyoke instance listeach with its state — observable, stopped, refused, failed
the unitsyoke unit list, yoke unit show clockeach unit's state, its condition, and what its plugin declared and was authorised
the logyoke log query --unit clock, yoke log followevery event of the instance: states, admissions, grants, a unit's health and occurrences
what the Core publishesyoke core subscribea snapshot of the records, then each change as it happens
the guardian$XDG_STATE_HOME/yoke/guardian.log — ~/.local/state/yoke/guardian.log by defaultthe gate's findings at a start, and every Core it ran
an interactive sessionyoke shellthe same operations, typed one after another

A refusal names its code and the field or path it is about, and every refusal found is reported, not the first. 1 is a refusal and the same attempt will be refused again; 2 is a fault and may succeed (the command line).

A unit started by hand, under a debugger, is admitted only by a run that asks for it: yoke app run --from hello --admit-unlaunched relaxes the one stage that checks the Core launched the process, and nothing else (admission).