2025-11-26 14:39:49 +00:00
2025-11-26 14:24:27 +00:00
2025-11-26 14:26:12 +00:00
2025-11-26 14:17:00 +00:00
2025-11-26 13:02:45 +00:00
2025-11-26 14:39:49 +00:00
2025-11-26 09:48:58 +00:00

🌐 myip IP & RIPE Lookup WebApp

myip è una webapp minimale e containerizzata che mostra:

  • il tuo IP pubblico
  • informazioni RIPE utili (ASN, Provider/Holder, Prefisso annunciato)
  • UI moderna e responsiva
  • pulsante Copia IP
  • integrazione con ingress-nginx e PROXY protocol
  • design personalizzabile tramite CSS dedicato

Pensata per essere deployata come micro-servizio in Kubernetes.


Screenshot

screenshot


🚀 Funzionalità

🔍 Identificazione del client

  • Recupero del vero IP del client anche dietro più proxy/load balancer.
  • Compatibile con:
    • X-Forwarded-For
    • X-Real-IP
    • PROXY protocol v2

🛰️ Lookup RIPEstat

Per lindirizzo IP viene mostrato:

  • ASN
  • Provider (holder)
  • Prefisso annunciato

🎨 UI moderna

  • Font Montserrat
  • Layout centrato
  • Logo cliccabile
  • Animazioni CSS
  • Copy-to-clipboard
  • Modalità dark automatica

🔧 Semplice da deployare

  • Dockerfile incluso
  • Configurazione Helm-ready
  • Compatibile con ingress-nginx e cert-manager

📂 Struttura del progetto

myip-webapp/
├─ app.py
├─ requirements.txt
├─ Dockerfile
├─ static/
│  ├─ myip.css
│  ├─ logo.png
│  └─ favicon.ico
└─ README.md

🐳 Deploy con Docker

Build

docker build -t myip:latest .

Run

docker run -p 8080:8000 myip

Apri:

http://localhost:8080

☸️ Deploy in Kubernetes (Helm)

values.yaml minimale

ingress:
  enabled: true
  className: nginx
  host: myip.example.com

  annotations:
    cert-manager.io/cluster-issuer: letsencrypt-production
    nginx.ingress.kubernetes.io/use-forwarded-headers: "true"
    nginx.ingress.kubernetes.io/real-ip-header: "X-Forwarded-For"
    nginx.ingress.kubernetes.io/compute-full-forwarded-for: "true"

  tls:
    enabled: true

ingress-nginx PROXY protocol (fondamentale)

Nella ConfigMap del controller:

data:
  use-proxy-protocol: "true"
  real-ip-header: "proxy_protocol"
  set-real-ip-from: "10.166.93.0/24"
  use-forwarded-headers: "true"

HAProxy (L4) davanti ad ingress-nginx

server backend1 10.166.93.34:443 send-proxy-v2 check
server backend2 10.166.93.35:443 send-proxy-v2 check
server backend3 10.166.93.36:443 send-proxy-v2 check

🧠 Note Tecniche

Determinazione dellIP reale

Lapp utilizza:

X-Forwarded-For  X-Real-IP  remote_addr

ed è compatibile con proxy multipli e ingress-nginx.

Lookup RIPE

Usa la API ufficiale RIPEstat:

  • /network-info/
  • /as-overview/

Timeout veloce (2s) per non bloccare la UI.


🎨 Personalizzazioni

Tutto il design è modificabile in:

static/myip.css

Puoi sostituire:

  • logo.png → per branding
  • favicon.ico → icona personalizzata

🏁 Roadmap

  • Endpoint /api/ip
  • Multi-theme (light/dark manuale)
  • Mini-widget JavaScript includibile in altri siti
  • Supporto IPv6-only
  • Caching locale del lookup RIPE

🤝 Credits

  • Frontend & Styling by ChatGPT + NETECH style guidelines
  • Backend Python + Flask
  • Lookup dati: RIPEstat Data API
  • Supporto PROXY prot. v2: HAProxy + ingress-nginx

📄 Licenza

MIT (o altra licenza a tua scelta)

Description
No description provided
Readme 363 KiB
Languages
Python 85.7%
CSS 13.3%
Dockerfile 1%