<?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>oidc-server &#8211; 天地一沙鸥</title>
	<atom:link href="https://haoluobo.com/tag/oidc-server/feed/" rel="self" type="application/rss+xml" />
	<link>https://haoluobo.com</link>
	<description>to be continue....</description>
	<lastBuildDate>Fri, 18 Feb 2022 02:29:48 +0000</lastBuildDate>
	<language>zh-Hans</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.8.2</generator>
	<item>
		<title>开源 wiki 和知识管理系统 Outline 的快速部署脚本</title>
		<link>https://haoluobo.com/2022/02/outline-docker-compose/</link>
					<comments>https://haoluobo.com/2022/02/outline-docker-compose/#comments</comments>
		
		<dc:creator><![CDATA[vicalloy]]></dc:creator>
		<pubDate>Wed, 16 Feb 2022 12:42:00 +0000</pubDate>
				<category><![CDATA[vicalloy的庄家]]></category>
		<category><![CDATA[oidc]]></category>
		<category><![CDATA[oidc-server]]></category>
		<category><![CDATA[outline]]></category>
		<category><![CDATA[wiki]]></category>
		<guid isPermaLink="false">https://haoluobo.com/?p=12248</guid>

					<description><![CDATA[项目地址：&#160;https://github.com/vicalloy/outline-docker-c [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p>项目地址：&nbsp;<a href="https://github.com/vicalloy/outline-docker-compose">https://github.com/vicalloy/outline-docker-compose</a></p>



<p>前一段想部署一个 Wiki ，看了一圈被&nbsp;<a href="https://www.getoutline.com/">Outline</a>&nbsp;的颜值吸引。Outline 支持部署到自己服务器，只是自部署的体验真的不太好。Outline 部署主要就下面几个问题。</p>



<ol class="wp-block-list"><li>默认使用 AWS 的 S3 服务。</li><li>不提供用户管理模块，需通过 Slack 、Google 或是自建 OIDC 服务进行登录。</li></ol>



<p>网上已用基于 docker-compose 的部署方案主要有两个：</p>



<ol class="wp-block-list"><li><a href="https://github.com/chsasank/outline-wiki-docker-compose">outline-wiki-docker-compose</a><ol><li>提供交互式脚本，生成 docker-compose 配置文件。</li><li>使用 Slack 进行登录，国内使用体验不好。</li><li>脚本太老，存在 Bug ，图片上传后显示不了。</li></ol></li><li><a href="https://github.com/soulteary/docker-outline">docker-outline</a><ol><li>国内用户写的部署脚本。目前中文网络环境下搜索 Outline 找到的都是 soulteary 的文章。</li><li>脚本不够智能，配置参数还是有些多。</li><li>内置了 OIDC 服务，不过好像不支持用户管理，只能创建一个用户。（注：没仔细研究过，不确定）</li></ol></li></ol>



<p>出于自己部署的需要，参考&nbsp;<code>outline-wiki-docker-compose</code>&nbsp;的实现，新开了 Outline 的部署项目。</p>



<ol class="wp-block-list"><li>配置文件尽量简化。只有&nbsp;<code>config.sh</code>&nbsp;一个配置文件，其他配置文件由脚本生成。</li><li>内置 OIDC 服务，可以直接通过 Web 管理用户。</li></ol>



<h2 class="wp-block-heading" id="odic-server">ODIC Server</h2>



<p>项目地址：<a href="https://github.com/vicalloy/oidc-server/">https://github.com/vicalloy/oidc-server/</a></p>



<p>多很多想自己部署 Outline 的人来说，没有本地的认证系统是一个非常头痛的问题。该Issue <a rel="noreferrer noopener" href="https://github.com/outline/outline/issues/1881" data-type="URL" data-id="https://github.com/outline/outline/issues/1881" target="_blank">Local Authentication #1881</a> 的评论数是 Outline 未关闭 Issue 中最多的。我也一度被该问题劝退。</p>



<p>可能 Outline 主推的还是 Cloud 版，虽然内建认证对自部署影响很大，官方依旧没有给出明确的支持方案。注：不少服务是提供OIDC认证的，如果你同时使用Gitlab，你可以使用Gitlab做OIDC认证服务器。</p>



<p>我最初的想法部署一个做简单的ODIC认证服务器给 Outline。出于节约内存的考虑，这个服务最好是Go或是Rust编写。找了一圈未发现合适的应用，于是回到了自己最熟悉的 Django 上。</p>



<p><a href="https://github.com/vicalloy/oidc-server/">OIDC Server</a> 主体代码来源于 <a href="https://github.com/juanifioren/django-oidc-provider">django-oidc-provider</a> 的 example 。甚至可以说这个项目就是将 example 做了个打包。依托于 Django 优秀的插件机制和 Admin 模块，在几乎不用写代码的情况下就可以得到一个还过得去的 OIDC Server。当然缺点是内存占用量有点大，这个服务需要用掉大概100M的内存。</p>



<p>注：<code>ODIC Server</code> docker镜像使用 <code>Github Action</code> 进行构建。不得不说 <code>Github Action</code> 的体验真的非常棒。</p>
]]></content:encoded>
					
					<wfw:commentRss>https://haoluobo.com/2022/02/outline-docker-compose/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
	</channel>
</rss>
