-
Notifications
You must be signed in to change notification settings - Fork 19
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
Dedicated container for database #482
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple comments, mostly typos.
Once this is merged, smdba autotune call can be also removed from mgr-setup and others.
) error { | ||
image := pgsqlFlags.Image | ||
currentReplicas := systemd.CurrentReplicaCount(podman.PgsqlService) | ||
log.Debug().Msgf("Current HUB replicas running are %d.", currentReplicas) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
log.Debug().Msgf("Current HUB replicas running are %d.", currentReplicas) | |
log.Debug().Msgf("Current pgsql replicas running are %d.", currentReplicas) |
log.Debug().Msgf("Current HUB replicas running are %d.", currentReplicas) | ||
|
||
if pgsqlFlags.Replicas == 0 { | ||
log.Debug().Msg("No pgsql requested.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
log.Debug().Msg("No pgsql requested.") | |
log.Info().Msg(L("No Postgres container requested.")) |
log.Debug().Msg("No pgsql requested.") | ||
} | ||
if !pgsqlFlags.IsChanged { | ||
log.Info().Msgf(L("No changes requested for hub. Keep %d replicas."), currentReplicas) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
log.Info().Msgf(L("No changes requested for hub. Keep %d replicas."), currentReplicas) | |
log.Info().Msgf(L("No changes requested for pgsql. Keep %d replicas."), currentReplicas) |
if err := cnx.WaitForHealthcheck(); err != nil { | ||
return err | ||
} | ||
// Now the servisce is up and ready, the admin credentials are no longer needed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Now the servisce is up and ready, the admin credentials are no longer needed | |
// Now the service is up and ready, the admin credentials are no longer needed |
@@ -0,0 +1,191 @@ | |||
// SPDX-FileCopyrightText: 2024 SUSE LLC |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// SPDX-FileCopyrightText: 2024 SUSE LLC | |
// SPDX-FileCopyrightText: 2025 SUSE LLC |
OLD_VERSION={{ .OldVersion }} | ||
NEW_VERSION={{ .NewVersion }} | ||
FAST_UPGRADE=--link | ||
FAST_UPGRADE= #--link |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not needed anymore
@@ -209,3 +209,21 @@ Leave it unset if you want to keep the previous number of replicas. | |||
_ = utils.AddFlagToHelpGroupID(cmd, "saline-replicas", "saline-container") | |||
_ = utils.AddFlagToHelpGroupID(cmd, "saline-port", "saline-container") | |||
} | |||
|
|||
// AddPgsqlFlags adds hub XML-RPC related parameters to cmd. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// AddPgsqlFlags adds hub XML-RPC related parameters to cmd. | |
// AddPgsqlFlags adds postgres related parameters to cmd. |
_ = utils.AddFlagToHelpGroupID(cmd, "pgsql-replicas", "pgsql-container") | ||
} | ||
|
||
// AddUpgradePgsqlFlags adds hub XML-RPC related parameters to cmd upgrade. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// AddUpgradePgsqlFlags adds hub XML-RPC related parameters to cmd upgrade. | |
// AddUpgradePgsqlFlags adds postgres related parameters to cmd upgrade. |
What does this PR change?
Current state:
Works with the image from uyuni-project/uyuni#9469
mgradm install podman --pgsql-image <image> --pgsql-tag <tag>
Uses workarounds for the issues discussed in https://github.com/SUSE/spacewalk/issues/25363
Missing kubernetes.
Test coverage
No tests: add explanation
No tests: already covered
Unit tests were added
DONE
Links
Issue(s): #
Changelogs
Make sure the changelogs entries you are adding are compliant with https://github.com/uyuni-project/uyuni/wiki/Contributing#changelogs and https://github.com/uyuni-project/uyuni/wiki/Contributing#uyuni-projectuyuni-repository
If you don't need a changelog check, please mark this checkbox:
If you uncheck the checkbox after the PR is created, you will need to re-run
changelog_test
(see below)Before you merge
Check How to branch and merge properly!