Uploaded image for project: 'IT: Release Engineering'
  1. IT: Release Engineering
  2. RELENG-4049

INFO file changes can not be merged if multiple saml entries in access table.

Issue XMLXMLWordPrintable

      The issue can be found in this part of the log (https://jenkins.int.linuxfoundation.org/job/info-master-merge/1498/console)

      15:27:28 INFO: LDAP GROUP IS onap-gerrit-integration-committer
      15:27:28 onap-jenkins-labs for repo integration
      

      There should only be one (1) LDAP group here (onap-gerrit-integration-committer), but the code found two (2)
      (onap-gerrit-integration-committer and onap-jenkins-labs)

      curl -s https://gerrit.onap.org/r/access/?project=integration | tail -n +2|jq  '.[].groups[].name'|grep saml
      "saml/onap-gerrit-integration-committer"
      "saml/onap-jenkins-labs"
      

      The end result is that the script fails with following code

      ERROR: Code: 500 Group onap-gerrit-integration-committer
      15:27:32 onap-jenkins-labs does not exists exiting...
      15:27:32 Build step 'Execute shell' marked build as failure
      

      The following is the issue code snip from ci-management/jjb/ci-management/info-master.sh

      function determine_ldap_group(){
          #TODO Should probably re write this to use the api via lftools.
          get_group(){
              ldap_group="$(curl -s https://"$clonebase"access/?project="$1" \
                | tail -n +2 \
                | jq '.[].groups[].name' \
                | grep saml \
                | awk -F"/" '{print $2}' \
                | sed 's/.$//')"
      

              bthuree Bengt Thuree
              bthuree Bengt Thuree
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: