summaryrefslogtreecommitdiffstats
path: root/cli/cli.py
diff options
context:
space:
mode:
authorAlejandro Sirgo Rica <asirgo@soleta.eu>2024-08-26 14:56:29 +0200
committerAlejandro Sirgo Rica <asirgo@soleta.eu>2024-09-02 14:30:15 +0200
commit28ec68df42879a847eab6d314bfbf3a0157d9f45 (patch)
treeb38c92ef39bdf0e809e50ddcc88be6d1245490c7 /cli/cli.py
parentfaebdd5a0daa5fa3dd4b75ac1b341e79d26c83d8 (diff)
repo: sync repo with new API
Add repo update. Example command: update repo --id 20 --address 192.168.1.189 192.168.1.191 --name test --center 1 Use addr instead of ip to pass a list of addresses.
Diffstat (limited to 'cli/cli.py')
-rw-r--r--cli/cli.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/cli/cli.py b/cli/cli.py
index 36fcb36..8e06c19 100644
--- a/cli/cli.py
+++ b/cli/cli.py
@@ -191,7 +191,7 @@ class OgCLI():
OgDisk.setup_disk(self.rest, args[1:])
def update(self, args):
- choices = ['image', 'center', 'room', 'folder']
+ choices = ['image', 'repo', 'center', 'room', 'folder']
parser = argparse.ArgumentParser(prog='ogcli update')
parser.add_argument('update_obj', choices=choices)
@@ -209,6 +209,8 @@ class OgCLI():
OgRoom.update_room(self.rest, args[1:])
elif parsed_args.update_obj == 'folder':
OgFolder.update_folder(self.rest, args[1:])
+ elif parsed_args.update_obj == 'repo':
+ OgRepo.update_repo(self.rest, args[1:])
def delete(self, args):
choices = ['server', 'repo', 'center', 'room', 'client', 'folder']