Parcourir la source

cmd_db: use rwurl for version subcommands

Daniel-Constantin Mierla il y a 5 ans
Parent
commit
dabc1b4cf5
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      kamcli/commands/cmd_db.py

+ 2 - 2
kamcli/commands/cmd_db.py

@@ -694,7 +694,7 @@ def db_version_set(ctx, vertable, table, version):
         <table> - Name of the table to set the version for
         <table> - Name of the table to set the version for
         <version> - Version number
         <version> - Version number
     """
     """
-    e = create_engine(ctx.gconfig.get("db", "adminurl"))
+    e = create_engine(ctx.gconfig.get("db", "rwurl"))
     e.execute(
     e.execute(
         "delete from {0} where table_name={1!r}".format(
         "delete from {0} where table_name={1!r}".format(
             vertable.encode("ascii", "ignore").decode(),
             vertable.encode("ascii", "ignore").decode(),
@@ -743,7 +743,7 @@ def db_version_get(ctx, vertable, oformat, ostyle, table):
     Parameters:
     Parameters:
         <table> - Name of the table to get the version for
         <table> - Name of the table to get the version for
     """
     """
-    e = create_engine(ctx.gconfig.get("db", "adminurl"))
+    e = create_engine(ctx.gconfig.get("db", "rwurl"))
     res = e.execute(
     res = e.execute(
         "select * from {0} where table_name={1!r}".format(
         "select * from {0} where table_name={1!r}".format(
             vertable.encode("ascii", "ignore").decode(),
             vertable.encode("ascii", "ignore").decode(),