
github/virga-actions-runner本镜像用于在Kubernetes集群中部署和运行自托管的GitHub Actions运行器,集成了Argo工具和Kubectl命令行工具。主要用途是为GitHub仓库提供自定义的、运行在Kubernetes环境中的Actions执行环境,支持与Kubernetes集群资源的交互及Argo相关工作流的管理。
运行器注册及功能启用需通过以下环境变量配置:
| 环境变量名 | 描述 | 必要性 |
|---|---|---|
GITHUB_REPOSITORY | 目标GitHub仓库地址(格式:owner/repo)或组织地址(格式:org:orgname) | 必需 |
GITHUB_TOKEN | 具有repo或admin:org权限的GitHub个人访问令牌(PAT),用于注册运行器 | 必需 |
RUNNER_NAME | 运行器名称(可选,默认自动生成) | 可选 |
RUNNER_LABELS | 运行器标签(逗号分隔,如k8s,argo,kubectl),用于工作流定向调度 | 可选 |
yamlapiVersion: apps/v1 kind: Deployment metadata: name: github-actions-runner namespace: actions-runner spec: replicas: 1 selector: matchLabels: app: actions-runner template: metadata: labels: app: actions-runner spec: containers: - name: runner image: [镜像名称] # 替换为实际镜像地址 env: - name: GITHUB_REPOSITORY value: "your-org/your-repo" # 替换为目标仓库/组织 - name: GITHUB_TOKEN valueFrom: secretKeyRef: name: github-runner-secret key: token - name: RUNNER_LABELS value: "k8s,argo,kubectl" resources: requests: cpu: "1" memory: "1Gi" limits: cpu: "2" memory: "2Gi"
repo(仓库级别)或admin:org(组织级别)bashkubectl create secret generic github-runner-secret -n actions-runner --from-literal=token=your_github_pat_token
在GitHub仓库工作流文件(如.github/workflows/k8s-deploy.yml)中,可指定使用该运行器:
yamlname: Deploy to Kubernetes on: [push] jobs: deploy: runs-on: [self-hosted, k8s, argo] # 匹配运行器标签 steps: - name: Checkout code uses: actions/checkout@v4 - name: Deploy to cluster run: | kubectl apply -f k8s/deployment.yaml # 使用内置kubectl argo workflow submit workflows/deploy.yaml # 使用内置Argo工具


manifest unknown 错误
TLS 证书验证失败
DNS 解析超时
410 错误:版本过低
402 错误:流量耗尽
身份认证失败错误
429 限流错误
凭证保存错误
来自真实用户的反馈,见证轩辕镜像的优质服务