---
Function {
 argument: Destructured {
  identifier: None,
  arguments: [
   DestructuredArgument {
    identifier: "config",
    default: None,
   },
   DestructuredArgument {
    identifier: "pkgs",
    default: None,
   },
   DestructuredArgument {
    identifier: "lib",
    default: None,
   },
  ],
  ellipsis: true,
 },
 definition: LetIn {
  bindings: [
   Binding {
    from: AttributePath {
     parts: [
      Raw {
       content: "cfg",
       position: (2, 5),
      },
     ],
    },
    to: PropertyAccess {
     expression: Variable {
      identifier: "config",
      position: (2, 11),
     },
     attribute_path: AttributePath {
      parts: [
       Raw {
        content: "services",
        position: (2, 18),
       },
       Raw {
        content: "victoriametrics",
        position: (2, 27),
       },
      ],
     },
     default: None,
    },
   },
  ],
  target: Map {
   bindings: [
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "options",
        position: (4, 3),
       },
       Raw {
        content: "services",
        position: (4, 11),
       },
       Raw {
        content: "victoriametrics",
        position: (4, 20),
       },
      ],
     },
     to: With {
      expression: Variable {
       identifier: "lib",
       position: (4, 43),
      },
      target: Map {
       bindings: [
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "enable",
            position: (5, 5),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkEnableOption",
           position: (5, 14),
          },
          arguments: [
           String {
            parts: [
             Raw {
              content: "victoriametrics",
              position: (5, 30),
             },
            ],
            position: (5, 29),
           },
          ],
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "package",
            position: (6, 5),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (6, 15),
          },
          arguments: [
           Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "type",
                 position: (7, 7),
                },
               ],
              },
              to: PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (7, 14),
               },
               attribute_path: AttributePath {
                parts: [
                 Raw {
                  content: "package",
                  position: (7, 20),
                 },
                ],
               },
               default: None,
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "default",
                 position: (8, 7),
                },
               ],
              },
              to: PropertyAccess {
               expression: Variable {
                identifier: "pkgs",
                position: (8, 17),
               },
               attribute_path: AttributePath {
                parts: [
                 Raw {
                  content: "victoriametrics",
                  position: (8, 22),
                 },
                ],
               },
               default: None,
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "defaultText",
                 position: (9, 7),
                },
               ],
              },
              to: FunctionApplication {
               function: Variable {
                identifier: "literalExpression",
                position: (9, 21),
               },
               arguments: [
                String {
                 parts: [
                  Raw {
                   content: "pkgs.victoriametrics",
                   position: (9, 40),
                  },
                 ],
                 position: (9, 39),
                },
               ],
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "description",
                 position: (10, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "The VictoriaMetrics distribution to use.\n",
                 position: (11, 1),
                },
               ],
               position: (10, 21),
              },
             },
            ],
            recursive: false,
            position: (6, 24),
           },
          ],
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "listenAddress",
            position: (14, 5),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (14, 21),
          },
          arguments: [
           Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "default",
                 position: (15, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: ":8428",
                 position: (15, 18),
                },
               ],
               position: (15, 17),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "type",
                 position: (16, 7),
                },
               ],
              },
              to: PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (16, 14),
               },
               attribute_path: AttributePath {
                parts: [
                 Raw {
                  content: "str",
                  position: (16, 20),
                 },
                ],
               },
               default: None,
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "description",
                 position: (17, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "The listen address for the http interface.\n",
                 position: (18, 1),
                },
               ],
               position: (17, 21),
              },
             },
            ],
            recursive: false,
            position: (14, 30),
           },
          ],
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "retentionPeriod",
            position: (21, 5),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (21, 23),
          },
          arguments: [
           Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "type",
                 position: (22, 7),
                },
               ],
              },
              to: PropertyAccess {
               expression: Variable {
                identifier: "types",
                position: (22, 14),
               },
               attribute_path: AttributePath {
                parts: [
                 Raw {
                  content: "int",
                  position: (22, 20),
                 },
                ],
               },
               default: None,
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "default",
                 position: (23, 7),
                },
               ],
              },
              to: Int {
               value: 1,
               position: (23, 17),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "description",
                 position: (24, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "Retention period in months.\n",
                 position: (25, 1),
                },
               ],
               position: (24, 21),
              },
             },
            ],
            recursive: false,
            position: (21, 32),
           },
          ],
         },
        },
        Binding {
         from: AttributePath {
          parts: [
           Raw {
            content: "extraOptions",
            position: (28, 5),
           },
          ],
         },
         to: FunctionApplication {
          function: Variable {
           identifier: "mkOption",
           position: (28, 20),
          },
          arguments: [
           Map {
            bindings: [
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "type",
                 position: (29, 7),
                },
               ],
              },
              to: FunctionApplication {
               function: PropertyAccess {
                expression: Variable {
                 identifier: "types",
                 position: (29, 14),
                },
                attribute_path: AttributePath {
                 parts: [
                  Raw {
                   content: "listOf",
                   position: (29, 20),
                  },
                 ],
                },
                default: None,
               },
               arguments: [
                PropertyAccess {
                 expression: Variable {
                  identifier: "types",
                  position: (29, 27),
                 },
                 attribute_path: AttributePath {
                  parts: [
                   Raw {
                    content: "str",
                    position: (29, 33),
                   },
                  ],
                 },
                 default: None,
                },
               ],
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "default",
                 position: (30, 7),
                },
               ],
              },
              to: List {
               elements: [],
               position: (30, 17),
              },
             },
             Binding {
              from: AttributePath {
               parts: [
                Raw {
                 content: "description",
                 position: (31, 7),
                },
               ],
              },
              to: String {
               parts: [
                Raw {
                 content: "Extra options to pass to VictoriaMetrics. See the README: <link\nxlink:href=\"https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/README.md\" />\nor <command>victoriametrics -help</command> for more\ninformation.\n",
                 position: (32, 1),
                },
               ],
               position: (31, 21),
              },
             },
            ],
            recursive: false,
            position: (28, 29),
           },
          ],
         },
        },
       ],
       recursive: false,
       position: (4, 48),
      },
      position: (4, 38),
     },
    },
    Binding {
     from: AttributePath {
      parts: [
       Raw {
        content: "config",
        position: (39, 3),
       },
      ],
     },
     to: FunctionApplication {
      function: PropertyAccess {
       expression: Variable {
        identifier: "lib",
        position: (39, 12),
       },
       attribute_path: AttributePath {
        parts: [
         Raw {
          content: "mkIf",
          position: (39, 16),
         },
        ],
       },
       default: None,
      },
      arguments: [
       PropertyAccess {
        expression: Variable {
         identifier: "cfg",
         position: (39, 21),
        },
        attribute_path: AttributePath {
         parts: [
          Raw {
           content: "enable",
           position: (39, 25),
          },
         ],
        },
        default: None,
       },
       Map {
        bindings: [
         Binding {
          from: AttributePath {
           parts: [
            Raw {
             content: "systemd",
             position: (40, 5),
            },
            Raw {
             content: "services",
             position: (40, 13),
            },
            Raw {
             content: "victoriametrics",
             position: (40, 22),
            },
           ],
          },
          to: Map {
           bindings: [
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "description",
                position: (41, 7),
               },
              ],
             },
             to: String {
              parts: [
               Raw {
                content: "VictoriaMetrics time series database",
                position: (41, 22),
               },
              ],
              position: (41, 21),
             },
            },
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "after",
                position: (42, 7),
               },
              ],
             },
             to: List {
              elements: [
               String {
                parts: [
                 Raw {
                  content: "network.target",
                  position: (42, 18),
                 },
                ],
                position: (42, 17),
               },
              ],
              position: (42, 15),
             },
            },
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "startLimitBurst",
                position: (43, 7),
               },
              ],
             },
             to: Int {
              value: 5,
              position: (43, 25),
             },
            },
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "serviceConfig",
                position: (44, 7),
               },
              ],
             },
             to: Map {
              bindings: [
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "Restart",
                   position: (45, 9),
                  },
                 ],
                },
                to: String {
                 parts: [
                  Raw {
                   content: "on-failure",
                   position: (45, 20),
                  },
                 ],
                 position: (45, 19),
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "RestartSec",
                   position: (46, 9),
                  },
                 ],
                },
                to: Int {
                 value: 1,
                 position: (46, 22),
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "StateDirectory",
                   position: (47, 9),
                  },
                 ],
                },
                to: String {
                 parts: [
                  Raw {
                   content: "victoriametrics",
                   position: (47, 27),
                  },
                 ],
                 position: (47, 26),
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "DynamicUser",
                   position: (48, 9),
                  },
                 ],
                },
                to: Variable {
                 identifier: "true",
                 position: (48, 23),
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "ExecStart",
                   position: (49, 9),
                  },
                 ],
                },
                to: String {
                 parts: [
                  Raw {
                   content: "",
                   position: (50, 1),
                  },
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (50, 13),
                    },
                    attribute_path: AttributePath {
                     parts: [
                      Raw {
                       content: "package",
                       position: (50, 17),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: "/bin/victoria-metrics \\\n    -storageDataPath=/var/lib/victoriametrics \\\n    -httpListenAddr ",
                   position: (50, 25),
                  },
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (52, 33),
                    },
                    attribute_path: AttributePath {
                     parts: [
                      Raw {
                       content: "listenAddress",
                       position: (52, 37),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: " \\\n    -retentionPeriod ",
                   position: (52, 51),
                  },
                  Expression {
                   expression: FunctionApplication {
                    function: Variable {
                     identifier: "toString",
                     position: (53, 34),
                    },
                    arguments: [
                     PropertyAccess {
                      expression: Variable {
                       identifier: "cfg",
                       position: (53, 43),
                      },
                      attribute_path: AttributePath {
                       parts: [
                        Raw {
                         content: "retentionPeriod",
                         position: (53, 47),
                        },
                       ],
                      },
                      default: None,
                     },
                    ],
                   },
                  },
                  Raw {
                   content: " \\\n    ",
                   position: (53, 63),
                  },
                  Expression {
                   expression: FunctionApplication {
                    function: PropertyAccess {
                     expression: Variable {
                      identifier: "lib",
                      position: (54, 17),
                     },
                     attribute_path: AttributePath {
                      parts: [
                       Raw {
                        content: "escapeShellArgs",
                        position: (54, 21),
                       },
                      ],
                     },
                     default: None,
                    },
                    arguments: [
                     PropertyAccess {
                      expression: Variable {
                       identifier: "cfg",
                       position: (54, 37),
                      },
                      attribute_path: AttributePath {
                       parts: [
                        Raw {
                         content: "extraOptions",
                         position: (54, 41),
                        },
                       ],
                      },
                      default: None,
                     },
                    ],
                   },
                  },
                  Raw {
                   content: "\n",
                   position: (54, 54),
                  },
                 ],
                 position: (49, 21),
                },
               },
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "LimitNOFILE",
                   position: (63, 9),
                  },
                 ],
                },
                to: Int {
                 value: 1048576,
                 position: (63, 23),
                },
               },
              ],
              recursive: false,
              position: (44, 23),
             },
            },
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "wantedBy",
                position: (65, 7),
               },
              ],
             },
             to: List {
              elements: [
               String {
                parts: [
                 Raw {
                  content: "multi-user.target",
                  position: (65, 21),
                 },
                ],
                position: (65, 20),
               },
              ],
              position: (65, 18),
             },
            },
            Binding {
             from: AttributePath {
              parts: [
               Raw {
                content: "postStart",
                position: (67, 7),
               },
              ],
             },
             to: LetIn {
              bindings: [
               Binding {
                from: AttributePath {
                 parts: [
                  Raw {
                   content: "bindAddr",
                   position: (69, 11),
                  },
                 ],
                },
                to: BinaryOperation {
                 operator: Addition,
                 operands: [
                  Parentheses {
                   expression: FunctionApplication {
                    function: PropertyAccess {
                     expression: Variable {
                      identifier: "lib",
                      position: (69, 23),
                     },
                     attribute_path: AttributePath {
                      parts: [
                       Raw {
                        content: "optionalString",
                        position: (69, 27),
                       },
                      ],
                     },
                     default: None,
                    },
                    arguments: [
                     Parentheses {
                      expression: FunctionApplication {
                       function: PropertyAccess {
                        expression: Variable {
                         identifier: "lib",
                         position: (69, 43),
                        },
                        attribute_path: AttributePath {
                         parts: [
                          Raw {
                           content: "hasPrefix",
                           position: (69, 47),
                          },
                         ],
                        },
                        default: None,
                       },
                       arguments: [
                        String {
                         parts: [
                          Raw {
                           content: ":",
                           position: (69, 58),
                          },
                         ],
                         position: (69, 57),
                        },
                        PropertyAccess {
                         expression: Variable {
                          identifier: "cfg",
                          position: (69, 61),
                         },
                         attribute_path: AttributePath {
                          parts: [
                           Raw {
                            content: "listenAddress",
                            position: (69, 65),
                           },
                          ],
                         },
                         default: None,
                        },
                       ],
                      },
                      position: (69, 42),
                     },
                     String {
                      parts: [
                       Raw {
                        content: "127.0.0.1",
                        position: (69, 81),
                       },
                      ],
                      position: (69, 80),
                     },
                    ],
                   },
                   position: (69, 22),
                  },
                  PropertyAccess {
                   expression: Variable {
                    identifier: "cfg",
                    position: (69, 95),
                   },
                   attribute_path: AttributePath {
                    parts: [
                     Raw {
                      content: "listenAddress",
                      position: (69, 99),
                     },
                    ],
                   },
                   default: None,
                  },
                 ],
                 position: (69, 93),
                },
               },
              ],
              target: FunctionApplication {
               function: PropertyAccess {
                expression: Variable {
                 identifier: "lib",
                 position: (71, 9),
                },
                attribute_path: AttributePath {
                 parts: [
                  Raw {
                   content: "mkBefore",
                   position: (71, 13),
                  },
                 ],
                },
                default: None,
               },
               arguments: [
                String {
                 parts: [
                  Raw {
                   content: "until ",
                   position: (72, 1),
                  },
                  Expression {
                   expression: FunctionApplication {
                    function: PropertyAccess {
                     expression: Variable {
                      identifier: "lib",
                      position: (72, 19),
                     },
                     attribute_path: AttributePath {
                      parts: [
                       Raw {
                        content: "getBin",
                        position: (72, 23),
                       },
                      ],
                     },
                     default: None,
                    },
                    arguments: [
                     PropertyAccess {
                      expression: Variable {
                       identifier: "pkgs",
                       position: (72, 30),
                      },
                      attribute_path: AttributePath {
                       parts: [
                        Raw {
                         content: "curl",
                         position: (72, 35),
                        },
                       ],
                      },
                      default: None,
                     },
                    ],
                   },
                  },
                  Raw {
                   content: "/bin/curl -s -o /dev/null http://",
                   position: (72, 40),
                  },
                  Expression {
                   expression: Variable {
                    identifier: "bindAddr",
                    position: (72, 75),
                   },
                  },
                  Raw {
                   content: "/ping; do\n  sleep 1;\ndone\n",
                   position: (72, 84),
                  },
                 ],
                 position: (71, 22),
                },
               ],
              },
              position: (68, 9),
             },
            },
           ],
           recursive: false,
           position: (40, 40),
          },
         },
        ],
        recursive: false,
        position: (39, 32),
       },
      ],
     },
    },
   ],
   recursive: false,
   position: (3, 1),
  },
  position: (2, 1),
 },
 position: (1, 1),
}