Skip to content

Instantly share code, notes, and snippets.

View darkraiden's full-sized avatar
🎯
Focusing

Davide Di Mauro darkraiden

🎯
Focusing
View GitHub Profile
@darkraiden
darkraiden / getlocalIP.go
Created May 28, 2019 17:23 — forked from ankanch/getlocalIP.go
[Golang] Get Public IP address via Public IP API
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func main() {
url := "https://api.ipify.org?format=text" // we are using a pulib IP API, we're using ipify here, below are some others
// https://www.ipify.org
// http://myexternalip.com

Keybase proof

I hereby claim:

  • I am darkraiden on github.
  • I am darkraiden (https://keybase.io/darkraiden) on keybase.
  • I have a public key whose fingerprint is 3AFD E676 1217 9C40 5E34 886A 6FC1 9224 F903 467E

To claim this, I am signing this object: