Instance profiles

The instance profile CR represent the CPU and memory resources assigned to each Pod of the cluster.


Kind: SGInstanceProfile

listKind: SGInstanceProfileList

plural: sginstanceprofiles

singular: sginstanceprofile


Spec

Property Required Updatable Default Type Description
cpu 1 string

CPU(s) (cores) to use for every instance of a SGCluster. Please note that every StackGres pod contains not only the Patroni+Postgres container, but several other sidecar containers. While the majority of the resources are devoted to the main Postgres container, some CPU is needed for the sidecars.

The specified number of cores will be split between all the containers.

A minimum of 2 cores is recommended.

memory 2Gi string

RAM allocated to every instance of a SGCluster. Use the suffix Mi or Gi to specify Mebibytes or Gibibytes, respectively. Please note that every StackGres pod contains not only the Patroni+Postgres container, but several other sidecar containers. While the majority of the resources are devoted to the main Postgres container, some RAM is needed for the sidecars.

The specified amount of RAM will be split between all the containers.

A minimum of 2-4Gi is recommended.

Example:

apiVersion: stackgres.io/v1beta1
  kind: SGInstanceProfile
  metadata:
    name: size-l
  spec:
    cpu: "4"
    memory: 8Gi