---
Function {
 argument: None,
 arguments: FunctionArguments {
  arguments: [
   FunctionArgument {
    identifier: "lib",
    default: None,
   },
   FunctionArgument {
    identifier: "pkgs",
    default: None,
   },
   FunctionArgument {
    identifier: "config",
    default: None,
   },
  ],
  ellipsis: true,
 },
 definition: With {
  expression: Variable {
   identifier: "lib",
   position: (3, 6),
  },
  target: LetIn {
   bindings: [
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "cfg",
        position: (7, 3),
       },
      ],
     },
     PropertyAccess {
      expression: Variable {
       identifier: "config",
       position: (7, 9),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "services",
         position: (7, 16),
        },
        Raw {
         content: "syslog-ng",
         position: (7, 25),
        },
       ],
      },
      default: None,
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "syslogngConfig",
        position: (9, 3),
       },
      ],
     },
     FunctionApplication {
      function: PropertyAccess {
       expression: Variable {
        identifier: "pkgs",
        position: (9, 20),
       },
       attribute_path: AttributePath {
        attributes: [
         Raw {
          content: "writeText",
          position: (9, 25),
         },
        ],
       },
       default: None,
      },
      arguments: [
       String {
        parts: [
         Raw {
          content: "syslog-ng.conf",
          position: (9, 36),
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "",
          position: (10, 1),
         },
         Expression {
          expression: PropertyAccess {
           expression: Variable {
            identifier: "cfg",
            position: (10, 7),
           },
           attribute_path: AttributePath {
            attributes: [
             Raw {
              content: "configHeader",
              position: (10, 11),
             },
            ],
           },
           default: None,
          },
         },
         Raw {
          content: "\n",
          position: (10, 24),
         },
         Expression {
          expression: PropertyAccess {
           expression: Variable {
            identifier: "cfg",
            position: (11, 7),
           },
           attribute_path: AttributePath {
            attributes: [
             Raw {
              content: "extraConfig",
              position: (11, 11),
             },
            ],
           },
           default: None,
          },
         },
         Raw {
          content: "\n",
          position: (11, 23),
         },
        ],
       },
      ],
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "ctrlSocket",
        position: (14, 3),
       },
      ],
     },
     String {
      parts: [
       Raw {
        content: "/run/syslog-ng/syslog-ng.ctl",
        position: (14, 17),
       },
      ],
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "pidFile",
        position: (15, 3),
       },
      ],
     },
     String {
      parts: [
       Raw {
        content: "/run/syslog-ng/syslog-ng.pid",
        position: (15, 14),
       },
      ],
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "persistFile",
        position: (16, 3),
       },
      ],
     },
     String {
      parts: [
       Raw {
        content: "/var/syslog-ng/syslog-ng.persist",
        position: (16, 18),
       },
      ],
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "syslogngOptions",
        position: (18, 3),
       },
      ],
     },
     List {
      elements: [
       String {
        parts: [
         Raw {
          content: "--foreground",
          position: (19, 6),
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "--module-path=",
          position: (20, 6),
         },
         Expression {
          expression: FunctionApplication {
           function: Variable {
            identifier: "concatStringsSep",
            position: (20, 22),
           },
           arguments: [
            String {
             parts: [
              Raw {
               content: ":",
               position: (20, 40),
              },
             ],
            },
            BinaryOperation {
             operator: Concatenation,
             operands: [
              List {
               elements: [
                String {
                 parts: [
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (20, 48),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "package",
                       position: (20, 52),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: "/lib/syslog-ng",
                   position: (20, 60),
                  },
                 ],
                },
               ],
               position: (20, 44),
              },
              PropertyAccess {
               expression: Variable {
                identifier: "cfg",
                position: (20, 80),
               },
               attribute_path: AttributePath {
                attributes: [
                 Raw {
                  content: "extraModulePaths",
                  position: (20, 84),
                 },
                ],
               },
               default: None,
              },
             ],
             position: (20, 77),
            },
           ],
          },
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "--cfgfile=",
          position: (21, 6),
         },
         Expression {
          expression: Variable {
           identifier: "syslogngConfig",
           position: (21, 18),
          },
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "--control=",
          position: (22, 6),
         },
         Expression {
          expression: Variable {
           identifier: "ctrlSocket",
           position: (22, 18),
          },
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "--persist-file=",
          position: (23, 6),
         },
         Expression {
          expression: Variable {
           identifier: "persistFile",
           position: (23, 23),
          },
         },
        ],
       },
       String {
        parts: [
         Raw {
          content: "--pidfile=",
          position: (24, 6),
         },
         Expression {
          expression: Variable {
           identifier: "pidFile",
           position: (24, 18),
          },
         },
        ],
       },
      ],
      position: (18, 21),
     },
    ),
   ],
   target: Map {
    bindings: [
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "imports",
         position: (28, 3),
        },
       ],
      },
      List {
       elements: [
        FunctionApplication {
         function: Variable {
          identifier: "mkRemovedOptionModule",
          position: (29, 6),
         },
         arguments: [
          List {
           elements: [
            String {
             parts: [
              Raw {
               content: "services",
               position: (29, 31),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "syslog-ng",
               position: (29, 42),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "serviceName",
               position: (29, 54),
              },
             ],
            },
           ],
           position: (29, 28),
          },
          String {
           parts: [],
          },
         ],
        },
        FunctionApplication {
         function: Variable {
          identifier: "mkRemovedOptionModule",
          position: (30, 6),
         },
         arguments: [
          List {
           elements: [
            String {
             parts: [
              Raw {
               content: "services",
               position: (30, 31),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "syslog-ng",
               position: (30, 42),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "listenToJournal",
               position: (30, 54),
              },
             ],
            },
           ],
           position: (30, 28),
          },
          String {
           parts: [],
          },
         ],
        },
       ],
       position: (28, 13),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "options",
         position: (33, 3),
        },
       ],
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "services",
            position: (35, 5),
           },
           Raw {
            content: "syslog-ng",
            position: (35, 14),
           },
          ],
         },
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "enable",
               position: (36, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (36, 16),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (37, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (37, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "bool",
                     position: (37, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (38, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "false",
                  position: (38, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (39, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "Whether to enable the syslog-ng daemon.\n",
                    position: (40, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (36, 25),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "package",
               position: (43, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (43, 17),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (44, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (44, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "package",
                     position: (44, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (45, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "pkgs",
                   position: (45, 19),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "syslogng",
                     position: (45, 24),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "defaultText",
                    position: (46, 9),
                   },
                  ],
                 },
                 FunctionApplication {
                  function: Variable {
                   identifier: "literalExpression",
                   position: (46, 23),
                  },
                  arguments: [
                   String {
                    parts: [
                     Raw {
                      content: "pkgs.syslogng",
                      position: (46, 42),
                     },
                    ],
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (47, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "The package providing syslog-ng binaries.\n",
                    position: (48, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (43, 26),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "extraModulePaths",
               position: (51, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (51, 26),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (52, 9),
                   },
                  ],
                 },
                 FunctionApplication {
                  function: PropertyAccess {
                   expression: Variable {
                    identifier: "types",
                    position: (52, 16),
                   },
                   attribute_path: AttributePath {
                    attributes: [
                     Raw {
                      content: "listOf",
                      position: (52, 22),
                     },
                    ],
                   },
                   default: None,
                  },
                  arguments: [
                   PropertyAccess {
                    expression: Variable {
                     identifier: "types",
                     position: (52, 29),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "str",
                       position: (52, 35),
                      },
                     ],
                    },
                    default: None,
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (53, 9),
                   },
                  ],
                 },
                 List {
                  elements: [],
                  position: (53, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "example",
                    position: (54, 9),
                   },
                  ],
                 },
                 FunctionApplication {
                  function: Variable {
                   identifier: "literalExpression",
                   position: (54, 19),
                  },
                  arguments: [
                   String {
                    parts: [
                     Raw {
                      content: "[ \"",
                      position: (55, 1),
                     },
                     Raw {
                      content: "$",
                      position: (55, 14),
                     },
                     Raw {
                      content: "{pkgs.syslogng_incubator}/lib/syslog-ng\" ]\n",
                      position: (55, 17),
                     },
                    ],
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (57, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "A list of paths that should be included in syslog-ng's\n<literal>--module-path</literal> option. They should usually\nend in <literal>/lib/syslog-ng</literal>\n",
                    position: (58, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (51, 35),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "extraConfig",
               position: (63, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (63, 21),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (64, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (64, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "lines",
                     position: (64, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (65, 9),
                   },
                  ],
                 },
                 String {
                  parts: [],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (66, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "Configuration added to the end of <literal>syslog-ng.conf</literal>.\n",
                    position: (67, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (63, 30),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "configHeader",
               position: (70, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "mkOption",
              position: (70, 22),
             },
             arguments: [
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "type",
                    position: (71, 9),
                   },
                  ],
                 },
                 PropertyAccess {
                  expression: Variable {
                   identifier: "types",
                   position: (71, 16),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "lines",
                     position: (71, 22),
                    },
                   ],
                  },
                  default: None,
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "default",
                    position: (72, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "@version: 3.6\n@include \"scl.conf\"\n",
                    position: (73, 1),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "description",
                    position: (76, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "The very first lines of the configuration file. Should usually contain\nthe syslog-ng version header.\n",
                    position: (77, 1),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (70, 31),
              },
             ],
            },
           ),
          ],
          recursive: false,
          position: (35, 26),
         },
        ),
       ],
       recursive: false,
       position: (33, 13),
      },
     ),
     KeyValue(
      AttributePath {
       attributes: [
        Raw {
         content: "config",
         position: (84, 3),
        },
       ],
      },
      FunctionApplication {
       function: Variable {
        identifier: "mkIf",
        position: (84, 12),
       },
       arguments: [
        PropertyAccess {
         expression: Variable {
          identifier: "cfg",
          position: (84, 17),
         },
         attribute_path: AttributePath {
          attributes: [
           Raw {
            content: "enable",
            position: (84, 21),
           },
          ],
         },
         default: None,
        },
        Map {
         bindings: [
          KeyValue(
           AttributePath {
            attributes: [
             Raw {
              content: "systemd",
              position: (85, 5),
             },
             Raw {
              content: "services",
              position: (85, 13),
             },
             Raw {
              content: "syslog-ng",
              position: (85, 22),
             },
            ],
           },
           Map {
            bindings: [
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "description",
                 position: (86, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "syslog-ng daemon",
                 position: (86, 22),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "preStart",
                 position: (87, 7),
                },
               ],
              },
              String {
               parts: [
                Raw {
                 content: "mkdir -p /{var,run}/syslog-ng",
                 position: (87, 19),
                },
               ],
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "wantedBy",
                 position: (88, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "multi-user.target",
                   position: (88, 21),
                  },
                 ],
                },
               ],
               position: (88, 18),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "after",
                 position: (89, 7),
                },
               ],
              },
              List {
               elements: [
                String {
                 parts: [
                  Raw {
                   content: "multi-user.target",
                   position: (89, 18),
                  },
                 ],
                },
               ],
               position: (89, 15),
              },
             ),
             KeyValue(
              AttributePath {
               attributes: [
                Raw {
                 content: "serviceConfig",
                 position: (90, 7),
                },
               ],
              },
              Map {
               bindings: [
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "Type",
                    position: (91, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "notify",
                    position: (91, 17),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "PIDFile",
                    position: (92, 9),
                   },
                  ],
                 },
                 Variable {
                  identifier: "pidFile",
                  position: (92, 19),
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "StandardOutput",
                    position: (93, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "null",
                    position: (93, 27),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "Restart",
                    position: (94, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Raw {
                    content: "on-failure",
                    position: (94, 20),
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "ExecStart",
                    position: (95, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Expression {
                    expression: PropertyAccess {
                     expression: Variable {
                      identifier: "cfg",
                      position: (95, 24),
                     },
                     attribute_path: AttributePath {
                      attributes: [
                       Raw {
                        content: "package",
                        position: (95, 28),
                       },
                      ],
                     },
                     default: None,
                    },
                   },
                   Raw {
                    content: "/sbin/syslog-ng ",
                    position: (95, 36),
                   },
                   Expression {
                    expression: FunctionApplication {
                     function: Variable {
                      identifier: "concatStringsSep",
                      position: (95, 54),
                     },
                     arguments: [
                      String {
                       parts: [
                        Raw {
                         content: " ",
                         position: (95, 72),
                        },
                       ],
                      },
                      Variable {
                       identifier: "syslogngOptions",
                       position: (95, 75),
                      },
                     ],
                    },
                   },
                  ],
                 },
                ),
                KeyValue(
                 AttributePath {
                  attributes: [
                   Raw {
                    content: "ExecReload",
                    position: (96, 9),
                   },
                  ],
                 },
                 String {
                  parts: [
                   Expression {
                    expression: PropertyAccess {
                     expression: Variable {
                      identifier: "pkgs",
                      position: (96, 25),
                     },
                     attribute_path: AttributePath {
                      attributes: [
                       Raw {
                        content: "coreutils",
                        position: (96, 30),
                       },
                      ],
                     },
                     default: None,
                    },
                   },
                   Raw {
                    content: "/bin/kill -HUP $MAINPID",
                    position: (96, 40),
                   },
                  ],
                 },
                ),
               ],
               recursive: false,
               position: (90, 23),
              },
             ),
            ],
            recursive: false,
            position: (85, 34),
           },
          ),
         ],
         recursive: false,
         position: (84, 28),
        },
       ],
      },
     ),
    ],
    recursive: false,
    position: (27, 4),
   },
   position: (5, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}