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

Foreman & Foreman Proxy plugin handling #46

Open
ekohl opened this issue Oct 28, 2024 · 0 comments
Open

Foreman & Foreman Proxy plugin handling #46

ekohl opened this issue Oct 28, 2024 · 0 comments

Comments

@ekohl
Copy link
Member

ekohl commented Oct 28, 2024

Right now there is a mechanism to enable/disable plugins:

ARG FOREMAN_PLUGINS="foreman-tasks foreman_remote_execution katello"
RUN dnf upgrade -y && dnf install --nodocs -y https://yum.theforeman.org/releases/${FOREMAN_VERSION}/el9/x86_64/foreman-release.rpm https://yum.theforeman.org/katello/${KATELLO_VERSION}/katello/el9/x86_64/katello-repos-latest.rpm && dnf install foreman foreman-postgresql foreman-service foreman-redis foreman-dynflow-sidekiq --nodocs -y && dnf clean all
RUN for PLUGIN in ${FOREMAN_PLUGINS}; do echo $PLUGIN; dnf install --nodocs -y "rubygem($PLUGIN)"; echo "gem '$PLUGIN' if ENV.fetch('FOREMAN_ENABLED_PLUGINS', '').split.include?('$PLUGIN') || ENV.fetch('FOREMAN_ENABLED_PLUGINS', nil).nil?" > /usr/share/foreman/bundler.d/$PLUGIN.rb; done && \
dnf clean all

What this does is to install certain plugins (FOREMAN_PLUGINS arg) and then overwrites the included bundler.d file. It does this so you can use FOREMAN_ENABLED_PLUGINS to have plugins installed, but not activated. This reduces the number of containers we need to build: instead of all permutations (which quickly explodes).

Currently this is undocumented, which is probably the first thing to resolve.

A next step is to figure out which containers we do build. Looking at the RPM repos I can imagine 3 variations:

  • core (no plugins)
  • core + all plugins in foreman-plugins
  • core + all plugins in foreman-plugins + katello & all its plugins

Another step is to figure out how to avoid needing to overwrite the shipped bundler.d file, for example using groups (exposing BUNDLER_WITHOUT).

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

1 participant