Skip to content

Fixes #39187 - Ensure PostgreSQL locale on Debian - #1288

Merged
ekohl merged 1 commit into
theforeman:masterfrom
jakduch:fix/39187
Aug 20, 2026
Merged

ekohl merged 1 commit into
theforeman:masterfrom
jakduch:fix/39187

Conversation

@jakduch

@jakduch jakduch commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Summary

Ensure the en_US.utf8 locale is available on Debian-family systems before creating the Foreman PostgreSQL database.

Foreman passes locale => 'en_US.utf8' to postgresql::server::db. A fresh Debian or Ubuntu installation may not provide that locale, leaving the PostgreSQL role created but the database missing and causing db:migrate to fail. Installing locales-all follows the recommendation from puppetlabs-postgresql and mirrors the existing glibc-langpack-en handling on EL.

The reported Apache port 443 symptom is a consequence of the failed catalog: the SSL vhost is written, but the dependent Apache service refresh is skipped. Allowing the initial database setup to finish also allows that refresh to run normally.

Fixes: https://projects.theforeman.org/issues/39187

Test coverage

  • Added a catalog expectation that locales-all is installed before Postgresql::Server::Db[foreman] on Debian-family systems.
  • Ruby syntax and whitespace checks pass locally. The full Puppet test bundle requires a newer Ruby than the available local runtime and is left to upstream CI.

This pull request was assisted by Codex 5.6 Sol High. The resulting changes were reviewed before submitting, and the commit includes an Assisted-By trailer.

Install locales-all before creating the Foreman database so the required en_US.utf8 locale is available.

Assisted-By: Codex 5.6 Sol High
@ekohl
ekohl merged commit 7ced021 into theforeman:master Aug 20, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants