0
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

Curlまとめ

Posted at

はじめに

  • curlコマンド とは?
  • ipconfig.me とは?
  • curlでグローバルIPアドレスを確認する方法

curlコマンド とは?

cURL 【client for URL】
UNIX系OSでよく利用されるコマンドおよびプログラムの一つで、様々なプロトコル(通信手順)を用いてURLで示されるネットワーク上の場所との間でデータの送受信を行うもの。

ipconfig.me とは?

ifconfig.meというネットワークの接続情報を表示してくれるウェブサービスがあります。そこに curl をするとグローバルIPを返してくれる。
https://ifconfig.co/https://ipinfo.io/ipなどの類似サービスもあります。 (@lo48576 さんより共有)

curlでグローバルIPアドレスを確認する方法

コマンド
$ curl -s ifconfig.me
xxx.xxx.xxx.xxx  #IPアドレスが確認できる

まとめ

curlを利用して、自信のPCのグローバルIPアドレスを確認できる👀
HTTPレスポンスの本文も理解すると、エラー修正がはかどりそう💡

参考サイト

0
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?