File size: 416 Bytes
b1edb56
 
 
 
 
926faa0
b1edb56
c666345
b1edb56
926faa0
b1edb56
 
 
 
926faa0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
events {}
http {
    server {
        listen 7860;
        location / {
            # Check the Bearer token
            if ($http_authorization != "Bearer ${ACCESS_TOKEN}") {
                return 401 "Unauthorized: Invalid ACCESS_TOKEN\n";
            }
            proxy_pass http://127.0.0.1:11434;
            proxy_set_header Host $host;
            proxy_set_header X-Real-IP $remote_addr;
        }
    }
}