sagikazarmark / helm-charts

Various Helm charts for my own and other projects
MIT License
42 stars 54 forks source link

Better tusd configuration #49

Open sagikazarmark opened 3 years ago

sagikazarmark commented 3 years ago

Currently tusd can be configured directly via container args. Let's add a better config structure so that container args are not exposed.

Example:

config:
  basePath:
  behindProxy:
  maxSize:
  timeout:
  uploadDir:
  verbose:

  tls:
    certPath:
    keyPath:
    mode:

  hooks:
    enabled: []
    stopCode:

    file:
      path:
    http:
      endpoint:
      backoff:
      forwardHeaders:
      retry:
    grpc:
      endpoint:
      backoff:
      retry:
    plugin:
      path:

  storage:
    gcs:
      bucket:
      objectPrefix:
    s3:
      bucket:
      objectPrefix:
      disableContentHashes:
      disableSsl:
      endpoint:
      partSize:
      transferAcceleration:
Vince-vd commented 3 years ago

Could you explain what the list of container args needs to look like right now for it to work please? I'm trying to specificy a gcs-bucket and gcs-object-prefix, but can not seem to find the right syntax in the values.yaml file Whichever way I try the helm install command fails with the error "timed out waiting for the condition"

This is the format I'm trying right now:

containerArgs: 
  - '-gcs-bucket'
  - 'bucket_name'
  - '-gcs-object-prefix'
  - 'tmp/tus/'

Thank you for all the work you've put into this package!

sagikazarmark commented 3 years ago

Without an actual error message it's impossible to know what went wrong. Can you check the cluster (eg. see if the pods are there, crashing, fetch some logs, etc)

Vince-vd commented 3 years ago

Sorry, yes absolutely. I'm pretty new to kubernetes and just assumed I was entering the args incorrectly. I see now that the error is actually [tusd] 2021/05/28 15:25:12 No service account file provided for Google Cloud Storage using the GCS_SERVICE_ACCOUNT_FILE environment variable. I had assumed this step wasn't necessary since it's already running in the google cloud environment. I see that there are tutorials on how to make this available in a pod so I'll give those a shot before bothering you again, unless this is a very easy step for you to explain of course. Thanks,