if there's a security context with a specific UID to use for the DB, use it, otherwise use the default postgres UID
(cluster *apiv1.Cluster, dbContainer *corev1.Container)
| 1016 | // if there's a security context with a specific UID to use for the DB, use it, |
| 1017 | // otherwise use the default postgres UID |
| 1018 | func getDatabasUserUID(cluster *apiv1.Cluster, dbContainer *corev1.Container) int64 { |
| 1019 | if dbContainer.SecurityContext.RunAsUser != nil { |
| 1020 | return *dbContainer.SecurityContext.RunAsUser |
| 1021 | } |
| 1022 | return cluster.GetPostgresUID() |
| 1023 | } |
| 1024 | |
| 1025 | func AssertClusterHasPvcsAndDataDirsForTablespaces(cluster *apiv1.Cluster, timeout int) { |
| 1026 | namespace := cluster.Namespace |
no test coverage detected