apiVersion: v1 kind: ConfigMap metadata: name: nginx-config data: default.conf: | upstream letsencrypt { server letsencrypt:80 max_fails=0 fail_timeout=1s; } server { listen 80; listen [::]:80; server_name _; location / { add_header Content-Type text/plain; # Prevents download return 200 "¡Hola mundo! Demo de Kubernetes + Let's encrypt."; } # Redirect all traffic in /.well-known/ to letsencrypt location ^~ /.well-known/acme-challenge/ { proxy_pass http://letsencrypt; } }