From 7ecc2b5aa6a3d2cb10c581d6d04e7e567bfcddd0 Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 21 Sep 2024 05:42:26 +0100 Subject: [PATCH] add readme --- README.md | 7 +++++++ app.py | 24 ++++++++++++------------ 2 files changed, 19 insertions(+), 12 deletions(-) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..a7bf3e2 --- /dev/null +++ b/README.md @@ -0,0 +1,7 @@ +# Traefik Helper (for Kubernetes) + +This is a helper for [Traefik](https://traefik.io/) on Kubernetes. It allows you to add and delete services from a simple cli. + +## Todo + +- [ ] Use the Traefik api to list all services diff --git a/app.py b/app.py index f64b345..6bb4a9a 100644 --- a/app.py +++ b/app.py @@ -7,19 +7,19 @@ from commands import addService from commands import deleteService class TraefikHelper(App): - def __init__(self): - super().__init__( - description='Traefik Helper', - version='0.1', - command_manager=CommandManager('commands'), - deferred_help=False, + def __init__(self): + super().__init__( + description='Traefik Helper', + version='0.1', + command_manager=CommandManager('commands'), + deferred_help=False, + ) - ) def main(argv=sys.argv[1:]): - app = TraefikHelper() - app.command_manager.add_command('add', addService.AddService) - app.command_manager.add_command('delete', deleteService.DeleteService) - return app.run(argv) + app = TraefikHelper() + app.command_manager.add_command('add', addService.AddService) + app.command_manager.add_command('delete', deleteService.DeleteService) + return app.run(argv) if __name__ == '__main__': - sys.exit(main(sys.argv[1:])) \ No newline at end of file + sys.exit(main(sys.argv[1:])) \ No newline at end of file