Arista EOS ConfigSession

Arista EOS ConfigSession

Certified
Enterprise Edition

Change the configuration of an EOS switch with a config session

Uses EOS configuration sessions: DIFF stages commands in a named session, returns the diff and aborts the session (dry run). APPLY stages them, returns the diff and commits it, immediately or with a commitTimer after which the switch reverts unless CONFIRM is run. ABORT discards a pending session.

With mode: REPLACE the session starts from rollback clean-config, so commands must describe the whole configuration. An empty diff is never committed.

yaml
type: io.kestra.plugin.ee.arista.eos.ConfigSession

Dry run a change, then apply it with a 5 minute safety timer

yaml
id: arista_config_session
namespace: company.network

tasks:
  - id: dry_run
    type: io.kestra.plugin.ee.arista.eos.ConfigSession
    host: leaf1.lab.example.com
    username: "{{ secret('ARISTA_USERNAME') }}"
    password: "{{ secret('ARISTA_PASSWORD') }}"
    action: DIFF
    sessionName: kestra_vlan_change
    commands:
      - vlan 120
      - name tenant-a

  - id: apply
    type: io.kestra.plugin.ee.arista.eos.ConfigSession
    host: leaf1.lab.example.com
    username: "{{ secret('ARISTA_USERNAME') }}"
    password: "{{ secret('ARISTA_PASSWORD') }}"
    action: APPLY
    sessionName: kestra_vlan_change
    commitTimer: PT5M
    commands:
      - vlan 120
      - name tenant-a

  - id: confirm
    type: io.kestra.plugin.ee.arista.eos.ConfigSession
    host: leaf1.lab.example.com
    username: "{{ secret('ARISTA_USERNAME') }}"
    password: "{{ secret('ARISTA_PASSWORD') }}"
    action: CONFIRM
    sessionName: kestra_vlan_change
Installation

This Enterprise plugin requires an Enterprise image and access to the plugin registry. Install it with the following command:

kestractl plugins get io.kestra.plugin.ee:plugin-ee-arista --compatible-for $KESTRA_VERSION

For kestractl, use your Kestra version with --compatible-for, or specify an exact plugin version.

For Kestra CLI, replace LATEST with a specific version or version range to pin the plugin version.

Properties
Possible Values
DIFFAPPLYCONFIRMABORT

Action

DIFF dry run, APPLY stage and commit, CONFIRM confirm a commit made with a timer, ABORT discard the session.

Switch host

Host name or IP address of the switch management interface serving eAPI.

Password

Use {{ secret('ARISTA_PASSWORD') }}. The value is never logged nor returned in outputs.

Username

Account allowed to run privileged commands over eAPI.

Assets this task consumes as inputs or produces as outputs, for lineage tracking and the asset graph (Enterprise Edition). A flow declaring this property on a task is rejected in the open-source edition.

Definitions
assetFailureBehaviorstring
Possible Values
IGNOREFAILWARN

Asset failure behavior

Behavior applied to the task state when a declared asset fails to render, emit, or be persisted (e.g. a lock conflict): FAIL escalates it to FAILED, WARN (default) warns it if it would otherwise succeed, IGNORE leaves the state untouched.

enableAutobooleanstring

Whether to auto-register assets referenced dynamically at runtime that are not statically declared in inputs or outputs.

inputsarray

The assets consumed as inputs.

id*string
Min length1
typestring
outputs

The assets produced as outputs.

id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*object
descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150
id*string
Min length1
Max length150
type*string
Min length1

Custom asset type

descriptionstring
displayNamestring
metadataobject
Default{}
namespacestring
Min length1
Max length150

CA certificate

PEM encoded CA certificate(s) used to validate the switch certificate. When set, only this CA is trusted. When empty, the JVM trust store is used.

SubTypestring

Commands

Configuration commands staged in the session. Required for DIFF and APPLY.

Commit timer

For APPLY: the commit reverts after this duration unless confirmed with CONFIRM. Whole seconds, up to 99 hours.

Connect timeout

Maximum time to open the connection. Defaults to 10 seconds.

Trust any certificate

Disables certificate and host name validation. Only for labs with self-signed certificates. Defaults to false.

Possible Values
MERGEREPLACE

Mode

MERGE (default) adds commands to the running configuration, REPLACE starts from rollback clean-config.

eAPI port

Defaults to 443.

Request timeout

Maximum time to wait for one eAPI answer. Defaults to 60 seconds. Tasks that run slow commands (image copy, checksum) expose their own timeout.

Session name

Letters, digits, _, - and ., up to 50 characters. Defaults to kestra.

Changed

True when the session contains a change (DIFF, APPLY) or a pending change was confirmed (CONFIRM).

Committed

True when the change is committed. With a commit timer it stays true but reverts unless confirmed.

Diff

Differences between the running configuration and the session, as printed by the switch. Not set for CONFIRM and ABORT.