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: | ๐Ÿ”„ Mycelium Reverse Proxy - Global Access

๐Ÿ”„ Mycelium Reverse Proxy - Global Access

โœ… SUCCESS! True Global Mycelium Access via Reverse Proxy

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.

๐Ÿ”„ Reverse Proxy Architecture

This deployment uses a reverse proxy pattern which is the professional way to expose internal services globally:

๐ŸŒ Traffic Flow:

  1. Global Client โ†’ Mycelium IPv6 + Port (8080/8081/8082)
  2. nginx Reverse Proxy โ†’ Receives request on host network
  3. Internal Forwarding โ†’ proxy_pass to nginx-mycelium.default.svc.cluster.local:80
  4. Kubernetes Load Balancer โ†’ Distributes to 3 nginx pods
  5. Response โ†’ Back through the same path to global client

Benefits: Clean separation, maintains load balancing, easy to scale, production-ready!

๐ŸŒ Global Access URLs

Your website is now truly globally accessible via:

Port 8080 (Node 1):

  • http://[51d:3596:6cc3:81e7:ff0f:d546:3737:4c8c]:8080
  • http://[476:c4f:b4cb:7205:ff0f:f56e:abea:6905]:8080

Port 8081 (Node 2):

  • http://[538:964a:a1e1:4057:ff0f:63c7:960b:7c27]:8081
  • http://[552:5984:2d97:72dc:ff0f:39ef:6ec:a48c]:8081

Port 8082 (Node 3):

  • http://[437:9faf:1f1a:e2b1:ff0f:1fd9:7fd5:1095]:8082
  • http://[5c3:a162:45ab:6c53:ff0f:8c55:36b0:24af]:8082

Anyone with Mycelium can access your website from anywhere in the world!

๐Ÿงช Test Global Accessibility

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! ๐ŸŒ