apiVersion: apps/v1
kind: Deployment
metadata:
  name: gitea
  labels:
    app: gitea
spec:
  replicas: 1
  selector:
    matchLabels:
      app: gitea
  template:
    metadata:
      labels:
        app: gitea
    spec:
      containers:
      - name: gitea-server
        image: gitea/gitea:1.6
        ports:
        - containerPort: 22
        - containerPort: 3000
        volumeMounts:
        - mountPath: /data
          name: gitea-volume
      volumes:
      - name: gitea-volume
        hostPath:
          path: /data/gitea
          type: DirectoryOrCreate
