99 lines
2.2 KiB
YAML
99 lines
2.2 KiB
YAML
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
labels:
|
|
run: gitea
|
|
name: gitea
|
|
namespace: pew
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
run: gitea
|
|
template:
|
|
metadata:
|
|
labels:
|
|
run: gitea
|
|
spec:
|
|
containers:
|
|
- name: gitea
|
|
image: gitea/gitea:1.12.5
|
|
# after initial install options must be changed at /data/gitea/conf/app.ini
|
|
env:
|
|
- name: RUN_MODE
|
|
value: "prod"
|
|
- name: DOMAIN
|
|
value: "git.seaturtle.pw"
|
|
- name: SSH_DOMAIN
|
|
value: "git.seaturtle.pw"
|
|
- name: SSH_PORT
|
|
value: "37122"
|
|
- name: ROOT_URL
|
|
value: "https://git.seaturtle.pw/"
|
|
- name: LFS_START
|
|
value: "true"
|
|
- name: DISABLE_REGISTRATION
|
|
value: "true"
|
|
- name: REQUIRE_SIGNIN_VIEW
|
|
value: "false"
|
|
- name: USER_UID
|
|
value: "1000"
|
|
- name: USER_GUID
|
|
value: "1000"
|
|
volumeMounts:
|
|
- mountPath: /data
|
|
name: gitea-data
|
|
readOnly: false
|
|
- mountPath: /etc/timezone
|
|
subPath: timezone
|
|
name: gitea-config
|
|
readOnly: true
|
|
- mountPath: /etc/localtime
|
|
name: gitea-localtime
|
|
readOnly: true
|
|
ports:
|
|
- name: http
|
|
containerPort: 3000
|
|
- name: ssh
|
|
containerPort: 37122
|
|
volumes:
|
|
- name: gitea-data
|
|
hostPath:
|
|
path: /bigdata/k8s-config/gitea/data
|
|
- name: gitea-config
|
|
configMap:
|
|
name: gitea-config
|
|
- name: gitea-localtime
|
|
hostPath:
|
|
path: /usr/share/zoneinfo/America/New_York
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
labels:
|
|
run: gitea
|
|
name: gitea
|
|
namespace: pew
|
|
spec:
|
|
selector:
|
|
run: gitea
|
|
ports:
|
|
- name: http
|
|
port: 3000
|
|
protocol: TCP
|
|
- name: ssh
|
|
port: 37122
|
|
protocol: TCP
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: gitea-config
|
|
namespace: pew
|
|
data:
|
|
timezone: |
|
|
America/New_York
|