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

Fix sushy_emulator integration in reproducer #1753

Merged
merged 1 commit into from
May 23, 2024

Conversation

cjeanner
Copy link
Contributor

A series of assumptions were made and lead to some issues with the way
the reproducer works.

Mostly, it can happen a hypervisor doesn't have the "zuul" user (for
example a home lab), leading to issues when facts such as
ansible_user_id, ansible_user_dir and related are used in conjuction
with delegate_to.

This patch allows the reproducer to properly works with the
sushy_emulator integration, and fixes some of those assumptions.

It also ensure the molecule tests for reproducer role is triggered uppon
podman and sushy_emulator role modifications.

As a pull request owner and reviewers, I checked that:

  • Appropriate testing is done and actually running
  • Appropriate documentation exists and/or is up-to-date:
    • README in the role

A series of assumptions were made and lead to some issues with the way
the reproducer works.

Mostly, it can happen a hypervisor doesn't have the "zuul" user (for
example a home lab), leading to issues when facts such as
`ansible_user_id`, `ansible_user_dir` and related are used in conjuction
with `delegate_to`.

This patch allows the reproducer to properly works with the
sushy_emulator integration, and fixes some of those assumptions.

It also ensure the molecule tests for reproducer role is triggered uppon
podman and sushy_emulator role modifications.
Copy link
Contributor

openshift-ci bot commented May 23, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@cjeanner cjeanner marked this pull request as ready for review May 23, 2024 07:33
@openshift-ci openshift-ci bot requested review from bshewale and rlandy May 23, 2024 07:33
@cjeanner cjeanner requested review from lewisdenny and removed request for rlandy and bshewale May 23, 2024 07:33
@pablintino
Copy link
Collaborator

/approve
/lgtm

Copy link
Contributor

openshift-ci bot commented May 23, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: pablintino

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 2b380d8 into main May 23, 2024
8 checks passed
@openshift-merge-bot openshift-merge-bot bot deleted the sushy_emulator/integration-fixes branch May 23, 2024 09:13
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the '/home' gets resolved as '/var/home' by realpath, leading to
incorrect path in remote machine.
Without 'realpath', we end up with the '..' in the patch which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not 'zuul' (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the '/home' gets resolved as '/var/home' by realpath, leading to
incorrect path in remote machine.
Without 'realpath', we end up with the '..' in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not 'zuul' (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 5, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 6, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
jcapiitao added a commit to jcapiitao/ci-framework that referenced this pull request Jun 7, 2024
It's a followup of openstack-k8s-operators#1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
openshift-merge-bot bot pushed a commit that referenced this pull request Jun 16, 2024
It's a followup of #1753.
We get rid of realpath filter which resolves the path using the
controller's filesystem [1]. When the filesystems don't match between
the controller and the remote machine, we might hit somme issues.
For instance, when running controller on a Fedora CoreOS system,
the `/home` gets resolved as `/var/home` by realpath, leading to
incorrect path in remote machine.
Without `realpath`, we end up with the `..` in the path which is
a bit uggly but we keep the consistency.

Also, we set the hypervisor ansible user used as the emulator libvirt
user in order to have a more dynamic configuration, otherwise it fails
by default if hypervisor ansible user is not `zuul` (i.e default user).

[1] https://docs.ansible.com/ansible/latest/collections/ansible/builtin/realpath_filter.html#synopsis
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants