saltstack-formulas / opensds-formula

Integration with Open Software Defined Storage - Capri release - SuSE/CentOS/Ubuntu
https://opensds.io
Other
4 stars 2 forks source link

Make cinder blockbox fails on CentOS. #68

Closed noelmcloughlin closed 5 years ago

noelmcloughlin commented 5 years ago

Needs to be customized for CentOS

          ID: opensds backend block daemon cinder software build make blockbox
    Function: cmd.run
        Name: make blockbox
      Result: False
     Comment: Command "make blockbox" run
     Started: 03:14:00.080141
    Duration: 3173.534 ms
     Changes:
              ----------
              pid:
                  24647
              retcode:
                  2
              stderr:
                  unable to prepare context: unable to 'git clone' to temporary context directory: error initializing submodules: usage: git submodule [--quiet] add [-b <branch>] [-f|--force] [--name <name>] [--reference <repository>] [--] <repository> [<path>]
                     or: git submodule [--quiet] status [--cached] [--recursive] [--] [<path>...]
                     or: git submodule [--quiet] init [--] [<path>...]
                     or: git submodule [--quiet] deinit [-f|--force] [--] <path>...
                     or: git submodule [--quiet] update [--init] [--remote] [-N|--no-fetch] [-f|--force] [--rebase] [--reference <repository>] [--merge] [--recursive] [--] [<path>...]
                     or: git submodule [--quiet] summary [--cached|--files] [--summary-limit <n>] [commit] [--] [<path>...]
                     or: git submodule [--quiet] foreach [--recursive] <command>
                     or: git submodule [--quiet] sync [--recursive] [--] [<path>...]
                  : exit status 1
                  make: *** [base] Error 1
              stdout:
                  docker build https://git.openstack.org/openstack/loci.git \
                        --build-arg PROJECT=cinder \
                        --build-arg FROM=debian:stretch \
                        --build-arg PROJECT_REF=master \
                        --tag debian-cinder:latest
noelmcloughlin commented 5 years ago

Solution is to upgrade git to version 2.

[root@localhost block-box]# yum install https://centos7.iuscommunity.org/ius-release.rpm && yum swap git git2u

[root@localhost block-box]# make blockbox
docker build https://git.openstack.org/openstack/loci.git \
    --build-arg PROJECT=cinder \
    --build-arg FROM=centos:7  \
    --build-arg PROJECT_REF=master \
    --tag debian-cinder:latest
Sending build context to Docker daemon  250.9kB
Step 1/26 : ARG FROM=ubuntu:xenial
Step 2/26 : FROM ${FROM}
7: Pulling from library/centos
a02a4930cb5d: Downloading [====================================>              ]  54.59MB/75.17MB
noelmcloughlin commented 5 years ago

Works fine