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

Pulp user password - required by tests #68

Open
pavelpicka opened this issue Nov 9, 2022 · 7 comments
Open

Pulp user password - required by tests #68

pavelpicka opened this issue Nov 9, 2022 · 7 comments

Comments

@pavelpicka
Copy link

When I run oci-env test -i -p pulp_rpm functional test required pulp password. Is it even set (Tried few without luck)?

===================================================== test session starts ======================================================
platform linux -- Python 3.8.13, pytest-7.2.0, pluggy-1.0.0
rootdir: /var/lib/pulp
plugins: pulpcore-3.22.0.dev0, xdist-3.0.2, custom-exit-code-0.3.0, pulp-smash-1!0.13.0
collected 294 items                                                                                                            

../../var/lib/pulp/api/test_acs.py ..                                                                                    [  0%]
../../var/lib/pulp/api/test_advisory_conflict.py .                                                                       [  1%]
../../var/lib/pulp/api/test_advisory_upload.py ....                                                                      [  2%]
../../var/lib/pulp/api/test_auto_publish.py ..                                                                           [  3%]
../../var/lib/pulp/api/test_character_encoding.py ..                                                                     [  3%]
../../var/lib/pulp/api/test_comps.py ......                                                                              [  5%]
../../var/lib/pulp/api/test_consume_content.py 
We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

[sudo] password for pulp:
@mdellweg
Copy link
Member

Can you try to make the test not use sudo?

@dkliban
Copy link
Member

dkliban commented Nov 10, 2022

i fixed this locally by editing the /etc/sudoers file with the following addition:

pulp ALL=(ALL:ALL) NOPASSWD:ALL

@pavelpicka
Copy link
Author

Exact the workaround I used, may this could be RFE (to not do local workaround every time) as rpm plugin tests needs to run dnf which requires root privileges

@bmbouter
Copy link
Member

+1 to the tests not requiring sudo

@lubosmj
Copy link
Member

lubosmj commented Feb 14, 2023

@decko, is this the same issue you have experienced? How did you resolve it?

@decko
Copy link
Member

decko commented Feb 14, 2023

@decko, is this the same issue you have experienced? How did you resolve it?

I didn't! But we could have two new issues here:
1- Just add the user to the sudoers file.
2- Work the tests to not use sudo and remove it from the images at all.

What do you think @lubosmj ?

@lubosmj
Copy link
Member

lubosmj commented Feb 14, 2023

I am in favour of option 1.

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

6 participants