---
Function {
 argument: None,
 arguments: FunctionArguments {
  arguments: [
   FunctionArgument {
    identifier: "options",
    default: None,
   },
   FunctionArgument {
    identifier: "pkgs",
    default: None,
   },
   FunctionArgument {
    identifier: "lib",
    default: None,
   },
   FunctionArgument {
    identifier: "config",
    default: None,
   },
  ],
  ellipsis: false,
 },
 definition: With {
  expression: Variable {
   identifier: "lib",
   position: (3, 6),
  },
  target: LetIn {
   bindings: [
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "cfg",
        position: (6, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (6, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "services",
         position: (6, 16),
        },
        Raw {
         content: "prometheus",
         position: (6, 25),
        },
        Raw {
         content: "exporters",
         position: (6, 36),
        },
        Raw {
         content: "wireguard",
         position: (6, 46),
        },
       ],
      },
      default: None,
     },
    ),
   ],
   target: Map {
    bindings: [
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "port",
         position: (8, 3),
        },
       ],
      },
      Int {
       value: 9586,
       position: (8, 10),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "imports",
         position: (9, 3),
        },
       ],
      },
      List {
       elements: [
        FunctionApplication {
         function: Variable {
          identifier: "mkRenamedOptionModule",
          position: (10, 6),
         },
         arguments: [
          List {
           elements: [
            String {
             parts: [
              Raw {
               content: "addr",
               position: (10, 31),
              },
             ],
            },
           ],
           position: (10, 28),
          },
          List {
           elements: [
            String {
             parts: [
              Raw {
               content: "listenAddress",
               position: (10, 42),
              },
             ],
            },
           ],
           position: (10, 39),
          },
         ],
        },
        Map {
         bindings: [
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "options",
              position: (11, 8),
             },
             Raw {
              content: "warnings",
              position: (11, 16),
             },
            ],
           },
           PropertyAccess {
            expression: Variable {
             identifier: "options",
             position: (11, 27),
            },
            attribute_path: AttributePath {
             attributes: [
              Raw {
               content: "warnings",
               position: (11, 35),
              },
             ],
            },
            default: None,
           },
          ),
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "options",
              position: (11, 45),
             },
             Raw {
              content: "assertions",
              position: (11, 53),
             },
            ],
           },
           PropertyAccess {
            expression: Variable {
             identifier: "options",
             position: (11, 66),
            },
            attribute_path: AttributePath {
             attributes: [
              Raw {
               content: "assertions",
               position: (11, 74),
              },
             ],
            },
            default: None,
           },
          ),
         ],
         recursive: false,
         position: (11, 6),
        },
       ],
       position: (9, 13),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "extraOpts",
         position: (13, 3),
        },
       ],
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "verbose",
            position: (14, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkEnableOption",
           position: (14, 15),
          },
          arguments: [
           String {
            parts: [
             Raw {
              content: "Verbose logging mode for prometheus-wireguard-exporter",
              position: (14, 31),
             },
            ],
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "wireguardConfig",
            position: (16, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (16, 23),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (17, 7),
                },
               ],
              },
              With {
               expression: Variable {
                identifier: "types",
                position: (17, 19),
               },
               target: FunctionApplication {
                function: Variable {
                 identifier: "nullOr",
                 position: (17, 26),
                },
                arguments: [
                 FunctionApplication {
                  function: Variable {
                   identifier: "either",
                   position: (17, 34),
                  },
                  arguments: [
                   Variable {
                    identifier: "path",
                    position: (17, 41),
                   },
                   Variable {
                    identifier: "str",
                    position: (17, 46),
                   },
                  ],
                 },
                ],
               },
               position: (17, 14),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (18, 7),
                },
               ],
              },
              Variable {
               identifier: "null",
               position: (18, 17),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (20, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "Path to the Wireguard Config to\n<link xlink:href=\"https://github.com/MindFlavor/prometheus_wireguard_exporter/tree/2.0.0#usage\">add the peer's name to the stats of a peer</link>.\n\nPlease note that <literal>networking.wg-quick</literal> is required for this feature\nas <literal>networking.wireguard</literal> uses\n<citerefentry><refentrytitle>wg</refentrytitle><manvolnum>8</manvolnum></citerefentry>\nto set the peers up.\n",
                 position: (21, 1),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (16, 32),
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "singleSubnetPerField",
            position: (31, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (31, 28),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (32, 7),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (32, 14),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "bool",
                  position: (32, 20),
                 },
                ],
               },
               default: None,
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (33, 7),
                },
               ],
              },
              Variable {
               identifier: "false",
               position: (33, 17),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (34, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "By default, all allowed IPs and subnets are comma-separated in the\n<literal>allowed_ips</literal> field. With this option enabled,\na single IP and subnet will be listed in fields like <literal>allowed_ip_0</literal>,\n<literal>allowed_ip_1</literal> and so on.\n",
                 position: (35, 1),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (31, 37),
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "withRemoteIp",
            position: (42, 5),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (42, 20),
          },
          arguments: [
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "type",
                 position: (43, 7),
                },
               ],
              },
              PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (43, 14),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "bool",
                  position: (43, 20),
                 },
                ],
               },
               default: None,
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "default",
                 position: (44, 7),
                },
               ],
              },
              Variable {
               identifier: "false",
               position: (44, 17),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (45, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "Whether or not the remote IP of a WireGuard peer should be exposed via prometheus.\n",
                 position: (46, 1),
                },
               ],
              },
             ),
            ],
            recursive: false,
            position: (42, 29),
           },
          ],
         },
        ),
       ],
       recursive: false,
       position: (13, 15),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "serviceOpts",
         position: (50, 3),
        },
       ],
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "path",
            position: (51, 5),
           },
          ],
         },
         List {
          elements: [
           PropertyAccess {
            expression: Variable {
             identifier: "pkgs",
             position: (51, 14),
            },
            attribute_path: AttributePath {
             attributes: [
              Raw {
               content: "wireguard-tools",
               position: (51, 19),
              },
             ],
            },
            default: None,
           },
          ],
          position: (51, 12),
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "serviceConfig",
            position: (53, 5),
           },
          ],
         },
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "AmbientCapabilities",
               position: (54, 7),
              },
             ],
            },
            List {
             elements: [
              String {
               parts: [
                Raw {
                 content: "CAP_NET_ADMIN",
                 position: (54, 32),
                },
               ],
              },
             ],
             position: (54, 29),
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "CapabilityBoundingSet",
               position: (55, 7),
              },
             ],
            },
            List {
             elements: [
              String {
               parts: [
                Raw {
                 content: "CAP_NET_ADMIN",
                 position: (55, 34),
                },
               ],
              },
             ],
             position: (55, 31),
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "ExecStart",
               position: (56, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "",
               position: (57, 1),
              },
              Expression {
               expression: PropertyAccess {
                expression: Variable {
                 identifier: "pkgs",
                 position: (57, 11),
                },
                attribute_path: AttributePath {
                 attributes: [
                  Raw {
                   content: "prometheus-wireguard-exporter",
                   position: (57, 16),
                  },
                 ],
                },
                default: None,
               },
              },
              Raw {
               content: "/bin/prometheus_wireguard_exporter \\\n  -p ",
               position: (57, 46),
              },
              Expression {
               expression: FunctionApplication {
                function: Variable {
                 identifier: "toString",
                 position: (58, 16),
                },
                arguments: [
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (58, 25),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "port",
                     position: (58, 29),
                    },
                   ],
                  },
                  default: None,
                 },
                ],
               },
              },
              Raw {
               content: " \\\n  -l ",
               position: (58, 34),
              },
              Expression {
               expression: PropertyAccess {
                expression: Variable {
                 identifier: "cfg",
                 position: (59, 16),
                },
                attribute_path: AttributePath {
                 attributes: [
                  Raw {
                   content: "listenAddress",
                   position: (59, 20),
                  },
                 ],
                },
                default: None,
               },
              },
              Raw {
               content: " \\\n  ",
               position: (59, 34),
              },
              Expression {
               expression: FunctionApplication {
                function: Variable {
                 identifier: "optionalString",
                 position: (60, 13),
                },
                arguments: [
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (60, 28),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "verbose",
                     position: (60, 32),
                    },
                   ],
                  },
                  default: None,
                 },
                 String {
                  parts: [
                   Raw {
                    content: "-v",
                    position: (60, 41),
                   },
                  ],
                 },
                ],
               },
              },
              Raw {
               content: " \\\n  ",
               position: (60, 45),
              },
              Expression {
               expression: FunctionApplication {
                function: Variable {
                 identifier: "optionalString",
                 position: (61, 13),
                },
                arguments: [
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (61, 28),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "singleSubnetPerField",
                     position: (61, 32),
                    },
                   ],
                  },
                  default: None,
                 },
                 String {
                  parts: [
                   Raw {
                    content: "-s",
                    position: (61, 54),
                   },
                  ],
                 },
                ],
               },
              },
              Raw {
               content: " \\\n  ",
               position: (61, 58),
              },
              Expression {
               expression: FunctionApplication {
                function: Variable {
                 identifier: "optionalString",
                 position: (62, 13),
                },
                arguments: [
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (62, 28),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "withRemoteIp",
                     position: (62, 32),
                    },
                   ],
                  },
                  default: None,
                 },
                 String {
                  parts: [
                   Raw {
                    content: "-r",
                    position: (62, 46),
                   },
                  ],
                 },
                ],
               },
              },
              Raw {
               content: " \\\n  ",
               position: (62, 50),
              },
              Expression {
               expression: FunctionApplication {
                function: Variable {
                 identifier: "optionalString",
                 position: (63, 13),
                },
                arguments: [
                 BinaryOperation {
                  operator: NotEqualTo,
                  operands: [
                   PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (63, 29),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "wireguardConfig",
                       position: (63, 33),
                      },
                     ],
                    },
                    default: None,
                   },
                   Variable {
                    identifier: "null",
                    position: (63, 52),
                   },
                  ],
                  position: (63, 49),
                 },
                 String {
                  parts: [
                   Raw {
                    content: "-n ",
                    position: (63, 59),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "escapeShellArg",
                      position: (63, 64),
                     },
                     arguments: [
                      PropertyAccess {
                       expression: Variable {
                        identifier: "cfg",
                        position: (63, 79),
                       },
                       attribute_path: AttributePath {
                        attributes: [
                         Raw {
                          content: "wireguardConfig",
                          position: (63, 83),
                         },
                        ],
                       },
                       default: None,
                      },
                     ],
                    },
                   },
                  ],
                 },
                ],
               },
              },
              Raw {
               content: "\n",
               position: (63, 101),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "RestrictAddressFamilies",
               position: (65, 7),
              },
             ],
            },
            List {
             elements: [
              String {
               parts: [
                Raw {
                 content: "AF_NETLINK",
                 position: (67, 10),
                },
               ],
              },
             ],
             position: (65, 33),
            },
           ),
          ],
          recursive: false,
          position: (53, 21),
         },
        ),
       ],
       recursive: false,
       position: (50, 17),
      },
     ),
    ],
    recursive: false,
    position: (7, 4),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}