The config you linked me to is in a single line, I’m not sure I understand what that is?
My config is:
proxy_cache_path /var/lib/nginx/cache-github levels=1:2 keys_zone=github:1024m; server { server_name api.github-proxy.corp.mydomain.com; location / { resolver 8.8.8.8; proxy_pass https://api.github.com/; proxy_set_header Authorization "token MyGeneratedToken"; proxy_cache github; proxy_cache_valid 200 302 1h; proxy_ignore_headers Expires Cache-Control Set-Cookie X-Accel-Redirect X-Accel-Expires; proxy_cache_use_stale error timeout invalid_header updating http_500 http_502 http_503 http_504; } }