<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Bits of Arrogance &#187; nginx</title>
	<atom:link href="https://www.crummylogic.com/wordpress/?feed=rss2&#038;tag=nginx" rel="self" type="application/rss+xml" />
	<link>https://www.crummylogic.com/wordpress</link>
	<description>Making myself pervasive</description>
	<lastBuildDate>Wed, 04 Oct 2017 17:25:53 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=4.2.4</generator>
	<item>
		<title>Host ownCloud behind your nginx reverse proxy</title>
		<link>https://www.crummylogic.com/wordpress/?p=410</link>
		<comments>https://www.crummylogic.com/wordpress/?p=410#comments</comments>
		<pubDate>Fri, 15 Jul 2016 13:34:19 +0000</pubDate>
		<dc:creator><![CDATA[jrdalrymple]]></dc:creator>
				<category><![CDATA[Technology junk]]></category>
		<category><![CDATA[HowTo]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[ownCloud]]></category>
		<category><![CDATA[reverse proxy]]></category>

		<guid isPermaLink="false">http://www.crummylogic.com/wordpress/?p=410</guid>
		<description><![CDATA[If you&#8217;re like me your public IP space is limited (/28 in my case) and your hosting needs are diverse. Lot&#8217;s of websites behind my 1 nginx reverse proxy that you&#8217;re using right now to load this site&#8217;s content. My configuration is pretty simple and really cool in my opinion. All of my SSL is &#8230; <a href="https://www.crummylogic.com/wordpress/?p=410" class="more-link">Continue reading <span class="screen-reader-text">Host ownCloud behind your nginx reverse proxy</span> <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>If you&#8217;re like me your public IP space is limited (/28 in my case) and your hosting needs are diverse. Lot&#8217;s of websites behind my 1 nginx reverse proxy that you&#8217;re using right now to load this site&#8217;s content.</p>
<p>My configuration is pretty simple and really cool in my opinion. All of my SSL is terminated on my reverse proxy so I don&#8217;t have to manage certificates inside my network at all. While this configuration isn&#8217;t particularly exotic, I thought it might be worth sharing anyway. I bet someone will someday find good use from it:</p>
<pre>
server {
   listen  80;
   server_name     owncloud.example.net;
   rewrite ^       https://$server_name$request_uri? permanent;
}

server {
        listen       443;
        server_name  owncloud.example.net;

        ssl                  on;
        ssl_certificate      /etc/nginx/conf.d/ssl/owncloud.example.net.bundle.crt;
        ssl_certificate_key  /etc/nginx/conf.d/ssl/owncloud.example.net.key;
# Ridiculously high timeout due to long requests for uploads
        ssl_session_timeout  5m;

        ssl_protocols  SSLv2 SSLv3 TLSv1;
        ssl_ciphers  HIGH:!aNULL:!MD5;

        access_log  /var/log/nginx/owncloud.example.net.log main;

        proxy_redirect  off;
        proxy_set_header        Host    $host;
        proxy_set_header        X-Real-IP       $remote_addr;
        proxy_set_header        X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_buffering         off;
        proxy_set_header Connection     "Keep-Alive";

# Allow uploads up to 16GB in size
        client_max_body_size    16000m;

# transparently handle requests to server root
        location / {
                rewrite ^ https://owncloud.example.net/owncloud$request_uri redirect;
        }

        location /owncloud {
# owncloud.example.local is your actual owncloud server inside your network
                proxy_pass http://owncloud.example.local:80/owncloud;
        }

}
</pre>
<p>This works, not only the web client but also the mobile and desktop clients. I put in the neat rewrite rule so that users can just type the server name and don&#8217;t have to get excited about the owncloud URI component. ownCloud is installed using default configurations on the internal server, no complex configurations or anything there. I love nginx reverse proxying.</p>
]]></content:encoded>
			<wfw:commentRss>https://www.crummylogic.com/wordpress/?feed=rss2&#038;p=410</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
