]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume: fix the type mismatch, covert the tries and interval to int from string. 32106/head
authortaodd <dongdong.tao@canonical.com>
Sun, 8 Dec 2019 02:10:59 +0000 (10:10 +0800)
committertaodd <dongdong.tao@canonical.com>
Sun, 8 Dec 2019 02:26:42 +0000 (10:26 +0800)
Fixes: https://tracker.ceph.com/issues/43186
Signed-off-by: dongdong tao <dongdong.tao@canonical.com>
src/ceph-volume/ceph_volume/systemd/main.py

index e4d244f5d56d22c9167286861d4496b9944120f5..2cb1d1b80ad47e87f970faa03ca089e9121c7a40 100644 (file)
@@ -92,8 +92,8 @@ def main(args=None):
     logger.info('parsed sub-command: %s, extra data: %s', sub_command, extra_data)
     command = ['ceph-volume', sub_command, 'trigger', extra_data]
 
-    tries = os.environ.get('CEPH_VOLUME_SYSTEMD_TRIES', 30)
-    interval = os.environ.get('CEPH_VOLUME_SYSTEMD_INTERVAL', 5)
+    tries = int(os.environ.get('CEPH_VOLUME_SYSTEMD_TRIES', 30))
+    interval = int(os.environ.get('CEPH_VOLUME_SYSTEMD_INTERVAL', 5))
     while tries > 0:
         try:
             # don't log any output to the terminal, just rely on stderr/stdout