Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Persistent Volumes are Kubernetes native.

How to set up Persistent Volumes

You can either:

  • Let the helm chart create the volumes for you (recommended)

  • Create the Volumes manually

Let the helm chart create the volumes for you (recommended)

  1. Comment out the claimName

  2. Check the remaining settings (see table below)

  3. Run a helm install ...

  4. Now the helm chart will create 3 volumes as specified in the settings

    1. backend-uploads

    2. button3d-media

    3. button3d-private-media

  5. Setup the respective claimName to the string of the Persistent volume name. E.g.

Code Block
languageyaml
fileStorageConfig:
    uploads:
      claimName: "backend-uploads"
    media:
      claimName: "button3d-media"
    privateMedia:
      claimName: "button3d-private-media"

6. Now helm will use the initially created volumes instead of creating new ones.

Create the Volumes manually

1. Creating the volumes

Please consult the Kubernetes Documentation to create the 3 volumes manually.
Our recommended claim names are:

  • backend-uploads

  • button3d-media

  • button3d-private-media

2. Link the volumes

Setup the respective claimName to the string of the Persistent volume name. E.g.

Code Block
languageyaml
fileStorageConfig:
    uploads:
      claimName: "backend-uploads"

All other settings will be ignored.

Code Block
languageyaml
fileStorageConfig:
  internal:
    enabled: true
    uploads:
      size: 1Gi
      storageClass: default
      claimName: "backend-uploads"
      accessMode: ReadWriteMany
    media:
      size: 1Gi
      storageClass: default
      claimName: "button3d-media"
      accessMode: ReadWriteOnceReadWriteMany
    privateMedia:
      size: 1Gi
      storageClass: default
       # fileStorageConfig.internal.privateMedia.claimName -- Use an existing PVC to persist data. If unspecified, a claim will be created with the name "button3d-private-media"claimName: "button3d-private-media"
      accessMode: ReadWriteMany

Azure Files storage specific

Code Block
fileStorageConfig:
  internal:
    enabled: true
    # TODO: define size and name of the storage class for persistent file storage
    uploads:
      size: 1Gi
      

...

storageClass: azurefile
      accessMode: ReadWriteMany

...

 

...

 

...

 

...

 

...

media:

...

 

...

 

...

 

...

 

...

 

...

 

...

size: 

...

1Gi
      

...

storageClass: 

...

azurefile
      accessMode: ReadWriteMany
   

...

 

...

privateMedia:
      size: 1Gi
      storageClass: azurefile
      accessMode: 

...

ReadWriteMany

Settings Key

Possible Values

Description

region

enabled

An AWS Region, eg eu-central-1

Specify the region of the S3 Bucket

publicBucket

A valid S3-Bucket name

The name of the bucket that holds the public media files

privateBucket

A valid S3-Bucket name

The name of the bucket that holds the private media files

uploadsBucket

A valid S3-Bucket name

The name of the bucket that holds the uploads (eg - 3D files)

accessKey

Any String

The access key of the IAM user that should access the private and public media buckets

secretKey

Any String

The secret key of the IAM user that should access the private and public media buckets

true, false

Specifies if Persistent Volumes are used

size

50Gi, 200Mi, 1Ti , …

The size of the volume on initial creation. Only relevant if claimName is unset

storageClass

A supported storageClass name or default

Check https://kubernetes.io/docs/concepts/storage/storage-classes/ . You can use kubectl get storageclass to see what storage classes are supported in your cluster. Only relevant if claimName is unset

claimName

A string

See above

accessMode

ReadWriteMany or ReadWriteOnce

Specifies if you can attach to the volume from multiple pods. It is recommended to use ReadWriteMany. Only relevant if claimName is unset