---
Function {
 argument: None,
 arguments: FunctionArguments {
  arguments: [
   FunctionArgument {
    identifier: "lib",
    default: None,
   },
   FunctionArgument {
    identifier: "config",
    default: None,
   },
  ],
  ellipsis: true,
 },
 definition: LetIn {
  bindings: [
   Inherit(
    Some(
     PropertyAccess {
      expression: Variable {
       identifier: "lib",
       position: (5, 12),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "attrsets",
         position: (5, 16),
        },
       ],
      },
      default: None,
     },
    ),
    [
     Raw {
      content: "hasAttr",
      position: (5, 26),
     },
    ],
   ),
   Inherit(
    Some(
     PropertyAccess {
      expression: Variable {
       identifier: "lib",
       position: (6, 12),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "modules",
         position: (6, 16),
        },
       ],
      },
      default: None,
     },
    ),
    [
     Raw {
      content: "mkDefault",
      position: (6, 25),
     },
     Raw {
      content: "mkIf",
      position: (6, 35),
     },
    ],
   ),
   Inherit(
    Some(
     PropertyAccess {
      expression: Variable {
       identifier: "lib",
       position: (7, 12),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "options",
         position: (7, 16),
        },
       ],
      },
      default: None,
     },
    ),
    [
     Raw {
      content: "mkEnableOption",
      position: (7, 25),
     },
     Raw {
      content: "mkOption",
      position: (7, 40),
     },
    ],
   ),
   Inherit(
    Some(
     PropertyAccess {
      expression: Variable {
       identifier: "lib",
       position: (8, 12),
      },
      attribute_path: AttributePath {
       attributes: [
        Raw {
         content: "types",
         position: (8, 16),
        },
       ],
      },
      default: None,
     },
    ),
    [
     Raw {
      content: "nonEmptyStr",
      position: (8, 23),
     },
     Raw {
      content: "nullOr",
      position: (8, 35),
     },
    ],
   ),
   KeyValue(
    AttributePath {
     attributes: [
      Raw {
       content: "options",
       position: (10, 3),
      },
      Raw {
       content: "services",
       position: (10, 11),
      },
      Raw {
       content: "tsmBackup",
       position: (10, 20),
      },
     ],
    },
    Map {
     bindings: [
      KeyValue(
       AttributePath {
        attributes: [
         Raw {
          content: "enable",
          position: (11, 5),
         },
        ],
       },
       FunctionApplication {
        function: Variable {
         identifier: "mkEnableOption",
         position: (11, 14),
        },
        arguments: [
         String {
          parts: [
           Raw {
            content: "automatic backups with the\nIBM Spectrum Protect (Tivoli Storage Manager, TSM) client.\nThis also enables\n<option>programs.tsmClient.enable</option>\n",
            position: (12, 1),
           },
          ],
         },
        ],
       },
      ),
      KeyValue(
       AttributePath {
        attributes: [
         Raw {
          content: "command",
          position: (17, 5),
         },
        ],
       },
       FunctionApplication {
        function: Variable {
         identifier: "mkOption",
         position: (17, 15),
        },
        arguments: [
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "type",
               position: (18, 7),
              },
             ],
            },
            Variable {
             identifier: "nonEmptyStr",
             position: (18, 14),
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "default",
               position: (19, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "backup",
               position: (19, 18),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "example",
               position: (20, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "incr",
               position: (20, 18),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "description",
               position: (21, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "The actual command passed to the\n<literal>dsmc</literal> executable to start the backup.\n",
               position: (22, 1),
              },
             ],
            },
           ),
          ],
          recursive: false,
          position: (17, 24),
         },
        ],
       },
      ),
      KeyValue(
       AttributePath {
        attributes: [
         Raw {
          content: "servername",
          position: (26, 5),
         },
        ],
       },
       FunctionApplication {
        function: Variable {
         identifier: "mkOption",
         position: (26, 18),
        },
        arguments: [
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "type",
               position: (27, 7),
              },
             ],
            },
            Variable {
             identifier: "nonEmptyStr",
             position: (27, 14),
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "example",
               position: (28, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "mainTsmServer",
               position: (28, 18),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "description",
               position: (29, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "Create a systemd system service\n<literal>tsm-backup.service</literal> that starts\na backup based on the given servername's stanza.\nNote that this server's\n<option>passwdDir</option> will default to\n<filename>/var/lib/tsm-backup/password</filename>\n(but may be overridden);\nalso, the service will use\n<filename>/var/lib/tsm-backup</filename> as\n<literal>HOME</literal> when calling\n<literal>dsmc</literal>.\n",
               position: (30, 1),
              },
             ],
            },
           ),
          ],
          recursive: false,
          position: (26, 27),
         },
        ],
       },
      ),
      KeyValue(
       AttributePath {
        attributes: [
         Raw {
          content: "autoTime",
          position: (43, 5),
         },
        ],
       },
       FunctionApplication {
        function: Variable {
         identifier: "mkOption",
         position: (43, 16),
        },
        arguments: [
         Map {
          bindings: [
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "type",
               position: (44, 7),
              },
             ],
            },
            FunctionApplication {
             function: Variable {
              identifier: "nullOr",
              position: (44, 14),
             },
             arguments: [
              Variable {
               identifier: "nonEmptyStr",
               position: (44, 21),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "default",
               position: (45, 7),
              },
             ],
            },
            Variable {
             identifier: "null",
             position: (45, 17),
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "example",
               position: (46, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "12:00",
               position: (46, 18),
              },
             ],
            },
           ),
           KeyValue(
            AttributePath {
             attributes: [
              Raw {
               content: "description",
               position: (47, 7),
              },
             ],
            },
            String {
             parts: [
              Raw {
               content: "The backup service will be invoked\nautomatically at the given date/time,\nwhich must be in the format described in\n<citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>5</manvolnum></citerefentry>.\nThe default <literal>null</literal>\ndisables automatic backups.\n",
               position: (48, 1),
              },
             ],
            },
           ),
          ],
          recursive: false,
          position: (43, 25),
         },
        ],
       },
      ),
     ],
     recursive: false,
     position: (10, 32),
    },
   ),
   KeyValue(
    AttributePath {
     attributes: [
      Raw {
       content: "cfg",
       position: (58, 3),
      },
     ],
    },
    PropertyAccess {
     expression: Variable {
      identifier: "config",
      position: (58, 9),
     },
     attribute_path: AttributePath {
      attributes: [
       Raw {
        content: "services",
        position: (58, 16),
       },
       Raw {
        content: "tsmBackup",
        position: (58, 25),
       },
      ],
     },
     default: None,
    },
   ),
   KeyValue(
    AttributePath {
     attributes: [
      Raw {
       content: "cfgPrg",
       position: (59, 3),
      },
     ],
    },
    PropertyAccess {
     expression: Variable {
      identifier: "config",
      position: (59, 12),
     },
     attribute_path: AttributePath {
      attributes: [
       Raw {
        content: "programs",
        position: (59, 19),
       },
       Raw {
        content: "tsmClient",
        position: (59, 28),
       },
      ],
     },
     default: None,
    },
   ),
   KeyValue(
    AttributePath {
     attributes: [
      Raw {
       content: "assertions",
       position: (61, 3),
      },
     ],
    },
    List {
     elements: [
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "assertion",
            position: (63, 7),
           },
          ],
         },
         FunctionApplication {
          function: Variable {
           identifier: "hasAttr",
           position: (63, 19),
          },
          arguments: [
           PropertyAccess {
            expression: Variable {
             identifier: "cfg",
             position: (63, 27),
            },
            attribute_path: AttributePath {
             attributes: [
              Raw {
               content: "servername",
               position: (63, 31),
              },
             ],
            },
            default: None,
           },
           PropertyAccess {
            expression: Variable {
             identifier: "cfgPrg",
             position: (63, 42),
            },
            attribute_path: AttributePath {
             attributes: [
              Raw {
               content: "servers",
               position: (63, 49),
              },
             ],
            },
            default: None,
           },
          ],
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "message",
            position: (64, 7),
           },
          ],
         },
         String {
          parts: [
           Raw {
            content: "TSM service servername not found in list of servers",
            position: (64, 18),
           },
          ],
         },
        ),
       ],
       recursive: false,
       position: (62, 5),
      },
      Map {
       bindings: [
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "assertion",
            position: (67, 7),
           },
          ],
         },
         PropertyAccess {
          expression: Variable {
           identifier: "cfgPrg",
           position: (67, 19),
          },
          attribute_path: AttributePath {
           attributes: [
            Raw {
             content: "servers",
             position: (67, 26),
            },
            Expression {
             expression: PropertyAccess {
              expression: Variable {
               identifier: "cfg",
               position: (67, 36),
              },
              attribute_path: AttributePath {
               attributes: [
                Raw {
                 content: "servername",
                 position: (67, 40),
                },
               ],
              },
              default: None,
             },
            },
            Raw {
             content: "genPasswd",
             position: (67, 52),
            },
           ],
          },
          default: None,
         },
        ),
        KeyValue(
         AttributePath {
          attributes: [
           Raw {
            content: "message",
            position: (68, 7),
           },
          ],
         },
         String {
          parts: [
           Raw {
            content: "TSM service requires automatic password generation",
            position: (68, 18),
           },
          ],
         },
        ),
       ],
       recursive: false,
       position: (66, 5),
      },
     ],
     position: (61, 16),
    },
   ),
  ],
  target: Map {
   bindings: [
    Inherit(
     None,
     [
      Raw {
       content: "options",
       position: (76, 11),
      },
     ],
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "config",
        position: (78, 3),
       },
      ],
     },
     FunctionApplication {
      function: Variable {
       identifier: "mkIf",
       position: (78, 12),
      },
      arguments: [
       PropertyAccess {
        expression: Variable {
         identifier: "cfg",
         position: (78, 17),
        },
        attribute_path: AttributePath {
         attributes: [
          Raw {
           content: "enable",
           position: (78, 21),
          },
         ],
        },
        default: None,
       },
       Map {
        bindings: [
         Inherit(
          None,
          [
           Raw {
            content: "assertions",
            position: (79, 13),
           },
          ],
         ),
         KeyValue(
          AttributePath {
           attributes: [
            Raw {
             content: "programs",
             position: (80, 5),
            },
            Raw {
             content: "tsmClient",
             position: (80, 14),
            },
            Raw {
             content: "enable",
             position: (80, 24),
            },
           ],
          },
          Variable {
           identifier: "true",
           position: (80, 33),
          },
         ),
         KeyValue(
          AttributePath {
           attributes: [
            Raw {
             content: "programs",
             position: (81, 5),
            },
            Raw {
             content: "tsmClient",
             position: (81, 14),
            },
            Raw {
             content: "servers",
             position: (81, 24),
            },
            Expression {
             expression: PropertyAccess {
              expression: Variable {
               identifier: "cfg",
               position: (81, 34),
              },
              attribute_path: AttributePath {
               attributes: [
                Raw {
                 content: "servername",
                 position: (81, 38),
                },
               ],
              },
              default: None,
             },
            },
            Raw {
             content: "passwdDir",
             position: (81, 50),
            },
           ],
          },
          FunctionApplication {
           function: Variable {
            identifier: "mkDefault",
            position: (82, 7),
           },
           arguments: [
            String {
             parts: [
              Raw {
               content: "/var/lib/tsm-backup/password",
               position: (82, 18),
              },
             ],
            },
           ],
          },
         ),
         KeyValue(
          AttributePath {
           attributes: [
            Raw {
             content: "systemd",
             position: (83, 5),
            },
            Raw {
             content: "services",
             position: (83, 13),
            },
            Raw {
             content: "tsm-backup",
             position: (83, 22),
            },
           ],
          },
          Map {
           bindings: [
            KeyValue(
             AttributePath {
              attributes: [
               Raw {
                content: "description",
                position: (84, 7),
               },
              ],
             },
             String {
              parts: [
               Raw {
                content: "IBM Spectrum Protect (Tivoli Storage Manager) Backup",
                position: (84, 22),
               },
              ],
             },
            ),
            KeyValue(
             AttributePath {
              attributes: [
               Raw {
                content: "environment",
                position: (87, 7),
               },
               Raw {
                content: "DSM_LOG",
                position: (87, 19),
               },
              ],
             },
             String {
              parts: [
               Raw {
                content: "/var/log/tsm-backup/",
                position: (87, 30),
               },
              ],
             },
            ),
            KeyValue(
             AttributePath {
              attributes: [
               Raw {
                content: "environment",
                position: (89, 7),
               },
               Raw {
                content: "HOME",
                position: (89, 19),
               },
              ],
             },
             String {
              parts: [
               Raw {
                content: "/var/lib/tsm-backup",
                position: (89, 27),
               },
              ],
             },
            ),
            KeyValue(
             AttributePath {
              attributes: [
               Raw {
                content: "serviceConfig",
                position: (90, 7),
               },
              ],
             },
             Map {
              bindings: [
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "SuccessExitStatus",
                   position: (93, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "4 8",
                   position: (93, 30),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ExecStart",
                   position: (96, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfgPrg",
                     position: (97, 14),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "wrappedPackage",
                       position: (97, 21),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: "/bin/dsmc ",
                   position: (97, 36),
                  },
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (97, 48),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "command",
                       position: (97, 52),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: " -se='",
                   position: (97, 60),
                  },
                  Expression {
                   expression: PropertyAccess {
                    expression: Variable {
                     identifier: "cfg",
                     position: (97, 68),
                    },
                    attribute_path: AttributePath {
                     attributes: [
                      Raw {
                       content: "servername",
                       position: (97, 72),
                      },
                     ],
                    },
                    default: None,
                   },
                  },
                  Raw {
                   content: "' -optfile=/dev/null",
                   position: (97, 83),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "LogsDirectory",
                   position: (98, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "tsm-backup",
                   position: (98, 26),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "StateDirectory",
                   position: (99, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "tsm-backup",
                   position: (99, 27),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "StateDirectoryMode",
                   position: (100, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "0750",
                   position: (100, 31),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "LockPersonality",
                   position: (102, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (102, 27),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "NoNewPrivileges",
                   position: (103, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (103, 27),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "PrivateDevices",
                   position: (104, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (104, 26),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectClock",
                   position: (107, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (107, 24),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectControlGroups",
                   position: (108, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (108, 32),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectHome",
                   position: (109, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "read-only",
                   position: (109, 24),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectHostname",
                   position: (110, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (110, 27),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectKernelLogs",
                   position: (111, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (111, 29),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectKernelModules",
                   position: (112, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (112, 32),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectKernelTunables",
                   position: (113, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (113, 33),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectProc",
                   position: (114, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "noaccess",
                   position: (114, 24),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "ProtectSystem",
                   position: (115, 9),
                  },
                 ],
                },
                String {
                 parts: [
                  Raw {
                   content: "strict",
                   position: (115, 26),
                  },
                 ],
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "RestrictNamespaces",
                   position: (116, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (116, 30),
                },
               ),
               KeyValue(
                AttributePath {
                 attributes: [
                  Raw {
                   content: "RestrictSUIDSGID",
                   position: (117, 9),
                  },
                 ],
                },
                Variable {
                 identifier: "true",
                 position: (117, 28),
                },
               ),
              ],
              recursive: false,
              position: (90, 23),
             },
            ),
            KeyValue(
             AttributePath {
              attributes: [
               Raw {
                content: "startAt",
                position: (119, 7),
               },
              ],
             },
             FunctionApplication {
              function: Variable {
               identifier: "mkIf",
               position: (119, 17),
              },
              arguments: [
               BinaryOperation {
                operator: NotEqualTo,
                operands: [
                 PropertyAccess {
                  expression: Variable {
                   identifier: "cfg",
                   position: (119, 23),
                  },
                  attribute_path: AttributePath {
                   attributes: [
                    Raw {
                     content: "autoTime",
                     position: (119, 27),
                    },
                   ],
                  },
                  default: None,
                 },
                 Variable {
                  identifier: "null",
                  position: (119, 37),
                 },
                ],
                position: (119, 35),
               },
               PropertyAccess {
                expression: Variable {
                 identifier: "cfg",
                 position: (119, 43),
                },
                attribute_path: AttributePath {
                 attributes: [
                  Raw {
                   content: "autoTime",
                   position: (119, 47),
                  },
                 ],
                },
                default: None,
               },
              ],
             },
            ),
           ],
           recursive: false,
           position: (83, 35),
          },
         ),
        ],
        recursive: false,
        position: (78, 28),
       },
      ],
     },
    ),
    KeyValue(
     AttributePath {
      attributes: [
       Raw {
        content: "meta",
        position: (123, 3),
       },
       Raw {
        content: "maintainers",
        position: (123, 8),
       },
      ],
     },
     List {
      elements: [
       PropertyAccess {
        expression: Variable {
         identifier: "lib",
         position: (123, 24),
        },
        attribute_path: AttributePath {
         attributes: [
          Raw {
           content: "maintainers",
           position: (123, 28),
          },
          Raw {
           content: "yarny",
           position: (123, 40),
          },
         ],
        },
        default: None,
       },
      ],
      position: (123, 22),
     },
    ),
   ],
   recursive: false,
   position: (74, 1),
  },
  position: (3, 1),
 },
 position: (1, 1),
}