Comment 2 for bug 1749204

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tripleo-common (master)

Reviewed: https://review.openstack.org/543965
Committed: https://git.openstack.org/cgit/openstack/tripleo-common/commit/?id=28751a50487fd590d866dff9ef7f288ba4f86fe9
Submitter: Zuul
Branch: master

commit 28751a50487fd590d866dff9ef7f288ba4f86fe9
Author: Michele Baldessari <email address hidden>
Date: Tue Feb 13 15:59:28 2018 +0100

    Fix overcloud export plan

    Currently exporting the plan for the overcloud gives us (note the
    spurious 3600 argument there):
    (undercloud) [stack@undercloud t]$ openstack overcloud plan export overcloud
    Exporting plan overcloud...
    Started Mistral Workflow tripleo.plan_management.v1.export_deployment_plan. Execution ID: 19da7423-ff44-4785-9f1f-237289b60dda
    Error while creating a tarball: Unexpected error while running command.
    Command: /usr/bin/tar -C /tmp/tmpiBEE9d 3600 /tmp/tmpOST_qM --exclude .git --exclude .tox --exclude *.pyc --exclude *.pyo .
    Exit code: 2
    Stdout: u''
    Stderr: u"/usr/bin/tar: You must specify one of the `-Acdtrux' or `--test-label' options\nTry `/usr/bin/tar --help' or `/usr/bin/tar --usage' for more information.\n"
    Exception exporting plan: Error while creating a tarball: Unexpected error while running command.
    Command: /usr/bin/tar -C /tmp/tmpiBEE9d 3600 /tmp/tmpOST_qM --exclude .git --exclude .tox --exclude *.pyc --exclude *.pyo .
    Exit code: 2
    Stdout: u''
    Stderr: u"/usr/bin/tar: You must specify one of the `-Acdtrux' or `--test-label' options\nTry `/usr/bin/tar --help' or `/usr/bin/tar --usage' for more information.\n"

    The reason is that in tripleo_common/actions/plan.py we call the
    following:
    swiftutils.create_and_upload_tarball(
      swift, tmp_dir, self.exports_container, tarball_name,
      self.delete_after)

    The reason is that in
    tripleo_common/utils/swift.py:create_and_upload_tarball() we added
    'tarball_options' as an option but we did not add it at the end and we
    had a caller using a positional argument.

    Let's make sure that 'delete_after' is passed as a named argument.

    Co-Authored-By: Damien Ciabrini <email address hidden>

    Change-Id: Idda2f6da3d84d1c448d941c962a07616863d61bf
    Closes-Bug: #1749204