Skip to content

Fixes for Candlepin 4.6 and Foreman 3.16#231

Merged
evgeni merged 4 commits into
masterfrom
fixes
Sep 11, 2025
Merged

Fixes for Candlepin 4.6 and Foreman 3.16#231
evgeni merged 4 commits into
masterfrom
fixes

Conversation

@evgeni

@evgeni evgeni commented Sep 11, 2025

Copy link
Copy Markdown
Member

No description provided.

systemd defaults to 90 seconds timeout of a service startup, but
candlepin 4.6 seems to require more on the first start when it applies
the DB migrations
As we can't rely on the host we run the `foremanpi` fixture on to have
correct DNS for `quadlet.example.com`, we use the IP address we get from
Vagrant for all communication.

Sadly this leaks into the generated registrtion command, which will also
use the IP address instead of the hostname, even tho the client system
has correct DNS (via `/etc/hosts`).

Before theforeman/foreman#10555 this wasn't a
problem, the registration part worked and the fact that the second curl
call failed was (silently) ignored.

Fix the `Host` header sent to the API to use `quadlet.example.com` and
thus generate the right command.
@evgeni evgeni mentioned this pull request Sep 11, 2025
6 tasks
Comment thread tests/conftest.py Outdated

@ekohl ekohl left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm ok leaving it to later because this is already an improvement, but just raising a thought inline.

Comment thread tests/conftest.py
@pytest.fixture(scope="module")
def certificates(pytestconfig):
def server_hostname():
return 'quadlet.example.com'

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also have the server part which calls paramiko://quadlet:

@pytest.fixture(scope="module")
def server():
yield testinfra.get_host('paramiko://quadlet', sudo=True, ssh_config='./.vagrant/ssh-config')

That part also has the quadlet name. Can we somehow extract quadlet.example.com from the get_host call?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll think about that part tomorrow

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@evgeni
evgeni merged commit a34d73d into master Sep 11, 2025
5 checks passed
@evgeni
evgeni deleted the fixes branch September 11, 2025 13:02
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

Successfully merging this pull request may close these issues.

2 participants