drone / charts

Helm charts for the Drone platform on Kubernetes
Other
168 stars 118 forks source link

Allow command to be overwritten #40

Closed agorgl closed 3 years ago

agorgl commented 3 years ago

This will allow server container command to be overwritten through customCommand value for injecting wrapper scripts. For example:

customCommand: ["/bin/sh", "-c", "apk add curl jq && . /scripts/drone-gitea-setup.sh && /bin/drone-server"]

extraVolumes:
  - name: wrapper
    configMap:
      name: drone-gitea-setup-wrapper
      defaultMode: 0744

extraVolumeMounts:
  - name: wrapper
    mountPath: /scripts

This can for example inject some environment variables exported from the script and allow fully automated integrations from e.g. gitea (by generating oauth2 creds from the rest api)

Idea from article: https://etoews.github.io/blog/2017/07/29/inject-an-executable-script-into-a-container-in-kubernetes/

agorgl commented 3 years ago

Ping?

agorgl commented 3 years ago

Reason?