Events
What --jsonl writes: one JSON object per line on stdout, each with an event field.
Every command takes --jsonl (before or after the command name), or reads
INSTAMIX_JSONL=1. stdout then carries one JSON object per line, each
with an event field; stderr keeps its human messages, and the exit code
is unchanged. run --record FILE writes the same events to a file, for
imix replay.
Where they come from#
| Event | From |
|---|---|
profiles | show |
file | show, cat, generate |
removed | generate into a directory |
generated | generate |
change, diff | diff |
problem, checks | lint |
target | test --list |
profile | profiles |
stage, tag, group, variable | describe |
exec, output, exited | anything that runs ansible, galaxy, lint or molecule |
play, task, result, recap | a run: run and container |
hidden | files left out by inactive profiles |
skipped, script, wrote | import, init |
requirement | doctor |
env | env |
runtime | run, install, lint and test, before they start anything |
error | any failure |
change#
A file generate would change.
| Field | Holds | What it is |
|---|---|---|
diff | string | A unified diff. |
path | string always there | |
status | added | modified | removed always there |
checks#
The checks finished.
| Field | Holds | What it is |
|---|---|---|
count | integer always there | |
problems | integer always there |
container#
The image and engine container runs ansible with, before it does.
| Field | Holds | What it is |
|---|---|---|
engine | string always there | |
hint | string | What in the script names the image, when it does. |
image | string always there |
diff#
diff finished.
| Field | Holds | What it is |
|---|---|---|
changed | boolean always there | |
dest | string always there |
env#
The environment env built or reused.
| Field | Holds | What it is |
|---|---|---|
ansible | string | null always there | |
collections | integer | Galaxy collections installed in it. |
created | boolean always there | |
path | string always there | |
python | string | null always there | |
roles | integer | Galaxy roles installed in it. |
error#
The command failed; the exit code is not 0.
| Field | Holds | What it is |
|---|---|---|
message | string always there |
exec#
instamix started a program.
| Field | Holds | What it is |
|---|---|---|
cmd | array of string always there | |
cwd | string always there |
exited#
The program exited.
| Field | Holds | What it is |
|---|---|---|
cmd | array of string always there | |
status | integer always there |
file#
A file of the tree.
| Field | Holds | What it is |
|---|---|---|
base64 | string | The contents, if not UTF-8 (cat). |
default | boolean | Added by instamix (inventory, ansible.cfg, requirements.yml), not declared by the script. |
mode | integer | null always there | Unix permission bits, or null for the default (0644). |
path | string always there | |
sha256 | string always there | |
size | integer always there | |
text | string | The contents, if UTF-8 (cat). |
generated#
generate finished.
| Field | Holds | What it is |
|---|---|---|
compression | gz | bz2 | xz | none | |
dest | string always there | |
files | integer always there | |
format | directory | tar always there | |
sha256 | string | Of the archive. |
group#
A host group and what its hosts are for (describe).
| Field | Holds | What it is |
|---|---|---|
children | array of string always there | |
description | string always there | |
hosts | array of string always there | |
name | string always there | |
vars | object always there |
hidden#
Files left out because their profiles are not active.
| Field | Holds | What it is |
|---|---|---|
files | integer always there | |
profiles | array of string always there |
image#
The container image the script asks for.
| Field | Holds | What it is |
|---|---|---|
image | string always there | |
source | string always there |
output#
A line the program wrote.
| Field | Holds | What it is |
|---|---|---|
line | string always there | |
stream | stdout | stderr always there |
play#
A play started (run).
| Field | Holds | What it is |
|---|---|---|
hosts | array of string always there | |
id | string always there | |
name | string always there |
problem#
A check found a problem.
| Field | Holds | What it is |
|---|---|---|
check | string always there | |
message | string always there |
profile#
A profile the script mentions.
| Field | Holds | What it is |
|---|---|---|
active | boolean always there | |
builtin | boolean always there | |
files | integer always there | |
name | string always there |
profiles#
The active profiles.
| Field | Holds | What it is |
|---|---|---|
active | array of string always there |
recap#
One host’s totals at the end of a run.
| Field | Holds | What it is |
|---|---|---|
changed | integer always there | |
failures | integer always there | |
host | string always there | |
ignored | integer always there | |
ok | integer always there | |
rescued | integer always there | |
skipped | integer always there | |
unreachable | integer always there |
record#
A recording began (–record): the first event of the file.
| Field | Holds | What it is |
|---|---|---|
argv | array of string always there | |
at | string always there | When, as an ISO 8601 time (UTC). |
script | string always there |
removed#
A file generate removed because the script no longer declares it.
| Field | Holds | What it is |
|---|---|---|
path | string always there |
requirement#
A runtime requirement, checked against this machine (doctor).
| Field | Holds | What it is |
|---|---|---|
found | string | null always there | The version, or path for a command, found here. |
kind | ansible | python | pip | command always there | |
name | string always there | |
ok | boolean always there | |
spec | string always there | A version requirement (>=2.16,<2.19), or empty. |
result#
What a task did on one host, or for one loop item (run).
| Field | Holds | What it is |
|---|---|---|
action | string always there | |
delegated_to | string | |
host | string always there | |
ignored | boolean | A failure ignore_errors lets through. |
item | any | The loop item this result is for. |
items | integer | The number of loop items, on the result that sums a loop up; each item had its own event. |
result | object always there | The module’s result, as ansible’s callbacks see it: without internal keys and the module invocation, and censored for no_log. |
status | ok | changed | failed | skipped | unreachable always there | |
task | string always there | |
task_id | string always there |
runtime#
What a command that starts ansible runs it with, before it does.
| Field | Holds | What it is |
|---|---|---|
ansible | string | null always there | |
ansible_playbook | string | null always there | Where ansible-playbook is; null: nowhere. |
base | string | The base the environment starts from. |
environment | string | null always there | The environment in use (–env), or null: PATH. |
proxy | string | Where galaxy and pip content comes through. |
python | string | null always there | |
settings | array of string | The config files in effect, the weakest first. |
script#
The script import wrote.
| Field | Holds | What it is |
|---|---|---|
source | string always there |
skipped#
A file import left out because it may hold secrets.
| Field | Holds | What it is |
|---|---|---|
path | string always there | |
reason | string always there |
stage#
A stage of the script (describe): a playbook under a tag of its name.
| Field | Holds | What it is |
|---|---|---|
description | string always there | |
hosts | array of string | What the plays of its playbook target. |
name | string always there | |
playbook | string always there | |
source | string | The script that described it. |
tags | array of string always there | |
when | any | The condition the stage runs under. |
tag#
A tag and what it runs (describe).
| Field | Holds | What it is |
|---|---|---|
description | string always there | |
name | string always there | |
stage | boolean always there | It is the tag of a stage. |
target#
Something test can run.
| Field | Holds | What it is |
|---|---|---|
name | string always there | |
path | string always there | |
runner | molecule | ansible-test | playbook always there |
task#
A task or handler started (run).
| Field | Holds | What it is |
|---|---|---|
action | string always there | |
handler | boolean always there | |
id | string always there | |
name | string always there | |
path | string | Where the task is, file:line. |
role | string |
variable#
A variable the playbooks need, and its shape (describe).
| Field | Holds | What it is |
|---|---|---|
default | any | What the group’s group_vars give it. |
description | string always there | |
group | string always there | |
name | string always there | |
required | boolean always there | The script has to set it: it has no default. |
schema | object | The shape as JSON Schema, as far as one says it. |
shape | string always there | The shape, as glom’s Match prints it. |
source | string | The script that described it. |
wrote#
A script was written.
| Field | Holds | What it is |
|---|---|---|
path | string always there |