Initial commit: Add demo nginx application

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
argocd
2026-02-04 03:57:20 +08:00
commit a15c556ceb
3 changed files with 57 additions and 0 deletions

17
README.md Normal file
View File

@@ -0,0 +1,17 @@
# Demo Application
这是一个由ArgoCD管理的示例应用。
## 应用信息
- **应用名称**: demo-nginx
- **镜像**: nginx:1.25-alpine
- **副本数**: 2
- **访问端口**: NodePort 30080
## 更新应用
修改 `manifests/` 目录下的文件并提交到GitArgoCD会自动同步部署。
## 测试访问
```bash
curl http://<NODE_IP>:30080
```

27
manifests/deployment.yaml Normal file
View File

@@ -0,0 +1,27 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: demo-nginx
namespace: default
spec:
replicas: 2
selector:
matchLabels:
app: demo-nginx
template:
metadata:
labels:
app: demo-nginx
spec:
containers:
- name: nginx
image: nginx:1.25-alpine
ports:
- containerPort: 80
resources:
requests:
memory: "64Mi"
cpu: "100m"
limits:
memory: "128Mi"
cpu: "200m"

13
manifests/service.yaml Normal file
View File

@@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: demo-nginx
namespace: default
spec:
type: NodePort
selector:
app: demo-nginx
ports:
- port: 80
targetPort: 80
nodePort: 30080