# test-argo **Repository Path**: heathcliffs/test-argo ## Basic Information - **Project Name**: test-argo - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2025-09-10 - **Last Updated**: 2025-09-11 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # MyChart 一个用于 Kubernetes 部署的 Helm Chart。 ## 概述 MyChart 是一个标准的 Helm chart,用于在 Kubernetes 集群中部署应用程序。它包含了部署、服务、入口控制器和水平自动扩缩容等常用的 Kubernetes 资源。 ## 功能特性 - 🚀 应用程序部署 (Deployment) - 🌐 服务暴露 (Service) - 🔗 入口控制 (Ingress) - 📈 水平自动扩缩容 (HPA) - 👤 服务账户 (ServiceAccount) - 🧪 连接测试 ## 快速开始 ### 前置条件 - Kubernetes 集群 (版本 1.19+) - Helm 3.0+ - kubectl 已配置并连接到集群 ### 安装 1. 克隆仓库: ```bash git clone cd ``` 2. 安装 chart: ```bash helm install my-release ./mychart ``` 3. 验证部署: ```bash kubectl get pods kubectl get services ``` ### 卸载 ```bash helm uninstall my-release ``` ## 配置 以下表格列出了 chart 的可配置参数及其默认值。 | 参数 | 描述 | 默认值 | |------|------|--------| | `replicaCount` | Pod 副本数量 | `1` | | `image.repository` | 镜像仓库 | `nginx` | | `image.tag` | 镜像标签 | `""` | | `image.pullPolicy` | 镜像拉取策略 | `IfNotPresent` | | `service.type` | 服务类型 | `ClusterIP` | | `service.port` | 服务端口 | `80` | | `ingress.enabled` | 启用 Ingress | `false` | | `autoscaling.enabled` | 启用自动扩缩容 | `false` | ### 自定义配置 你可以通过以下方式自定义配置: 1. 使用 `--set` 参数: ```bash helm install my-release ./mychart --set replicaCount=3 ``` 2. 使用自定义 values 文件: ```bash helm install my-release ./mychart -f custom-values.yaml ``` ## 目录结构 ``` mychart/ ├── Chart.yaml # Chart 元数据 ├── values.yaml # 默认配置值 ├── templates/ # Kubernetes 模板文件 │ ├── deployment.yaml │ ├── service.yaml │ ├── ingress.yaml │ ├── hpa.yaml │ ├── serviceaccount.yaml │ ├── _helpers.tpl │ ├── NOTES.txt │ └── tests/ │ └── test-connection.yaml └── .helmignore # Helm 忽略文件 ``` ## 测试 运行 Helm 测试来验证部署: ```bash helm test my-release ``` ## 开发 ### 本地开发 1. 验证 chart 语法: ```bash helm lint ./mychart ``` 2. 渲染模板(不安装): ```bash helm template my-release ./mychart ``` 3. 调试安装: ```bash helm install my-release ./mychart --debug --dry-run ``` ### 打包 ```bash helm package ./mychart ``` ## 贡献 欢迎提交 Issue 和 Pull Request! ## 许可证 [MIT License](LICENSE) ## 支持 如果你遇到问题或有疑问,请: 1. 查看 [Issues](../../issues) 页面 2. 创建新的 Issue 3. 联系维护者 --- **注意**: 请根据你的具体应用需求修改配置参数和文档内容。