Schlagwort-Archive: event-handler

ARISTA bash event-handler in different VRF context

We are using an event-handler with on-startup-config write to push the configuration to our langley service which push the config in the central GIT repository.

To execute an bash command in an different vrf context use „ip netns exec ns-<VRF>“ before the command. See the example:

event-handler ARCHIVE_LANGLEY
   trigger on-startup-config
   action bash sudo ip netns exec ns-MANAGEMENT curl https://10.1.1.1/langley/put/$(hostname)/1 --upload-file /mnt/flash/startup-config