Compare commits
47 Commits
e46e008941
...
d862f7c132
| Author | SHA1 | Date | |
|---|---|---|---|
| d862f7c132 | |||
| 7cbab35102 | |||
| 721dc409ad | |||
| 0ada9155eb | |||
| 5129be3fc8 | |||
| f70afe5523 | |||
| d6292ca4b0 | |||
| c514a76b5e | |||
| 6287a199b8 | |||
| d884c6cb2b | |||
| b7e034847e | |||
| cbb973550c | |||
|
|
041946b804 | ||
|
|
9793780639 | ||
|
|
a5d7592dc7 | ||
|
|
e6b0bb2db2 | ||
|
|
e3d4952df6 | ||
|
|
7bc8d7f084 | ||
|
|
06b0355568 | ||
|
|
5f6e0e9e35 | ||
|
|
8748fa515b | ||
|
|
fbbeb2e407 | ||
|
|
d84ebe5751 | ||
|
|
a062df8654 | ||
|
|
900cfed378 | ||
|
|
cb2b3a2c3a | ||
|
|
0c992a6d46 | ||
| 2604afabb5 | |||
| 10c0b70359 | |||
| 9abb6ce3cb | |||
| ea197d2006 | |||
| c735392ee5 | |||
| 63f651d622 | |||
| 81a2fb2c7f | |||
| 8d8630b0c5 | |||
| a7c67e138c | |||
| 8cda255fae | |||
| fa6f0ff85a | |||
| c23ff885f2 | |||
| d252b09a5d | |||
| 04b1992002 | |||
| 57f012a639 | |||
| d952476420 | |||
| 3fd277dd88 | |||
| 1f86724ba5 | |||
| 47168eb6dc | |||
| 87384c8b63 |
@@ -1,12 +1,12 @@
|
|||||||
name: Upload Helm Chart
|
name: Upload Helm Chart
|
||||||
run-name: Uploading helm chart
|
run-name: Uploading helm chart
|
||||||
on: [push]
|
on: [release]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
Explore-Gitea-Actions:
|
Explore-Gitea-Actions:
|
||||||
runs-on: shell
|
runs-on: shell
|
||||||
env:
|
env:
|
||||||
HELM_CHART_VERSION: "1.0.24"
|
HELM_CHART_VERSION: "${{ github.event.release_name }}"
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Set up Helm
|
- name: Set up Helm
|
||||||
@@ -15,10 +15,9 @@ jobs:
|
|||||||
version: 'v3.0.0'
|
version: 'v3.0.0'
|
||||||
- run: 'sed -i "s/version:.*/version: \"${HELM_CHART_VERSION}\"/" ./Chart/Chart.yaml'
|
- run: 'sed -i "s/version:.*/version: \"${HELM_CHART_VERSION}\"/" ./Chart/Chart.yaml'
|
||||||
- run: helm package ./Chart
|
- run: helm package ./Chart
|
||||||
- run: echo ${{ secrets.GITEA_TOKEN }} > /tmp/gitea-token
|
|
||||||
- name: Upload Helm Chart
|
- name: Upload Helm Chart
|
||||||
run: |
|
run: |
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
--user ${{ secrets.HELM_PKG_UPLOAD_USER }}:${{ secrets.HELM_PKG_UPLOAD_PASS }} \
|
--user ${{ secrets.HELM_PKG_UPLOAD_USER }}:${{ secrets.HELM_PKG_UPLOAD_PASS }} \
|
||||||
--form "chart=@wordyne-${HELM_CHART_VERSION}.tgz" \
|
--form "chart=@wordyne-${HELM_CHART_VERSION}.tgz" \
|
||||||
https://git.cloudyne.io/api/packages/helm/helm/api/charts
|
https://git.cloudyne.io/api/packages/helm/helm/api/charts
|
||||||
|
|||||||
4
.gitignore
vendored
4
.gitignore
vendored
@@ -1,2 +1,4 @@
|
|||||||
example.yaml
|
example.yaml
|
||||||
example*.yaml
|
example*.yaml
|
||||||
|
example*.yml
|
||||||
|
test-*.yaml
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
variables:
|
variables:
|
||||||
HELM_CHART_VERSION: "0.6.13"
|
HELM_CHART_VERSION: "1.0.24"
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
- deploy
|
- deploy
|
||||||
@@ -9,9 +9,7 @@ default:
|
|||||||
name: cloudyne/kubectl-helm:latest
|
name: cloudyne/kubectl-helm:latest
|
||||||
entrypoint: [""]
|
entrypoint: [""]
|
||||||
tags:
|
tags:
|
||||||
- build01
|
- shell
|
||||||
- helm
|
|
||||||
- chartbuild
|
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
stage: deploy
|
stage: deploy
|
||||||
|
|||||||
@@ -1,131 +0,0 @@
|
|||||||
{{- if .Values.init.asJob }}
|
|
||||||
apiVersion: batch/v1
|
|
||||||
kind: Job
|
|
||||||
metadata:
|
|
||||||
name: {{ include "..fullname" . }}-initializer
|
|
||||||
labels:
|
|
||||||
{{- include "..labels" . | nindent 4 }}
|
|
||||||
cloudyne.systems/component: site-init
|
|
||||||
spec:
|
|
||||||
backoffLimit: 2
|
|
||||||
template:
|
|
||||||
spec:
|
|
||||||
restartPolicy: "OnFailure"
|
|
||||||
affinity: {{ include "..affinity-labels" . | nindent 8 }}
|
|
||||||
securityContext:
|
|
||||||
fsGroup: 101
|
|
||||||
volumes:
|
|
||||||
- name: serverconfig
|
|
||||||
configMap:
|
|
||||||
name: {{ include "..fullname" . }}-cfg
|
|
||||||
{{- if and .Values.secrets .Values.secrets.external }}
|
|
||||||
{{- range .Values.secrets.external }}
|
|
||||||
{{- if eq .type "file" }}
|
|
||||||
- name: {{ .name }}
|
|
||||||
secret:
|
|
||||||
secretName: {{- include "..fullname" $ }}-exts-{{ .name }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.storage.kubernetes }}
|
|
||||||
{{- range .Values.storage.kubernetes }}
|
|
||||||
- name: {{ .name }}
|
|
||||||
{{- if eq .type "secret" }}
|
|
||||||
secret:
|
|
||||||
secretName: "{{- include "..fullname" $ }}-sec-{{ .name }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- if eq .type "configmap" }}
|
|
||||||
configMap:
|
|
||||||
name: "{{- include "..fullname" $ }}-sec-{{ .name }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.storage.cloud.active }}
|
|
||||||
- name: cloud
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: pvc-{{- include "..name" . }}-cloud
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.storage.local.active }}
|
|
||||||
- name: local
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: pvc-{{- include "..name" . }}-local
|
|
||||||
{{- end }}
|
|
||||||
{{- if and .Values.secrets .Values.secrets.external }}
|
|
||||||
{{- range .Values.secrets.external }}
|
|
||||||
{{- if eq .type "docker" }}
|
|
||||||
imagePullSecrets:
|
|
||||||
- name: "{{- include "..fullname" $ }}-exts-{{ .name }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.storage.kubernetes }}
|
|
||||||
{{- range .Values.storage.kubernetes }}
|
|
||||||
{{- if eq .type "docker" }}
|
|
||||||
imagePullSecrets:
|
|
||||||
- name: "{{- include "..fullname" $ }}-sec-{{ .name }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if and .Values.storage.cloud.active .Values.storage.local.active .Values.storage.local.cloneCloud }}
|
|
||||||
initContainers:
|
|
||||||
- name: init-local-storage
|
|
||||||
securityContext:
|
|
||||||
allowPrivilegeEscalation: false
|
|
||||||
runAsUser: 0
|
|
||||||
image: cloudyne/ubuntu-ci:latest
|
|
||||||
command: ["python3"]
|
|
||||||
args: ["/usr/local/bin/storage-clone", "/mnt/cloud", "/mnt/local"]
|
|
||||||
imagePullPolicy: IfNotPresent
|
|
||||||
volumeMounts:
|
|
||||||
- name: cloud
|
|
||||||
mountPath: /mnt/cloud
|
|
||||||
- name: local
|
|
||||||
mountPath: /mnt/local
|
|
||||||
{{- end }}
|
|
||||||
containers:
|
|
||||||
- name: init-site
|
|
||||||
securityContext:
|
|
||||||
allowPrivilegeEscalation: false
|
|
||||||
runAsUser: 0
|
|
||||||
image: "{{ .Values.site.image }}"
|
|
||||||
imagePullPolicy: IfNotPresent
|
|
||||||
volumeMounts:
|
|
||||||
- name: serverconfig
|
|
||||||
mountPath: /init-go/config.json
|
|
||||||
subPath: init.json
|
|
||||||
{{- if .Values.storage.local.active }}
|
|
||||||
{{- range .Values.storage.folders }}
|
|
||||||
- name: local
|
|
||||||
mountPath: "/app/web/app/{{ . }}"
|
|
||||||
subPath: "{{ . }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.storage.cloud.active }}
|
|
||||||
- name: cloud
|
|
||||||
mountPath: "/mnt/cloud"
|
|
||||||
{{- end }}
|
|
||||||
{{- else }}
|
|
||||||
{{- if .Values.storage.cloud.active }}
|
|
||||||
{{- range .Values.storage.folders }}
|
|
||||||
- name: cloud
|
|
||||||
mountPath: "/app/web/app/{{ . }}"
|
|
||||||
subPath: "{{ . }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
|
|
||||||
envFrom:
|
|
||||||
- configMapRef:
|
|
||||||
name: {{ include "..fullname" . }}-env
|
|
||||||
{{- if and .Values.secrets .Values.secrets.external }}
|
|
||||||
{{- range .Values.secrets.external }}
|
|
||||||
{{- if eq .type "env" }}
|
|
||||||
- secretRef:
|
|
||||||
name: "{{- include "..fullname" $ }}-exts-{{ .name }}"
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
- secretRef:
|
|
||||||
name: {{ include "..fullname" . }}-db-auth
|
|
||||||
command: ["sh"]
|
|
||||||
args: ["-c", "/init-go/init-go"]
|
|
||||||
{{- end }}
|
|
||||||
Reference in New Issue
Block a user