mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-05-06 13:26:42 +02:00
Merged in feature/helm-install-plugins (pull request #117)
Feature/helm install plugins
This commit is contained in:
@@ -108,7 +108,7 @@ data:
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration>
|
||||
|
||||
<--
|
||||
<!--
|
||||
in a container environment we only need stdout
|
||||
-->
|
||||
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
|
||||
|
||||
@@ -29,6 +29,17 @@ spec:
|
||||
volumeMounts:
|
||||
- name: data
|
||||
mountPath: /data
|
||||
{{- if .Values.plugins }}
|
||||
- name: install-plugins
|
||||
image: alpine:3.8
|
||||
imagePullPolicy: IfNotPresent
|
||||
command: ['sh', '/scripts/install-plugins.sh']
|
||||
volumeMounts:
|
||||
- name: data
|
||||
mountPath: /data
|
||||
- name: scripts
|
||||
mountPath: /scripts
|
||||
{{- end }}
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
||||
@@ -63,6 +74,11 @@ spec:
|
||||
- name: config
|
||||
configMap:
|
||||
name: {{ include "scm-manager.fullname" . }}
|
||||
{{- if .Values.plugins }}
|
||||
- name: scripts
|
||||
configMap:
|
||||
name: {{ include "scm-manager.fullname" . }}-scripts
|
||||
{{- end }}
|
||||
{{- with .Values.nodeSelector }}
|
||||
nodeSelector:
|
||||
{{ toYaml . | indent 8 }}
|
||||
|
||||
21
deployments/helm/templates/scripts.yaml
Normal file
21
deployments/helm/templates/scripts.yaml
Normal file
@@ -0,0 +1,21 @@
|
||||
{{- if .Values.plugins }}
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ include "scm-manager.fullname" . }}-scripts
|
||||
labels:
|
||||
app: {{ include "scm-manager.name" . }}
|
||||
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
|
||||
release: "{{ .Release.Name }}"
|
||||
heritage: "{{ .Release.Service }}"
|
||||
data:
|
||||
install-plugins.sh: |
|
||||
#!/bin/sh
|
||||
mkdir -p /data/plugins
|
||||
chown 1000:1000 /data/plugins
|
||||
{{ range $i, $plugin := .Values.plugins }}
|
||||
# install plugin {{ $plugin.name }}
|
||||
wget -O /data/plugins/{{ $plugin.name }}.smp {{ $plugin.url }}
|
||||
chown 1000:1000 /data/plugins/{{ $plugin.name }}.smp
|
||||
{{ end }}
|
||||
{{- end }}
|
||||
@@ -10,6 +10,10 @@ image:
|
||||
tag: latest
|
||||
pullPolicy: Always
|
||||
|
||||
# plugins:
|
||||
# - name: scm-review-plugin
|
||||
# url: https://oss.cloudogu.com/jenkins/job/scm-manager/job/scm-manager-bitbucket/job/scm-review-plugin/job/develop/lastSuccessfulBuild/artifact/target/scm-review-plugin-2.0.0-SNAPSHOT.smp
|
||||
|
||||
nameOverride: ""
|
||||
fullnameOverride: ""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user