98 lines
2.1 KiB
YAML
98 lines
2.1 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
|
|
env:
|
|
- name: RUN_MODE
|
|
value: "prod"
|
|
- name: DOMAIN
|
|
value: "git.seaturtle.pw"
|
|
- name: SSH_DOMAIN
|
|
value: "git.seaturtle.pw"
|
|
- name: SSH_PORT
|
|
value: "2223"
|
|
- name: ROOT_URL
|
|
value: "https://git.seaturtle.pw/"
|
|
- name: LFS_START
|
|
value: "true"
|
|
- name: DISABLE_REGISTRATION
|
|
value: "true"
|
|
- name: REQUIRED_SIGNIN_VIEW
|
|
value: "true"
|
|
- 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: 22
|
|
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: 2223
|
|
protocol: TCP
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: gitea-config
|
|
namespace: pew
|
|
data:
|
|
timezone: |
|
|
America/New_York
|