fixed volums

This commit is contained in:
kolaente 2017-11-26 17:42:02 +01:00
parent d1917df761
commit b80d13b46f
No known key found for this signature in database
GPG Key ID: F40E70337AB24C9B
2 changed files with 41 additions and 23 deletions

View File

@ -3,12 +3,12 @@ services:
gitea: gitea:
image: gitea/gitea:1.3.0-rc1 image: gitea/gitea:1.3.0-rc1
volumes: volumes:
- ${data_path}/git:/data/git - gitea-data-git:/data/git
- ${data_path}/ssh:/data/ssh - gitea-data-ssh:/data/ssh
- ${data_path}/gitea/conf:/data/gitea/conf - gitea-data-conf:/data/gitea/conf
- ${data_path}/gitea/lfs:/data/gitea/lfs - gitea-data-lfs:/data/gitea/lfs
- ${data_path}/gitea/log:/data/gitea/log - gitea-data-log:/data/gitea/log
- ${data_path}/gitea/sessions:/data/gitea/sessions - gitea-data-sessions:/data/gitea/sessions
{{- if ne .Values.db_link ""}} {{- if ne .Values.db_link ""}}
external_links: external_links:
@ -22,10 +22,28 @@ services:
MYSQL_ROOT_PASSWORD: ${mysql_password} MYSQL_ROOT_PASSWORD: ${mysql_password}
MYSQL_DATABASE: 'gitea' MYSQL_DATABASE: 'gitea'
volumes: volumes:
- ${data_path}/gitea/db:/var/lib/mysql - gitea-db:/var/lib/mysql
{{- end}} {{- end}}
lb: lb:
image: rancher/lb-service-haproxy:v0.7.9 image: rancher/lb-service-haproxy:v0.7.9
ports: ports:
- ${http_port}:${http_port}/tcp - ${http_port}:${http_port}/tcp
- ${ssh_port}:${ssh_port}/tcp - ${ssh_port}:${ssh_port}/tcp
volumes:
gitea-data-git:
driver: ${volume_driver}
gitea-data-ssh:
driver: ${volume_driver}
gitea-data-conf:
driver: ${volume_driver}
gitea-data-lfs:
driver: ${volume_driver}
gitea-data-log:
driver: ${volume_driver}
gitea-data-sessions:
driver: ${volume_driver}
{{- if eq .Values.db_link ""}}
gitea-db:
driver: ${volume_driver}
{{- end}}

View File

@ -19,23 +19,23 @@ catalog:
required: true required: true
default: "2222" default: "2222"
type: "int" type: "int"
- variable: data_path # - variable: data_path
description: "Path where to store the data of the Gitea-instance." # description: "Path where to store the data of the Gitea-instance."
label: "Data path" # label: "Data path"
required: true
default: "/var/lib/gitea"
type: "string"
# - variable: "volume_driver"
# description: "Volume driver to associate with this service."
# label: "Volume Driver"
# required: true # required: true
# default: "local" # default: "/var/lib/gitea"
# type: enum # type: "string"
# options: # List of options if using type of `enum` - variable: "volume_driver"
# - local description: "Volume driver to associate with this service."
# - rancher-nfs label: "Volume Driver"
# - rancher-efs required: true
# - rancher-ebs default: "local"
type: enum
options: # List of options if using type of `enum`
- local
- rancher-nfs
- rancher-efs
- rancher-ebs
- variable: "db_link" - variable: "db_link"
description: "External DB service to use with gitea instead of its own DB-Container." description: "External DB service to use with gitea instead of its own DB-Container."
label: "External DB service" label: "External DB service"