sample logs
2023-01-30 00:00:31,344 [xxxxx] INFO LogService - 2023-01-30 00:00:31 0.0.0.0 - 0.0.0.0 1025 GET /data/foo/bar foobar
awk '{A[$13]++}END{for(i in A)print i,A[i]}' access.log
DELETE 7034
GET 660341| { | |
| "editor.fontFamily": "JetBrains Mono", | |
| "editor.fontSize": 13, | |
| "editor.fontLigatures": true, | |
| "editor.letterSpacing": 0.3, | |
| "editor.smoothScrolling": true, | |
| "workbench.colorTheme": "GitHub Dark Default", | |
| "workbench.preferredDarkColorTheme": "GitHub Dark Default", | |
| "workbench.preferredHighContrastColorTheme": "GitHub Dark Default", |
sample logs
2023-01-30 00:00:31,344 [xxxxx] INFO LogService - 2023-01-30 00:00:31 0.0.0.0 - 0.0.0.0 1025 GET /data/foo/bar foobar
awk '{A[$13]++}END{for(i in A)print i,A[i]}' access.log
DELETE 7034
GET 660341minikube ssh sudo resolvectl dns eth0 8.8.8.8 8.8.4.4
minikube ssh sudo resolvectl dns docker0 8.8.8.8 8.8.4.4
minikube ssh sudo resolvectl dns sit0 8.8.8.8 8.8.4.4
kubernetes/minikube#13497 (comment)
Or edit /etc/resolve.conf directly
| use proconio::input; | |
| use rand::prelude::*; | |
| fn main() { | |
| input! { | |
| n: usize | |
| }; | |
| let mut rng = rand::thread_rng(); | |
| let mut cnt = 0.0; |
macro_rules! chmin {| package main | |
| import( | |
| "fmt" | |
| "time" | |
| ) | |
| func main() { | |
| var ( | |
| o []Option |
下記のように、set_real_ip_fromにLBやIngressのIPを記載し、real_ip_recursiveを設定することで、remote_addr変数にクライアントの ソース元IPを入れることができるようです。
##
# Logging Settings
##
real_ip_header X-Forwarded-For;
set_real_ip_from 130.211.0.0/22;
set_real_ip_from 35.191.0.0/16;