Skip to content

Commit 3c95256

Browse files
committed
add empty-dir for pgbackrest repohost if readonlyrootfilesystem
1 parent 48ea7d5 commit 3c95256

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pkg/cluster/k8sres.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -886,6 +886,10 @@ func (c *Cluster) generatePodTemplate(
886886
addEmptyDirVolume(&podSpec, "postgres-tmp", "postgres", "/tmp")
887887
}
888888

889+
if c.OpConfig.ReadOnlyRootFilesystem != nil && *c.OpConfig.ReadOnlyRootFilesystem && isRepoHost == true {
890+
addEmptyDirVolume(&podSpec, "pgbackrest-tmp", "pgbackrest", "/tmp")
891+
}
892+
889893
if sharePgSocketWithSidecars != nil && *sharePgSocketWithSidecars {
890894
addVarRunVolume(&podSpec)
891895
}

0 commit comments

Comments
 (0)