Refactor #18732: Make Foreman Containerizable
Add a dockerfile for foreman
fixes #26741 - adds containers support for developers
this patch introduce a docker file and docker compose example
so that developers can easily get a production docker based env
this by no means is a replacement to the installer or should
effect users besides the porpose of getting up an environment quickly
this does not try to solve docker problems for plugins (but it
can be used to build customized images with a custom plugin installed).
to test this pr you would need docker and docker-compose (I'm running docker-compose-1.22.0-2.)
to use this PR:
docker-compose run app bundle exec rake db:create db:migrate db:seed
in order to build your own docker image you can either use a service
(such as quay.io) tiggered by a git push or manually OR
to install a recent version of docker that supports multi-stage builds
in theory podman also supports it, but i had stability issues with it
while trying to build images.
refs #26741 - update the location of the container image
Container image is now enabled on quay.io, on every merge
to foreman repo, a new image would be built for every branch.
Currently, only the develop branch is enabled, and therefore
the latest tag would be used for it.
refs #26741 - use develop container tag vs latest
hopefully this makes it more obvious one is using the
latest development build vs a stable release.
refs #26741 - adds usage/build instructions for foreman container
refs #26741 - switch to fedora-minimal base image
Not sure if this matters a lot, but this reduces the base image size from about 300MB to 130MB
refs #26741 - do not include facter in container based builds
Since hostnames do not matter within the container users
are expected to override the FOREMAN_FQDN setting.
this avoids the flipflop in the audits trail (of
serveral settings that depend on the hostname) and sets
a default so facter is not needed anymore.