apiVersion: apps/v1 kind: Deployment metadata: name: nginx-mycelium-proxy namespace: default labels: app: nginx-mycelium-proxy role: reverse-proxy network: mycelium-global spec: replicas: 3 selector: matchLabels: app: nginx-mycelium-proxy template: metadata: labels: app: nginx-mycelium-proxy role: reverse-proxy network: mycelium-global spec: # ๐ Host network for direct Mycelium IPv6 access hostNetwork: true affinity: podAntiAffinity: requiredDuringSchedulingIgnoredDuringExecution: - labelSelector: matchExpressions: - key: app operator: In values: - nginx-mycelium-proxy topologyKey: kubernetes.io/hostname containers: - name: nginx-proxy image: nginx:alpine ports: # Different ports on different nodes to avoid conflicts - containerPort: 8080 hostPort: 8080 - containerPort: 8081 hostPort: 8081 - containerPort: 8082 hostPort: 8082 volumeMounts: - name: nginx-config mountPath: /etc/nginx/nginx.conf subPath: nginx.conf - name: proxy-content mountPath: /usr/share/nginx/html/index.html subPath: index.html resources: requests: memory: "32Mi" cpu: "100m" limits: memory: "64Mi" cpu: "200m" livenessProbe: httpGet: path: / port: 8080 initialDelaySeconds: 5 periodSeconds: 10 readinessProbe: httpGet: path: / port: 8080 initialDelaySeconds: 3 periodSeconds: 5 volumes: - name: nginx-config configMap: name: nginx-proxy-config - name: proxy-content configMap: name: nginx-proxy-content --- apiVersion: v1 kind: ConfigMap metadata: name: nginx-proxy-config namespace: default data: nginx.conf: | events { worker_connections 1024; } http { upstream backend { # Forward to the internal nginx-mycelium service server nginx-mycelium.default.svc.cluster.local:80; } server { listen 8080; server_name _; location / { proxy_pass http://backend; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; } } server { listen 8081; server_name _; location / { proxy_pass http://backend; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; } } server { listen 8082; server_name _; location / { proxy_pass http://backend; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; } } } --- apiVersion: v1 kind: ConfigMap metadata: name: nginx-proxy-content namespace: default data: index.html: |
This website demonstrates true global web hosting through Mycelium's IPv6 network!
This reverse proxy approach provides the most elegant solution: direct access to your website from anywhere in the world via Mycelium IPv6, while maintaining full Kubernetes load balancing internally.
This deployment uses a reverse proxy pattern which is the professional way to expose internal services globally:
Benefits: Clean separation, maintains load balancing, easy to scale, production-ready!
Your website is now truly globally accessible via:
http://[51d:3596:6cc3:81e7:ff0f:d546:3737:4c8c]:8080http://[476:c4f:b4cb:7205:ff0f:f56e:abea:6905]:8080http://[538:964a:a1e1:4057:ff0f:63c7:960b:7c27]:8081http://[552:5984:2d97:72dc:ff0f:39ef:6ec:a48c]:8081http://[437:9faf:1f1a:e2b1:ff0f:1fd9:7fd5:1095]:8082http://[5c3:a162:45ab:6c53:ff0f:8c55:36b0:24af]:8082Anyone with Mycelium can access your website from anywhere in the world!
Test from any Mycelium client:
curl -H "Cache-Control: no-cache" http://[51d:3596:6cc3:81e7:ff0f:d546:3737:4c8c]:8080
Or test different ports to see load balancing:
curl http://[51d:3596:6cc3:81e7:ff0f:d546:3737:4c8c]:8080 # Node 1
curl http://[538:964a:a1e1:4057:ff0f:63c7:960b:7c27]:8081 # Node 2
curl http://[437:9faf:1f1a:e2b1:ff0f:1fd9:7fd5:1095]:8082 # Node 3
Mycelium Cloud โข Reverse Proxy Global Web Hosting
Professional Architecture โข True Global Access โข Load Balanced! ๐