Skip to content

Conversation

timricese
Copy link

This PR makes logical-backup CronJobs be created with a securityContext containing runAsUser, runAsGroup and FSGroup based on the SpiloRunAsUser, SpiloRunAsGroup and SpiloFSGroup operator configuration options, allowing the logical-backup jobs to run as non-root.

resolves #1306

@joschi36
Copy link

Just ran in the non-root problem for logical backup container. Is there a plan to merge this change, or is there another way?

@FxKu
Copy link
Member

FxKu commented May 17, 2022

Thanks @timricese. Let's do some more refactoring here. Can you move this code block (lines 1164 - 1178) inside generatePodTemplate function? We can then remove arguments spiloRunAsUser *int64, spiloRunAsGroup *int64, spiloFSGroup *int64 from the function spec and it will be used for all pods - spilo and logical backup.

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

Successfully merging this pull request may close these issues.

Run logical_backup as non-root

3 participants