Skip to content

Commit

Permalink
distro/rhel10: use only distro-wide locale and timezone
Browse files Browse the repository at this point in the history
Remove the Locale and Timezone overrides from all image types in RHEL
10.  Use the distro-wide configuration for these everywhere.

This commit has no effect on image definitions.
  • Loading branch information
achilleas-k committed Jan 17, 2025
1 parent 7107ded commit b182eab
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 15 deletions.
2 changes: 0 additions & 2 deletions pkg/distro/rhel/rhel10/ami.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,6 @@ const (
// default EC2 images config (common for all architectures)
func defaultEc2ImageConfig() *distro.ImageConfig {
return &distro.ImageConfig{
Locale: common.ToPtr("C.UTF-8"),
Timezone: common.ToPtr("UTC"),
TimeSynchronization: &osbuild.ChronyStageOptions{
Servers: []osbuild.ChronyConfigServer{
{
Expand Down
2 changes: 0 additions & 2 deletions pkg/distro/rhel/rhel10/azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -406,8 +406,6 @@ const defaultAzureKernelOptions = "ro loglevel=3 console=tty1 console=ttyS0 earl
// based on https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html/deploying_rhel_9_on_microsoft_azure/assembly_deploying-a-rhel-image-as-a-virtual-machine-on-microsoft-azure_cloud-content-azure#making-configuration-changes_configure-the-image-azure
func defaultAzureImageConfig(rd *rhel.Distribution) *distro.ImageConfig {
ic := &distro.ImageConfig{
Timezone: common.ToPtr("UTC"),
Locale: common.ToPtr("C.UTF-8"),
Keyboard: &osbuild.KeymapStageOptions{
Keymap: "us",
X11Keymap: &osbuild.X11KeymapOptions{
Expand Down
2 changes: 0 additions & 2 deletions pkg/distro/rhel/rhel10/gce.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ func mkGCEImageType() *rhel.ImageType {

func baseGCEImageConfig() *distro.ImageConfig {
ic := &distro.ImageConfig{
Timezone: common.ToPtr("UTC"),
TimeSynchronization: &osbuild.ChronyStageOptions{
Servers: []osbuild.ChronyConfigServer{{Hostname: "metadata.google.internal"}},
},
Expand All @@ -59,7 +58,6 @@ func baseGCEImageConfig() *distro.ImageConfig {
"reboot.target",
},
DefaultTarget: common.ToPtr("multi-user.target"),
Locale: common.ToPtr("C.UTF-8"),
Keyboard: &osbuild.KeymapStageOptions{
Keymap: "us",
},
Expand Down
1 change: 0 additions & 1 deletion pkg/distro/rhel/rhel10/ubi.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ func mkWSLImgType() *rhel.ImageType {
)

it.DefaultImageConfig = &distro.ImageConfig{
Locale: common.ToPtr("C.UTF-8"),
NoSElinux: common.ToPtr(true),
WSLConfig: &osbuild.WSLConfStageOptions{
Boot: osbuild.WSLConfBootOptions{
Expand Down
8 changes: 0 additions & 8 deletions pkg/distro/rhel/rhel10/vmdk.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
package rhel10

import (
"github.com/osbuild/images/internal/common"
"github.com/osbuild/images/pkg/datasizes"
"github.com/osbuild/images/pkg/distro"
"github.com/osbuild/images/pkg/distro/rhel"
"github.com/osbuild/images/pkg/rpmmd"
)
Expand All @@ -24,9 +22,6 @@ func mkVMDKImgType() *rhel.ImageType {
[]string{"vmdk"},
)

it.DefaultImageConfig = &distro.ImageConfig{
Locale: common.ToPtr("C.UTF-8"),
}
it.KernelOptions = vmdkKernelOptions
it.Bootable = true
it.DefaultSize = 4 * datasizes.GibiByte
Expand All @@ -49,9 +44,6 @@ func mkOVAImgType() *rhel.ImageType {
[]string{"archive"},
)

it.DefaultImageConfig = &distro.ImageConfig{
Locale: common.ToPtr("C.UTF-8"),
}
it.KernelOptions = vmdkKernelOptions
it.Bootable = true
it.DefaultSize = 4 * datasizes.GibiByte
Expand Down

0 comments on commit b182eab

Please sign in to comment.