Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Feature: add HARP/ExApps support

未关闭
#776 7 条评论 4 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
35/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
冷清
技术栈
docker, helm, kubernetes

调研方向

未指定任何文件或测试。首先检查现有的 Helm service 和 ingress 模板以及 chart 的 Kubernetes 配置,然后比较建议的 StatefulSet 和在受支持设置中的 Docker rootless/socket exposure。完成的标准是:ExApps 可以在不依赖特定集群 manifest 的情况下,使用正常工作的 service 和 ingress 配置进行部署。

由索引模型根据 Issue 内容生成。

描述

enhancement

Description of the change

I tried to add a StatefulSet with HARP to run exapps on kubernetes.
My tests were successful.

StatefulSet code:

apiVersion: v1
kind: ConfigMap
metadata:
  name: docker-daemon-config
data:
  daemon.json: |
    {
      "memory": "512m"
    }
---
apiVersion: apps/v1
kind: StatefulSet
metadata:
  labels:
    app: clouduvet
  name: clouduvet-harp
spec:
  serviceName: harp
  replicas: 1
  selector:
    matchLabels:
      app: clouduvet
  template:
    metadata:
      labels:
        app: clouduvet
    spec:
      volumes:
        - name: docker-config
          configMap:
            name: docker-daemon-config
      restartPolicy: Always
      securityContext:
        fsGroup: 1000
      containers:
        - name: appapi-harp
          image: ghcr.io/nextcloud/nextcloud-appapi-harp:release
          imagePullPolicy: Always
          env:
            - name: DOCKER_HOST
              value: unix:///run/user/1000/docker.sock
            - name: HP_SHARED_KEY
              valueFrom:
                secretKeyRef:
                  name: harp-shared-key
                  key: shared-key
            - name: NC_INSTANCE_URL
              value: "http://nextcloud.nextcloud.svc.cluster.local"
          resources:
            requests:
              cpu: "250m"
              memory: "512Mi"
            limits:
              cpu: "250m"
              memory: "512Mi"
          #securityContext:
          #  privileged: true
#---
#apiVersion: v1
#kind: Pod
#metadata:
#  name: appapi-harp
#  labels:
#    app: appapi-harp
#spec:
#  restartPolicy: Always
#  hostNetwork: false
#  containers:
#    - name: appapi-harp
#      image: ghcr.io/nextcloud/nextcloud-appapi-harp:release
#      imagePullPolicy: IfNotPresent
#      env:
#        - name: HP_SHARED_KEY
#          valueFrom:
#            secretKeyRef:
#              name: harp-shared-key
#              key: shared-key
#        - name: NC_INSTANCE_URL
#          value: "http://nextcloud.nextcloud.svc.cluster.local"
#      ports:
#        - containerPort: 8780
#        - containerPort: 8782
#      volumeMounts:
#        - name: docker-sock
#          mountPath: /var/run/docker.sock
#        - name: certs
#          mountPath: /certs
#  volumes:
#    - name: docker-sock
#      hostPath:
#        path: /var/run/docker.sock
#        type: Socket
#    - name: certs
#      hostPath:
#        path: /absolute/path/to/certs  # Change to absolute path on host
#        type: Directory

It allowed me to expose a docker rootless using harp. I put that here mostly so others may be able to reference it, feel free to use it :)
You also need to change the service and the ingress.

Benefits

ExApps support.

Possible drawbacks

The StatefulState approach is losely based on what I've done for gitlab runners on my cluster, it might not be the best approach.
I cannot guarantee that the manifest I provided can be used across every clusters.

Additional information

I am willing to create a pull request for this change. However, I'd appreciate some guidance on how to expose the docker socket of the host node in a manner that is compatible with a maximum of setups.

主要语言
Go Template
星标
536
派生
316
平均合并
4 天 16 小时
30 天内合并 PR
2

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

nextcloud/helm 的其他 Issue

查看 nextcloud/helm 的全部 Issue

相似的 Issue

更多 DevOps Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。