==============
Managing peers
==============

Peers are displayed in a table on the node details page.

.. contents::
    :local:
    :depth: 1

Adding a peer
=============

To add a peer, click the |add| button next to the header on the **Peers**
table. This will open the **Add peer** modal. From here you can specify the
following information. Fields marked with an asterisk are required.

Name
----

A descriptive name for the peer.

Interfaces *
------------

Any interfaces on the node used to establish peer link connections. A peer can
have any number of interfaces assigned to it.

Preference *
++++++++++++

The preference of the associated interface. Defaults to 500. Higher values have
a higher priority. Multiple interfaces can share the same preference(s).

Remotes *
---------

Any remote nodes or node groups that form the target of a peer link connection.
A peer can have any number of remotes assigned to it.

Preference *
++++++++++++

The preference of the associated remote. Defaults to 500. Higher values have
a higher priority. Multiple remotes can share the same preference(s).

Editing a peer
==============

To edit a peer, click the |edit| button in the ``Actions`` column of the
corresponding row in the **Peers** table. This will open the **Edit peer**
modal.

Deleting a peer
===============

To delete a peer, click the |delete| button in the ``Actions`` column. This
will ask you to confirm before the peer is **permanently** deleted.

.. |add| image:: /attachments/laywire/add.svg
    :width: 20px
    :alt: Add button
.. |edit| image:: /attachments/laywire/edit.svg
    :width: 20px
    :alt: Edit button
.. |delete| image:: /attachments/laywire/delete.svg
    :width: 20px
    :alt: Delete button
