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
// how to use boost.asio + sendfile(2) | |
// Michał Papierski <michal@papierski.net> | |
#include <iostream> | |
#include <string> | |
#include <boost/asio.hpp> | |
#include <boost/make_shared.hpp> | |
#include <boost/shared_ptr.hpp> | |
#include <boost/ref.hpp> | |
#include <boost/bind.hpp> | |
#include <boost/enable_shared_from_this.hpp> |
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
#include <memory> | |
#include <iostream> | |
#include <sstream> | |
#include <utility> | |
#include <algorithm> | |
#include <iterator> | |
struct sequence_tag {}; | |
struct pointer_tag {}; |
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
#server.modules += ( "mod_rewrite") | |
# Workaround to have a working reverse-proxy that matches an URL does URL rewriting in Ligghtpd. | |
# | |
# Ligtthpd 1.4.28 cannot perform both matching and URL rewriting at the same time. | |
# Therefore we need to define 2 proxies, one does the matching and bounce the request | |
# to the other one, in charge of rewriting the URL before proxying the request to the target server. | |
# | |
# More about this here: | |
# http://redmine.lighttpd.net/issues/164#note-9 |