Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepare playbook from URL does not work for imported plans #3349

Open
The-Mule opened this issue Nov 8, 2024 · 0 comments
Open

Prepare playbook from URL does not work for imported plans #3349

The-Mule opened this issue Nov 8, 2024 · 0 comments

Comments

@The-Mule
Copy link
Contributor

The-Mule commented Nov 8, 2024

When running a an imported plan that contains Ansible playbook specified as URL, prepare phase fails claiming that the playbook does not exist.

Importing plan:

/fips-enabled:
  plan:
    import:
      url: https://.../tests/libkcapi
      name: /plans/ci/fips-enabled

Actual plan:

summary: CI test plan

execute:
  how: tmt

/fips-enabled:
  context+:
    fips: enabled
  prepare+:
    - name: Enable FIPS mode
      how: ansible
      order: 99
      playbook:
        - https://.../playbooks/enable-fips.yaml
 ...

Playbook URL is correct, the playbook is reachable. This can be proved by running the actual plan directly - it just works:

   prepare
        ...
        queued prepare task #1: Enable beaker-tasks on default-0
        ... 
        prepare task #4: Enable FIPS mode on default-0
        how: ansible
        name: Enable FIPS mode
        playbook: https://.../playbooks/enable-fips.yaml
        playbook-path: playbook-isftw5ft.yml
        ok: 1 task
        changed: 1 task
        skipped: 1 task
        ...
        summary: 4 preparations applied

On the other hand when running the importing one that imports the actual one, it does not work:

prepare
        ...
        queued prepare task #4: Enable FIPS mode on default-0
        ...
        prepare task #4: Enable FIPS mode on default-0
        how: ansible
        name: Enable FIPS mode
        playbook: https://.../playbooks/enable-fips.yaml
        playbook-path: playbook-0ldv71eq.yml
        fail: Playbook '/var/ARTIFACTS/work-fips-enabled-buildroot-disabled0niufoxa/import/plans/ci/fips-enabled-buildroot-disabled/playbook-0ldv71eq.yml' does not exist.

I believe the issue is that TMT downloads the playbook into different directory than than "/import/plans/..." directory (maybe the actual run directory, ie. "/plans/..."?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant