Compare commits
7 Commits
44088e1a91
...
1352cf33ab
| Author | SHA1 | Date | |
|---|---|---|---|
| 1352cf33ab | |||
|
|
c30f598103 | ||
|
|
f1a95f9ab6 | ||
|
|
106e0d4fd5 | ||
|
|
1526b9cc9c | ||
|
|
ff426fd6aa | ||
|
|
e7bb0c0b53 |
6
apps/nginx-canary/namespace.yaml
Normal file
6
apps/nginx-canary/namespace.yaml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: nginx-canary
|
||||||
|
labels:
|
||||||
|
track: canary
|
||||||
20
apps/nginx-mcp/application.yaml
Normal file
20
apps/nginx-mcp/application.yaml
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: nginx-mcp
|
||||||
|
namespace: argocd
|
||||||
|
spec:
|
||||||
|
project: default
|
||||||
|
source:
|
||||||
|
repoURL: http://gitea-http.gitea.svc.cluster.local:3000/admin/k3s-gitops
|
||||||
|
path: apps/nginx-mcp
|
||||||
|
targetRevision: HEAD
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: nginx-mcp
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
111
apps/nginx-mcp/configmap.yaml
Normal file
111
apps/nginx-mcp/configmap.yaml
Normal file
@@ -0,0 +1,111 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: nginx-mcp-html
|
||||||
|
namespace: nginx-mcp
|
||||||
|
data:
|
||||||
|
index.html: |
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>Hello from MCP - v1 Stable</title>
|
||||||
|
<style>
|
||||||
|
* { margin: 0; padding: 0; box-sizing: border-box; }
|
||||||
|
body {
|
||||||
|
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
|
||||||
|
background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
|
||||||
|
min-height: 100vh;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
.card {
|
||||||
|
background: rgba(255,255,255,0.08);
|
||||||
|
backdrop-filter: blur(12px);
|
||||||
|
border: 1px solid rgba(255,255,255,0.15);
|
||||||
|
border-radius: 20px;
|
||||||
|
padding: 60px 80px;
|
||||||
|
text-align: center;
|
||||||
|
box-shadow: 0 25px 50px rgba(0,0,0,0.4);
|
||||||
|
max-width: 600px;
|
||||||
|
width: 90%;
|
||||||
|
}
|
||||||
|
.badge {
|
||||||
|
display: inline-block;
|
||||||
|
background: linear-gradient(90deg, #667eea, #764ba2);
|
||||||
|
color: #fff;
|
||||||
|
font-size: 0.75rem;
|
||||||
|
font-weight: 700;
|
||||||
|
letter-spacing: 2px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
padding: 6px 18px;
|
||||||
|
border-radius: 20px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
.version-badge {
|
||||||
|
display: inline-block;
|
||||||
|
background: rgba(102,126,234,0.2);
|
||||||
|
border: 1px solid rgba(102,126,234,0.5);
|
||||||
|
color: #a78bfa;
|
||||||
|
font-size: 0.7rem;
|
||||||
|
font-weight: 700;
|
||||||
|
letter-spacing: 2px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
padding: 4px 14px;
|
||||||
|
border-radius: 20px;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
h1 {
|
||||||
|
font-size: 3rem;
|
||||||
|
font-weight: 800;
|
||||||
|
background: linear-gradient(90deg, #a78bfa, #60a5fa);
|
||||||
|
-webkit-background-clip: text;
|
||||||
|
-webkit-text-fill-color: transparent;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
.subtitle { color: #94a3b8; font-size: 1rem; margin-bottom: 40px; }
|
||||||
|
.ip-box {
|
||||||
|
background: rgba(0,0,0,0.35);
|
||||||
|
border: 1px solid rgba(103,78,167,0.5);
|
||||||
|
border-radius: 12px;
|
||||||
|
padding: 20px 30px;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
.ip-label { font-size: 0.7rem; letter-spacing: 2px; text-transform: uppercase; color: #64748b; margin-bottom: 8px; }
|
||||||
|
.ip-value { font-size: 1.8rem; font-weight: 700; font-family: 'Courier New', monospace; color: #a78bfa; letter-spacing: 3px; }
|
||||||
|
.footer { font-size: 0.78rem; color: #475569; }
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="card">
|
||||||
|
<div class="badge">🤖 MCP Powered</div><br>
|
||||||
|
<div class="version-badge">v1 stable</div>
|
||||||
|
<h1>Hello from MCP</h1>
|
||||||
|
<p class="subtitle">Deployed via AI-assisted GitOps pipeline</p>
|
||||||
|
<div class="ip-box">
|
||||||
|
<div class="ip-label">Your IP Address</div>
|
||||||
|
<div class="ip-value" id="ip">Detecting...</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer">nginx-mcp · thedevops.dev · ArgoCD + Traefik</div>
|
||||||
|
</div>
|
||||||
|
<script>
|
||||||
|
fetch('https://api.ipify.org?format=json')
|
||||||
|
.then(r => r.json())
|
||||||
|
.then(d => { document.getElementById('ip').textContent = d.ip; })
|
||||||
|
.catch(() => { document.getElementById('ip').textContent = window.location.hostname; });
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
nginx.conf: |
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name _;
|
||||||
|
root /usr/share/nginx/html;
|
||||||
|
index index.html;
|
||||||
|
location / {
|
||||||
|
try_files $uri $uri/ =404;
|
||||||
|
}
|
||||||
|
}
|
||||||
56
apps/nginx-mcp/deployment.yaml
Normal file
56
apps/nginx-mcp/deployment.yaml
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: nginx-mcp
|
||||||
|
namespace: nginx-mcp
|
||||||
|
labels:
|
||||||
|
app: nginx-mcp
|
||||||
|
track: stable
|
||||||
|
version: v1.0.0
|
||||||
|
spec:
|
||||||
|
replicas: 3
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: nginx-mcp
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: nginx-mcp
|
||||||
|
track: stable
|
||||||
|
version: v1.0.0
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: nginx
|
||||||
|
image: nginx:1.25-alpine
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
volumeMounts:
|
||||||
|
- name: html
|
||||||
|
mountPath: /usr/share/nginx/html/index.html
|
||||||
|
subPath: index.html
|
||||||
|
- name: html
|
||||||
|
mountPath: /etc/nginx/conf.d/default.conf
|
||||||
|
subPath: nginx.conf
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 50m
|
||||||
|
memory: 64Mi
|
||||||
|
limits:
|
||||||
|
cpu: 200m
|
||||||
|
memory: 128Mi
|
||||||
|
readinessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /
|
||||||
|
port: 80
|
||||||
|
initialDelaySeconds: 5
|
||||||
|
periodSeconds: 10
|
||||||
|
livenessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /
|
||||||
|
port: 80
|
||||||
|
initialDelaySeconds: 10
|
||||||
|
periodSeconds: 20
|
||||||
|
volumes:
|
||||||
|
- name: html
|
||||||
|
configMap:
|
||||||
|
name: nginx-mcp-html
|
||||||
6
apps/nginx-mcp/namespace.yaml
Normal file
6
apps/nginx-mcp/namespace.yaml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: nginx-mcp
|
||||||
|
labels:
|
||||||
|
track: stable
|
||||||
16
apps/nginx-mcp/service.yaml
Normal file
16
apps/nginx-mcp/service.yaml
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: nginx-mcp
|
||||||
|
namespace: nginx-mcp
|
||||||
|
labels:
|
||||||
|
app: nginx-mcp
|
||||||
|
track: stable
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app: nginx-mcp
|
||||||
|
ports:
|
||||||
|
- name: http
|
||||||
|
port: 80
|
||||||
|
targetPort: 80
|
||||||
|
type: ClusterIP
|
||||||
Reference in New Issue
Block a user