---
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: code-server
  name: code-server
  namespace: development
spec:
  selector:
    matchLabels:
      app: code-server
  replicas: 1
  template:
    metadata:
      labels:
        app: code-server
    spec:
      containers:
      - image: ghcr.io/linuxserver/code-server@sha256:b05386388edc547d6125496aad75e0e6cff6e7272426c108cb6b7aebb63667b3
        imagePullPolicy: Always
        name: code-server
        env:
        - name: "TZ"
          value: "Europe/Zurich"
        - name: "DOCKER_MODS"
          value: "linuxserver/mods:code-server-docker|linuxserver/mods:code-server-python3|linuxserver/mods:code-server-shellcheck|linuxserver/mods:universal-git"
        # - name: "PASSWORD"
        #   valueFrom:
        #     secretKeyRef:
        #       name: code-server-password
        #       key: password
        resources:
          requests:
            cpu: 100m
            memory: 100Mi
          limits:
            cpu: 500m
            memory: 200Mi
        ports:
        - containerPort: 8443
        volumeMounts:
        - mountPath: /config
          name: code-server
      volumes:
      - name: code-server
        persistentVolumeClaim:
          claimName: code-server-data-pvc
