Last active
February 2, 2017 22:04
-
-
Save es/ef4da0558c23f8a9e83d1f54ae12bca9 to your computer and use it in GitHub Desktop.
Example Nginx (built with OpenResty’s Lua module) config adding a header with the time since epoch to responses
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
events { | |
worker_connections 42; | |
} | |
http { | |
server { | |
listen 8080; | |
header_filter_by_lua_block { | |
ngx.header['X-Epoch'] = ngx.time() | |
} | |
location / { | |
return 200 'Hello, World!'; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment