]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
ceph-dev-new-build/build/setup_rpm: install python2 for el7 1404/head
authorKefu Chai <kchai@redhat.com>
Sat, 5 Oct 2019 02:43:11 +0000 (10:43 +0800)
committerKefu Chai <kchai@redhat.com>
Sat, 5 Oct 2019 03:22:16 +0000 (11:22 +0800)
otherwise we will have

Traceback (most recent call last):
  File "/tmp/venv.pAISkJ09vG/bin/chacractl", line 6, in <module>
    main.ChacraCtl()
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/main.py", line 38, in __init__
    self.main(argv)
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/decorators.py", line 68, in newfunc
    return f(*a, **kw)
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/main.py", line 82, in main
    parser.dispatch()
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/tambo/dispatcher.py", line 21, in dispatch
    result = instance.main()
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/api/exists.py", line 62, in main
    return self.head(url)
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/decorators.py", line 68, in newfunc
    return f(*a, **kw)
  File "/tmp/venv.pAISkJ09vG/lib/python3.6/site-packages/chacractl/util.py", line 65, in inner_wrapper
    for counter in xrange(times):
NameError: name 'xrange' is not defined

Signed-off-by: Kefu Chai <kchai@redhat.com>
ceph-dev-new-build/build/setup_rpm

index 19da81847aa20940cbe579812cd99c10d41b0613..2bd5096166800f904323a5c38dcca0e23d7b80c9 100644 (file)
@@ -89,6 +89,8 @@ if [ "$RELEASE" = 7 ]; then
    fi
 elif [ "$RELEASE" = 8 ]; then
     $SUDO dnf config-manager --set-enabled PowerTools
+    # chacractl is not python3 compatible yet
+    $SUDO dnf -y install python2
 fi
 
 sed -e 's/@//g' < ceph.spec.in > $DIR/ceph.spec