Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-30467

nuxeoctl rollback template feature leads to unpredictable results

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 10.10
    • Fix Version/s: None

      Description

      Follow-up of NXCLI-67: installation of a buggy package can wreak havoc in nuxeo.conf

      • install nuxeo-10.10 from ZIP
      • nuxeoctl console

        and configure using the wizard:

        • default DB as H2
        • log dir as ./log
        • data dir as ./nxserver2/data
        • development mode to false
        • mail as port 25000
      • once correctly booted shutdown Nuxeo
      • edit nuxeo.conf and change
        • nuxeo.templates=mongodb
        • between line ### BEGIN and ### END where it is said not to edit, add line:
          nuxeo.mongodb.server=localhost:27001
          and save nuxeo.conf
      • copy nuxeo.conf nuxeo.conf.mongo
      • nuxeoctl mp-install /path./to/reproducer-package-1.0-SNAPSHOT.zip
        Installing reproducer-1.0.0-SNAPSHOT
        Template 'reproducer' not found with relative or absolute path (C:\CASES\SUP34436\NXP\nuxeo-server-10.10-tomcat\templates\reproducer). Check your nuxeo.templates parameter, and nuxeo.template.includes for included files.
        
      • bash -c "diff nuxeo.conf nuxeo.conf.mongo"
        258,261c258
        < nuxeo.templates=mongodb,reproducer
        <
        <
        <
        ---
        > nuxeo.templates=mongodb
        268,271c265,268
        < #nuxeo.data.dir=./nxserver2/data
        < nuxeo.data.dir=C:/CASES/SUP34436/NXP/nuxeo-server-10.10-tomcat/./nxserver2/data
        < #nuxeo.log.dir=./log
        < nuxeo.log.dir=C:/CASES/SUP34436/NXP/nuxeo-server-10.10-tomcat/./log
        ---
        > #nuxeo.data.dir=C:/CASES/SUP34436/NXP/nuxeo-server-10.10-tomcat/nxserver/data
        > nuxeo.data.dir=./nxserver2/data
        > #nuxeo.log.dir=C:/CASES/SUP34436/NXP/nuxeo-server-10.10-tomcat/log
        > nuxeo.log.dir=./log
        273a271
        > nuxeo.mongodb.server=localhost:27001
        276a275
        >
        

        Notice that the specific line we manually added for mongo configuration has vanished (very very bad result => it might be better to throw an exception and not attempt to recover)
        Notice that the log dir and data dir line changed. Depending on history of wizard usage, some randomness in the values can be observed.

      • nuxeoctl mp-uninstall reproducer

        does not cure the issue at all

      All of this does not happen if no "rogue" template in the package (see NXCLI-67 for origin of the package)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                pabgrall Patrick Abgrall
                Participants:
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated: