charts icon indicating copy to clipboard operation
charts copied to clipboard

Download and initialize plugins by `initContainers`

Open abdennour opened this issue 4 years ago • 2 comments

Code of Conduct

Submission validity

  • [X] This is not a personal support request, that should be posted on discussions community.
  • [X] I checked current issues and this request isn't a duplicate of an existing issue, opened or closed.

Summary

i want to manage installing plugins from the same helm chart.

Motivation

  • keeping helm chart as single source for the infra-as-code of the Yourls instances.
  • keeping helm chart as single source for config-as-code
  • Complying with the release engineering principles about immutable infra
  • Managing plugins lifecycle from helm chart and this is the trigger of motivation ; installing this plugin: https://github.com/peterberbec/yourls-keyword_charset_length

Describe the solution

We can design our default values in a case if a user wants to install this chart, he will give something like this :

plugins:
  - name: key_char_len
     url: https://raw.githubusercontent.com/peterberbec/yourls-keyword_charset_length/master/plugin.php
  - name: plugin_xyz
     url: https://something/xyz/plugin.php

abdennour avatar Jul 16 '21 18:07 abdennour

Thanks a lot for opening this ticket @abdennour. This is indeed a really good idea! 👍 That said making it real is a bit more complicated than it looks like.

  • Should this be managed by an initContainer? Which one?
  • How do you validate installation? How do manage upgrade?
  • ...

LeoColomb avatar Jul 19 '21 17:07 LeoColomb

use _helpers.tpl to unify the flow of values. for example, initContainers must be computed in _helpers.tpl and so on . check jenkins/jenkins helm chart

abdennour avatar Jul 30 '21 08:07 abdennour

I'm closing this as stale and with an already pretty suitable solution. I'd advocate using the initContainers with a proper yet simple script to download and extract the necessary plugins. This is not optimal, but with the lack of a plugin manager this is probably the best.

LeoColomb avatar Sep 09 '24 18:09 LeoColomb