Image management
The Image resource is the workflow that is used to change image of the
            operating system on nodes, via an upgrade or downgrade. For more information about
            workflows, see Workflows and workflow definitions.
You can use the Image workflow to perform the following tasks:
- Reimage a single node, a list of nodes by name, a set of nodes using a label selector, or tranches of nodes, including support for canaries
 - Perform a configurable set of pre and post checks to verify:
- that all interfaces are up (with an option to use a label selector)
 - that all default BGP peers are up
 - reachability on ISLs
 - reachability between system addresses
 
 
In the Image resource, provide the input for the following
                fields:
Type: the type of workflow. Set tonode,nodeselector, ortranchenodeProfile: set to the destinationNodeProfileresource.version: set to the destination version in theNodeProfileresource.
The following settings are optional:
prompt: specifies when the workflow prompts an operator to continue. Set toAfterPreChecksorAfterPostChecks. These options can force a prompt even when checks pass.checks, a container that includes options for pre and post checks:skip: indicates that checks should be skipped (not run).force: indicates that checks should be run without prompts, even if checks fail.checks: lists the checks to run. If not provided, all checks are run. Valid checks areInterface,DefaultBGP,PingISL, andPingSystem.
Requirements for re-imaging nodes
Before running an image workflow, ensure that deviations in the system, if any, have all been accepted or rejected.
Ensure that node groups and node users have the necessary privileges to perform the operations. For example, the GNOI/GNSI privilege is required to execute operational commands such as reboot.
Re-imaging failure
- Cleaning up drain policies created by the workflow.
 - Removing any configlets created by the workflow.
 - Reverting the node profile and setting the NPP mode if necessary.
 
Operators can attempt re-imaging by creating a new workflow.
Reimaging individual nodes
You can reimage individual nodes using the Image workflow or using the
        edactl tool.
Workflow resource for re-imaging specific nodes
To reimage individual nodes using the Image workflow, provide the
        following input:
type: set tonodenodes: set to the name of theTopoNodesto be reimaged
apiVersion: core.eda.nokia.com/v1
kind: Workflow
metadata:
  name: workflow-upgrade-leaf1
  namespace: eda
spec:
  type: operatingsystem-image
  input:
    type: node
    nodes:
    - mv-dc1-fabric1-leaf1
    nodeProfile: srlinux-24.10.1
    version: "24.10.1"
    Using the edactl tool with a GVK workflow definition
edactl workflow run operatingsystem-image-gvk workflow-mv1-dc1-leaf-1-bynode --bg -n eda type node nodes[i] 0:mv1nd01-leaf-1 nodeProfile srlinux-25.3.2-70 version 25.3.2
    Reimaging nodes using labels
You can reimage nodes using the Image workflow and applying labels to select
      toponodes or using the edactl tool.
Workflow resource for re-imaging nodes using a label selector
To reimage a set of nodes using a label selector, provide the following input:
type: set tonodeselector.nodeSelectors: provide a list of label selectors to selectTopoNodes.
apiVersion: core.eda.nokia.com/v1
kind: Workflow
metadata:
  name: workflow-upgrade-rack1
  namespace: eda
spec:
  type: operatingsystem-image
  input:
    type: nodeselector
    nodeSelector:
      - 'eda.nokia.com/redundancy-group=rack1'
    nodeProfile: srlinux-24.10.1
    version: "24.10.1"
    prompt:
    - AfterPreChecks
    drains:
      minimumWaitTime: 5
    Using the edactl tool with a GVK workflow definition
edactl workflow run operatingsystem-image-gvk workflow-fabric-upgrade-bylabel --bg -n eda type nodeselector nodeSelector[i] 0:maintenancenodes=fabric1 nodeProfile srlinux-24.10.3-201 version 24.10.3 checks.skip true drains.skip true
    Reimaging node tranches
To reimage sets of groups of nodes with an ordered list of label selectors, provide the following input:
type: set totranche.tranches: set to a list ofnodeSelector, nesting the node selector typecanaries: optionally be used with tranches, specify as a pre-tranche to be reimaged before all others, and are subsequently the last to be undone in the event of a revert.
- Canaries are imaged first, executing any pre and post checks along with any waits. Assuming these operations succeed, the workflow continues.
 - Tranche with index 0 is imaged next, following the same run-to-completion workflow.
 - Tranche with the next index is imaged next, with this repeating until all tranches have been upgraded.
 
Workflow resource for re-imaging tranches of nodes
apiVersion: core.eda.nokia.com/v1
kind: Workflow
metadata:
  name: workflow-upgrade-rack1-rack2
  namespace: eda
spec:
  type: operatingsystem-image
  input:
    type: tranche
    drains:
      skip: true
    tranches:
      - nodeSelector:
          - 'eda.nokia.com/redundancy-group=rack1'
        name: rack1
      - nodeSelector:
          - 'eda.nokia.com/redundancy-group=rack2'
        name: rack2
    nodeProfile: srlinux-24.10.1
    version: "24.10.1"
        Creating the workflow using the edactl tool with a GVK workflow definition
edactl workflow run operatingsystem-image-gvk wrorktranche --bg -n eda type tranche drains.skip true nodeProfile srlinux-25.3.2-70 version 25.3.2 tranches[i].name 0:a tranches[i].nodeSelector[i] 0:0:eda.nokia.com/redundancy-group=a tranches[i].name 1:b tranches[i].nodeSelector[i] 1:0:eda.nokia.com/redundancy-group=b
        Node imaging checks
The Image workflow supports the following checks during node
            imaging:
- Verifying that interlink switch interfaces are operational. This check gets any
                    
Interfaceresource with the labeleda.nokia.com/role=interSwitchwhere the current node is a member. The list of up interfaces is stored for comparison later. - Verifying that BGP peers are up in the default network instance. As with interfaces, the list of up default BGP peers is stored for comparison later.
 - 
                
Verifying connectivity on every ISL. This check triggers the ping workflow to run, passing in
islas thepingType. - 
                
Verifying connectivity between all system addresses of nodes. This triggers the ping workflow to run, passing in
systemas thepingType. 
These checks are executed before an upgrade batch takes place, and after the upgrade batch completes. If any check fails, the administrator is prompted to continue, but only after completing the execution of each test. If an operator rejects continuing in post checks, the image reverts to its previous version.