Skip to content

Deploy foreman-certs from source instead of unmerged PR COPR build#673

Open
ehelms wants to merge 1 commit into
theforeman:masterfrom
ehelms:mock-installer-from-nightly
Open

Deploy foreman-certs from source instead of unmerged PR COPR build#673
ehelms wants to merge 1 commit into
theforeman:masterfrom
ehelms:mock-installer-from-nightly

Conversation

@ehelms

@ehelms ehelms commented Jul 17, 2026

Copy link
Copy Markdown
Member

Why are you introducing these changes? (Problem description, related links)

foreman-installer PR #935 adds the foreman-certs command but is not yet merged, so the mock-installer role was pinned to a COPR build of that PR. This is fragile — COPR builds are ephemeral and tied to a specific PR state. The binary and its Kafo scenario config can be deployed as role files instead, relying only on the nightly foreman-installer-katello package for puppet, modules, and kafo-export-params.

Additionally, repository setup was inlined in the setup-repositories playbook and not reusable, requiring forge setup-repositories to be run before forge mock-installer.

theforeman/foreman-installer#935

What are the changes introduced in this pull request?

  • Remove the COPR repo task from mock_foreman_installer
  • Add files/foreman-certs, files/foreman-certs.yaml, and files/foreman-certs-answers.yaml to the role — equivalent to what rake install produces for the foreman-certs scenario in PR #935
  • Install puppet-strings into Puppet's gem environment before running foreman-certs (required by kafo-export-params for parser cache generation)
  • Extract repository setup into development/roles/setup_repositories and refactor setup-repositories.yaml to delegate to it
  • Add setup_repositories as the first role in mock-installer.yaml so forge mock-installer is self-contained

How to test this pull request

Steps to reproduce:

  • Run ./forge mock-installer on a fresh VM without running ./forge setup-repositories first
  • Verify certificates are generated in /root/ssl-build/
  • Verify /etc/foreman-installer/scenarios.d/ contains the fixture files
  • Verify /usr/sbin/foreman-certs is present and executable

Checklist

  • Tests added/updated (if applicable)
  • Documentation updated (if applicable)

foreman-installer PR #935 adds foreman-certs but is not yet merged, so
the mock-installer role was pinned to a COPR build of that PR. Deploy
the binary and Kafo scenario config as role files instead, relying only
on the nightly foreman-installer-katello package for puppet, modules,
and kafo-export-params.

Extract repository setup into a reusable role so mock-installer is
self-contained and does not require forge setup-repositories to run
first.

Co-Authored-By: Claude <noreply@anthropic.com>
@ehelms
ehelms force-pushed the mock-installer-from-nightly branch from b51b2a2 to 66d0bec Compare July 17, 2026 17:55
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.

1 participant