Skip to content

Introduce a plain foreman flavor#511

Draft
ekohl wants to merge 10 commits into
theforeman:masterfrom
ekohl:plain-foreman-flavor
Draft

Introduce a plain foreman flavor#511
ekohl wants to merge 10 commits into
theforeman:masterfrom
ekohl:plain-foreman-flavor

Conversation

@ekohl

@ekohl ekohl commented May 15, 2026

Copy link
Copy Markdown
Member

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

Today Foreman can be deployed without Katello on both RPM and Debian installations and this allows users to mirror that.

What are the changes introduced in this pull request?

The flavor itself is rather trivial, but there are some changes made to only deploy certain roles depending on the features enabled. That is likely incomplete. In particular, Apache is not yet modified to only deploy the required services. In the future when a plain foreman-proxy role is introduced then that will need adjustment.

There are also heavy testing changes, heavily based on #509 which in turn is based on #508. I'm wondering how much of those commits already belong there.

Right now the test suite fails because the foreman feature is only set in the flavor and not in the parameters.

It's also important to look at how this will play into #431.

How to test this pull request

Steps to reproduce:

  • Run foremanctl deploy --flavor foreman
  • Observe only Foreman it deployed without Pulp and Candlepin
  • Test suite passes

Checklist

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

ekohl added 10 commits May 20, 2026 11:58
This sets up a directory structure where an entire directory gets a
feature mark. This makes it easy to skip entire feature tests.
This guards it behind the feature flag, allowing the tests to be skipped
if the feature is disabled. For example, on a standalone foreman-proxy.
This moves Candlepin and Pulp behind the feature flags. Candlepin is
only deployed on Foreman with Katello servers while Pulp is deployed on
Katello enabled servers.
Comment thread tests/postgresql_test.py


def test_postgresql_users(database):
def test_postgresql_users(features, database):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Here why are we using features instead of enabled_features? features will bring all the features(available + enabled)

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.

Good catch. Left over from an older version where features was what is now enabled_features.

@arvind4501

Copy link
Copy Markdown
Contributor

Our CI is currently not designed to run flavor specific tests https://github.com/theforeman/foremanctl/blob/master/.github/workflows/test.yml#L54, it adds all features but surely that won't make sense, as we want to only add relevent features for a flavor(ex: add bmc to plain foreman does not make any sense),

Thinking out loud:-
Should we make test workflow per flavor, I am still trying to get all data points which can help in multi-flavor testing

@ekohl

ekohl commented Jun 2, 2026

Copy link
Copy Markdown
Member Author

Should we make test workflow per flavor, I am still trying to get all data points which can help in multi-flavor testing

If you're talking about a GitHub Actions workflow: I think that does make sense. We probably can't test all combinations, but finding a good set is exactly what I think we should do.

@arvind4501

arvind4501 commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

If you're talking about a GitHub Actions workflow

yes,and i think without flavor specific workflows we might end up with a single tests workflow which adds all available features(as of today) and will keep CI red

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