|
|
<!doctype html>
|
|
|
<html class="no-js" lang="en">
|
|
|
<head>
|
|
|
<meta charset="utf-8">
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
<meta name="author" content="Lednerb">
|
|
|
<meta name="description" content="Bilberry Premium Theme for Hugo.">
|
|
|
<meta name="keywords" content="blog,personal,responsive,search,font awesome,pages,posts,multilingual,highlight.js,syntax highlighting,premium,shortcuts">
|
|
|
<meta name="generator" content="Hugo 0.50" />
|
|
|
<title> [筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記 | My cool new Blog</title>
|
|
|
<meta name="description" content="[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記 - Bilberry Premium Theme for Hugo.">
|
|
|
<meta itemprop="name" content="[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記">
|
|
|
<meta itemprop="description" content="[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記 - Bilberry Premium Theme for Hugo.">
|
|
|
<meta property="og:title" content="[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記">
|
|
|
<meta property="og:description" content="[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記 - Bilberry Premium Theme for Hugo.">
|
|
|
<meta property="og:image" content="https://www.gravatar.com/avatar/88188b6cc451928eba90e8400bc68086?size=200">
|
|
|
<meta property="og:url" content="https://h.cowbay.org/article/e7-ad-86-e8-a8-98-centos-6-6-iredmail-0-9-4-e5-ae-89-e8-a3-9d-e7-ad-86-e8-a8-98/">
|
|
|
<meta property="og:site_name" content="My cool new Blog">
|
|
|
<meta property="og:type" content="article">
|
|
|
<link rel="icon" type="image/png" href="https://h.cowbay.org/favicon-32x32.png" sizes="32x32">
|
|
|
<link rel="icon" type="image/png" href="https://h.cowbay.org/favicon-16x16.png" sizes="16x16">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="https://h.cowbay.org/sass/combined.min.717098cb5503581e75f12e486a847ca410bf8367d4d8713f4c37affc868c5a1d.css">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</head>
|
|
|
<body class="bilberry-hugo-theme">
|
|
|
|
|
|
<nav>
|
|
|
|
|
|
<div class="container">
|
|
|
<ul class="topnav">
|
|
|
|
|
|
|
|
|
<li><a href="/page/about-bilberry/">About Bilberry</a></li>
|
|
|
|
|
|
|
|
|
|
|
|
<li><a href="https://github.com/Lednerb/bilberry-hugo-theme" target="_blank">Github</a></li>
|
|
|
|
|
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
|
<div id="search-box" class="search">
|
|
|
<i class="fa fa-search"></i>
|
|
|
<input id="search" type="text" placeholder="Search ...">
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
</nav>
|
|
|
|
|
|
|
|
|
<header>
|
|
|
<div class="container">
|
|
|
<div class="logo">
|
|
|
<a href="/" class="logo">
|
|
|
|
|
|
<img src="https://www.gravatar.com/avatar/88188b6cc451928eba90e8400bc68086?d=mm&size=200" alt="">
|
|
|
|
|
|
|
|
|
<span class="overlay"><i class="fa fa-home"></i></span>
|
|
|
</a>
|
|
|
</div>
|
|
|
<div class="titles">
|
|
|
<h3 class="title"><a href="/">My cool new Blog</a></h3>
|
|
|
|
|
|
<span class="subtitle">Hello World! This is the most epic subtitle ever.</span>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="languages">
|
|
|
|
|
|
|
|
|
<a href="/en" class="active">en</a>
|
|
|
|
|
|
|
|
|
|
|
|
<a href="/de">de</a>
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="toggler">
|
|
|
|
|
|
<i class="fa fa-bars" aria-hidden="true"></i>
|
|
|
</div>
|
|
|
</div>
|
|
|
</header>
|
|
|
|
|
|
|
|
|
<div class="main container">
|
|
|
|
|
|
|
|
|
<div class="article-wrapper u-cf single">
|
|
|
|
|
|
<a class="bubble" href="/article/e7-ad-86-e8-a8-98-centos-6-6-iredmail-0-9-4-e5-ae-89-e8-a3-9d-e7-ad-86-e8-a8-98/">
|
|
|
<i class="fa fa-fw fa-pencil"></i>
|
|
|
</a>
|
|
|
|
|
|
<article class="default article">
|
|
|
|
|
|
|
|
|
<div class="content">
|
|
|
<h3><a href="/article/e7-ad-86-e8-a8-98-centos-6-6-iredmail-0-9-4-e5-ae-89-e8-a3-9d-e7-ad-86-e8-a8-98/">[筆記] CentOS 6.6 + iRedmail 0.9.4 + postfixadmin 安裝筆記</a></h3>
|
|
|
<div class="meta">
|
|
|
|
|
|
|
|
|
<span class="date moment">2016-01-27</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<span class="categories">
|
|
|
|
|
|
<a href="/categories/%E6%9C%AA%E5%88%86%E9%A1%9E">未分類</a>
|
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<p><font size="4">系統基礎設定</font></p>
|
|
|
|
|
|
<p><font size="4">Clone from a fresh new install CentOS 6.6 in vmware </font></p>
|
|
|
|
|
|
<p><font size="4">power on</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">新增DNS 伺服器</font></p>
|
|
|
|
|
|
<p><font size="4">vi /etc/resolv.conf</font></p>
|
|
|
|
|
|
<p><font size="4">刪除內容 新增以下資料 </font></p>
|
|
|
|
|
|
<p><font size="4">nameserver 168.95.1.1</font></p>
|
|
|
|
|
|
<p><font size="4">nameserver 8.8.8.8</font></p>
|
|
|
|
|
|
<p><font size="4">nameserver 8.8.4.4</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">啟動網路卡</font></p>
|
|
|
|
|
|
<p><font size="4">cp /etc/sysconfig/network-scripts/ifcfg-eth2 /etc/sysconfig/network-scripts/ifcfg-eth3</font></p>
|
|
|
|
|
|
<p><font size="4">vi /etc/sysconfig/network-scripts</font></p>
|
|
|
|
|
|
<p><font size="4">刪除 MAC </font></p>
|
|
|
|
|
|
<p><font size="4">修改底下的設定</font></p>
|
|
|
|
|
|
<p><font size="4">BOOTPROTO=static
|
|
|
IPADDR=192.168.10.220
|
|
|
NETMASK=255.255.255.0</font></p>
|
|
|
|
|
|
<p><font size="4">vi /etc/sysconfig/network</font></p>
|
|
|
|
|
|
<p><font size="4">NETWORKING=yes
|
|
|
HOSTNAME=iredmail
|
|
|
GATEWAY=192.168.10.246
|
|
|
</font></p>
|
|
|
|
|
|
<p><font size="4">service network restart</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">修改時區</font></p>
|
|
|
|
|
|
<p><font size="4">yum install ntpdate –y</font></p>
|
|
|
|
|
|
<p><font size="4">cp /usr/share/zoneinfo/Asia/Taipei /etc/localtime</font></p>
|
|
|
|
|
|
<p><font size="4">ntpdate 192.168.10.243</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">reboot (讓hostname 生效)</font></p>
|
|
|
|
|
|
<p><font size="4">登入</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">安裝基本指定</font></p>
|
|
|
|
|
|
<p><font size="4">yum install –y wget telnet vim ftp epel-release bind-utils</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">下載 iredmail 進行安裝</font></p>
|
|
|
|
|
|
<p><font size="4">wget </font><a href="https://bitbucket.org/zhb/iredmail/downloads/iRedMail-0.9.4.tar.bz2"><font size="4">https://bitbucket.org/zhb/iredmail/downloads/iRedMail-0.9.4.tar.bz2</font></a></p>
|
|
|
|
|
|
<p><font size="4">tar xjf iRedMail-0.9.4.tar.bz2</font></p>
|
|
|
|
|
|
<p><font size="4">cd iRedMail-0.9.4</font></p>
|
|
|
|
|
|
<p><font size="4">bash iRedMail.sh</font>
|
|
|
<font size="4"></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p></font></p>
|
|
|
|
|
|
<p><font size="4">IredMail Install </font></p>
|
|
|
|
|
|
<p><font size="4">1.mailbox directory , just keep it and next</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-15-59.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-15-59_thumb.png" alt="pietty0327_2016-01-27_09-15-59" title="pietty0327_2016-01-27_09-15-59" /></font></a></p>
|
|
|
|
|
|
<p><font size="4">2.choose web server ( apache here , more familiar)</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-07.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-07_thumb.png" alt="pietty0327_2016-01-27_09-16-07" title="pietty0327_2016-01-27_09-16-07" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">3. backend choose , MySQL / OpenLDAP MySQL Here ( but seems some proble with global address book in SOGo)</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-16.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-16_thumb.png" alt="pietty0327_2016-01-27_09-16-16" title="pietty0327_2016-01-27_09-16-16" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">4. your domain</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-31.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-31_thumb.png" alt="pietty0327_2016-01-27_09-16-31" title="pietty0327_2016-01-27_09-16-31" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">5. your password to mail admin </font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-42.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-42_thumb.png" alt="pietty0327_2016-01-27_09-16-42" title="pietty0327_2016-01-27_09-16-42" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">6.WEBMAIL , Choose SOGo</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-53.png"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/pietty0327_2016-01-27_09-16-53_thumb.png" alt="pietty0327_2016-01-27_09-16-53" title="pietty0327_2016-01-27_09-16-53" /></a></p>
|
|
|
|
|
|
<p> </p>
|
|
|
|
|
|
<p><font size="4">離開這個畫面後,會開始進行安裝,並且詢問一些問題都按 y ,完成後,會產生一個 iRedMail.tips 裡面有帳號、密碼等資訊</font></p>
|
|
|
|
|
|
<p><font size="4">接著安裝 phpmyadmin</font></p>
|
|
|
|
|
|
<p><font size="4">yum install –y phpmyadmin</font></p>
|
|
|
|
|
|
<p><font size="4">重開機套用</font></p>
|
|
|
|
|
|
<p><font size="4">reboot</font></p>
|
|
|
|
|
|
<p><font size="4"></font>
|
|
|
<font size="4"></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p></font></p>
|
|
|
|
|
|
<p><font size="4">開啟 </font><a href="https://hostname/iredmailadmin"><font size="4">https://hostname/iredmailadmin</font></a></p>
|
|
|
|
|
|
<p><font size="4">建立三個USER做測試用</font></p>
|
|
|
|
|
|
<p><font size="4">登入 </font><a href="https://hostname/SOGo"><font size="4">https://hostname/SOGo</font></a></p>
|
|
|
|
|
|
<p><font size="4">用其中一個帳號登入,收發信件測試 (前提是 DNS 還有防火牆 已經設定好了)</font></p>
|
|
|
|
|
|
<p><font size="4">檢查通訊錄,發現 Global Address Book (公用通訊錄、全域通訊錄) 居然是空的</font></p>
|
|
|
|
|
|
<p><font size="4">關機,再做一台來測試 OpenLDAP (VM真他X的方便)</font></p>
|
|
|
|
|
|
<p><font size="4">shutdown –h now</font>
|
|
|
<font size="4"></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p></font></p>
|
|
|
|
|
|
<p><font size="4">重複 基礎設定 、下載安裝包、進行安裝,改選openLDAP,一開始要輸入 dc=abc,dc=org , 再來輸入 abc.org 其他都一樣</font></p>
|
|
|
|
|
|
<p><font size="4">安裝完後,多裝一個 phpldapadmin</font></p>
|
|
|
|
|
|
<p><font size="4">yum install phpldapadmin –y</font></p>
|
|
|
|
|
|
<p><font size="4">reboot</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">開啟 </font><a href="https://hostname/iredmailadmin"><font size="4">https://hostname/iredmailadmin</font></a></p>
|
|
|
|
|
|
<p><font size="4">建立三個USER做測試用</font></p>
|
|
|
|
|
|
<p><font size="4">p.s <strike>等了好久(5分鐘左右吧)才看到頁面,不知道是那邊的問題</strike> (update: 應該是firefox的關係,重設後 OK )</font></p>
|
|
|
|
|
|
<p><font size="4"><strike>要檢視憑證也是很久很久..</strike></font></p>
|
|
|
|
|
|
<p><font size="4">登入 </font><a href="https://hostname/SOGo"><font size="4">https://hostname/SOGo</font></a></p>
|
|
|
|
|
|
<p><font size="4">Global Address Book 還是看不到東西</font></p>
|
|
|
|
|
|
<p><font size="4">但是RoundCubeMail 的通訊錄裡面有!!!</font></p>
|
|
|
|
|
|
<p><font size="4">還要再研究看看,或者就不要管SOGo了,反正RoundCubeMail 本來就比較好看又好用!</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/iexplore_2016-01-27_10-41-02.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/iexplore_2016-01-27_10-41-02_thumb.png" alt="iexplore_2016-01-27_10-41-02" title="iexplore_2016-01-27_10-41-02" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">RoundCubeMail的設定檔在 /var/www/roundcubemail/config/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">有關LDAP ADDRESS BOOK的設定如下</font>
|
|
|
> <font size="4">// Global LDAP address book.
|
|
|
> $config[‘ldap_public’][“global_ldap_abook”] = array(
|
|
|
> ‘name’ => ‘Global LDAP Address Book’,
|
|
|
> ‘hosts’ => array(‘127.0.0.1’),
|
|
|
> ‘port’ => 389,
|
|
|
> ‘use_tls’ => false,
|
|
|
> ‘ldap_version’ => ‘3’,
|
|
|
> ‘network_timeout’ => 10,
|
|
|
> ‘user_specific’ => true,</font>
|
|
|
>
|
|
|
> <font size="4"> // Search mail users under same domain.
|
|
|
> ‘base_dn’ => ‘domainName=%d,o=domains,dc=abc,dc=org’,
|
|
|
> ‘bind_dn’ => <a href="mailto:">‘mail=%u@%d,ou=Users,domainName=%d,o=domains,dc=abc,dc=org’</a>,</font>
|
|
|
>
|
|
|
> <font size="4"> ‘hidden’ => false,
|
|
|
> ‘searchonly’ => false,
|
|
|
> ‘writable’ => false,</font>
|
|
|
>
|
|
|
> <font size="4"> ‘search_fields’ => array(‘mail’, ‘cn’, ‘sn’, ‘givenName’, ‘street’, ‘telephoneNumber’, ‘mobile’, ‘stree’, ‘postalCode’),
|
|
|
> </font>
|
|
|
>
|
|
|
> <font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">底下這是欄位對應</font>
|
|
|
> <font size="4">// mapping of contact fields to directory attributes
|
|
|
> ‘fieldmap’ => array(
|
|
|
> ‘name’ => ‘cn’,
|
|
|
> ‘surname’ => ‘sn’,
|
|
|
> ‘firstname’ => ‘givenName’,
|
|
|
> ‘title’ => ‘title’,
|
|
|
> ‘email’ => ‘mail:<em>’,
|
|
|
> ‘phone:work’ => ‘telephoneNumber’,
|
|
|
> ‘phone:mobile’ => ‘mobile’,
|
|
|
> ‘street’ => ‘street’,
|
|
|
> ‘zipcode’ => ‘postalCode’,
|
|
|
> ‘locality’ => ‘l’,
|
|
|
> ‘department’ => ‘departmentNumber’,
|
|
|
> ‘notes’ => ‘description’,
|
|
|
> ‘name’ => ‘cn’,
|
|
|
> ‘surname’ => ‘sn’,
|
|
|
> ‘firstname’ => ‘givenName’,
|
|
|
> ‘title’ => ‘title’,
|
|
|
> ‘email’ => ‘mail:</em>’,
|
|
|
> ‘phone:work’ => ‘telephoneNumber’,
|
|
|
> ‘phone:mobile’ => ‘mobile’,
|
|
|
> ‘phone:workfax’ => ‘facsimileTelephoneNumber’,
|
|
|
> ‘street’ => ‘street’,
|
|
|
> ‘zipcode’ => ‘postalCode’,
|
|
|
> ‘locality’ => ‘l’,
|
|
|
> ‘department’ => ‘departmentNumber’,
|
|
|
> ‘notes’ => ‘description’,
|
|
|
> ‘photo’ => ‘jpegPhoto’,
|
|
|
> ),</font></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4"></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p></font> <p><strong><font size="4">安裝 PostfixAdmin 取代 iRedMail 預載的陽春管理介面</font></strong></p>
|
|
|
|
|
|
<p><font size="4">wget </font><a href="http://nchc.dl.sourceforge.net/project/postfixadmin/postfixadmin/postfixadmin-2.93/postfixadmin-2.93.tar.gz"><font size="4">http://nchc.dl.sourceforge.net/project/postfixadmin/postfixadmin/postfixadmin-2.93/postfixadmin-2.93.tar.gz</font></a></p>
|
|
|
|
|
|
<p><font size="4">tar zxvf postfixadmin-2.93.tar.gz</font></p>
|
|
|
|
|
|
<p><font size="4">mv postfixadmin-2.93 pfa</font></p>
|
|
|
|
|
|
<p><font size="4">mv pfa /var/www/html</font></p>
|
|
|
|
|
|
<p><font size="4">編輯 httpd 設定</font></p>
|
|
|
|
|
|
<p><font size="4">vim /etc/httpd/conf.d/pfa.conf</font></p>
|
|
|
|
|
|
<p><font size="4">要安全性的再自己修改 allow / deny 順序和限制</font>
|
|
|
> <font size="4">Alias /pfa “/var/www/pfa/”
|
|
|
> <Directory “/var/www/pfa/”>
|
|
|
> Order allow,deny
|
|
|
> Allow from all
|
|
|
> Options -Indexes
|
|
|
> </Directory></font></p>
|
|
|
|
|
|
<p><font size="4">新增 PostfixAdmin 資料庫</font></p>
|
|
|
|
|
|
<p><font size="4">mysql –u root –p</font></p>
|
|
|
|
|
|
<p><font size="4">輸入 root 密碼,進入 mysql 介面</font></p>
|
|
|
|
|
|
<p><font size="4">執行以下指令,建立一個資料庫叫postfix ,一個使用者帳號 postfix 密碼 postfixadmin ,並指定讓使用者postfix可以讀寫 postfix 資料庫</font></p>
|
|
|
|
|
|
<p><font size="4"> CREATE DATABASE postfix;
|
|
|
CREATE USER ‘postfix’@‘localhost’ IDENTIFIED BY ‘postfixadmin’;
|
|
|
GRANT ALL PRIVILEGES ON ‘postfix’. * TO </font><a href="mailto:"><font size="4">‘postfix’@‘localhost’</font></a><font size="4">;
|
|
|
</font></p>
|
|
|
|
|
|
<p><font size="4">離開mysql 介面</font></p>
|
|
|
|
|
|
<p><font size="4">編輯 postfixadmin 設定檔</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/pfa/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">修改以下設定</font></p>
|
|
|
|
|
|
<p><font size="4"></font>
|
|
|
> <font size="4">$CONF[‘configured’] = true;</font>
|
|
|
>
|
|
|
> <font size="4">$CONF[‘database_type’] = ‘mysqli’;
|
|
|
> $CONF[‘database_user’] = ‘postfix’;
|
|
|
> $CONF[‘database_password’] = ‘postfixadmin’;
|
|
|
> $CONF[‘database_name’] = ‘postfix’;</font></p>
|
|
|
|
|
|
<p><font size="4">存檔後離開,開啟postfixadmin 安裝頁面</font></p>
|
|
|
|
|
|
<p><a href="http://ip_address/pfa/setup.php"><font size="4">http://ip_address/pfa/setup.php</font></a></p>
|
|
|
|
|
|
<p><font size="4">應該會提示有個目錄要有讀寫權限</font></p>
|
|
|
|
|
|
<p><font size="4">chmod a+rw –R /var/www/pfa/templates_c</font></p>
|
|
|
|
|
|
<p><font size="4">重整安裝頁面</font></p>
|
|
|
|
|
|
<p><font size="4">安裝過程其實很簡單</font></p>
|
|
|
|
|
|
<p><font size="4">注意一下密碼安全性原則,不得小於五個字,至少要有三個英文、兩個數字(我是直接拿掉這段,省得麻煩)</font></p>
|
|
|
|
|
|
<p><font size="4">安裝過程中會要求你設定一組安裝密碼,然後系統會產生一組編碼過後的字串</font></p>
|
|
|
|
|
|
<p><font size="4">將這組字串填入 config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/pfa/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">註解掉第一個 setup_password 變數,然後填入剛剛系統產生的編碼字串</font></p>
|
|
|
|
|
|
<p><font size="4">#$CONF[‘setup_password’] = ‘changeme’;
|
|
|
$CONF[‘setup_password’] = ‘7d4b2b0def324a8dc0:80e26d5c’;</font></p>
|
|
|
|
|
|
<p><font size="4">存檔後離開</font></p>
|
|
|
|
|
|
<p><font size="4">接著在安裝畫面填入你剛剛輸入的密碼「明文」,不是那個字串,而是你剛剛輸入的安裝密碼</font></p>
|
|
|
|
|
|
<p><font size="4">建立一個系統管理者帳號、密碼</font></p>
|
|
|
|
|
|
<p><font size="4">都完成之後,會提示一個連結讓你前往登入,或者自己開啟</font></p>
|
|
|
|
|
|
<p><a href="http://ip_address/pfa/login.php"><font size="4">http://ip_address/pfa/login.php</font></a></p>
|
|
|
|
|
|
<p><font size="4">填入剛剛輸入的管理者帳號(全部,包含 @ 後面的域名) 和密碼,登入管理介面,這邊可以順便改語系,內建有繁體中文( 感動! )</font></p>
|
|
|
|
|
|
<p><font size="4">接著先新建一個網域</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-20-29.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-20-29_thumb.png" alt="firefox_2016-01-28_10-20-29" title="firefox_2016-01-28_10-20-29" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">然後新增幾個使用者進行測試,而且postfixadmin 內建就可以建立別名,不用像 iredmail 一樣,要透過 mysql 、openldap 之類的方式去建立!</font></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-26-18.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-26-18_thumb.png" alt="firefox_2016-01-28_10-26-18" title="firefox_2016-01-28_10-26-18" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">別名的建立畫面</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-27-26.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_10-27-26_thumb.png" alt="firefox_2016-01-28_10-27-26" title="firefox_2016-01-28_10-27-26" /></font></a></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><p><font size="4">Update: 更新歡迎信件無法寄出的錯誤</font></p>
|
|
|
|
|
|
<p><font size="4">經過這樣的修改,postfixadmin 預設有一個發送歡迎信件給新帳號的功能會發生錯誤</font></p>
|
|
|
|
|
|
<p><font size="4">maillog 裡面會出現 Sender address rejected: not logged in; 這樣的狀況</font></p>
|
|
|
|
|
|
<p><font size="4">修改postfixadmin的設定</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/pfa/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">修改 admin_email</font></p>
|
|
|
|
|
|
<p><font size="4">$CONF[‘admin_email’] = </font><a href="mailto:"><font size="4">‘postmaster@iredmail.abc.org’</font></a><font size="4">; //本來是 </font><a href="mailto:postmaster@abc.org"><font size="4">postmaster@abc.org</font></a><font size="4"> , 改成 </font><a href="mailto:postmaster@hostname.abc.org"><font size="4">postmaster@hostname.abc.org</font></a></p>
|
|
|
|
|
|
<p><font size="4">測試寄送歡迎信件,應該OK了</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_15-41-45.png"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_15-41-45_thumb.png" alt="firefox_2016-01-28_15-41-45" title="firefox_2016-01-28_15-41-45" /></a></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4"></font> </p>
|
|
|
|
|
|
<p><font size="4">接著登入之前安裝的 roundcubemail 去收發郵件測試正常,</font></p>
|
|
|
|
|
|
<p><font size="4">不過通訊錄還是抓舊的全域通訊錄,應該還是要透過 phpldapadmin 去修改吧,在想是不是乾脆不要用這個功能,改用現在的方式,去AD抓帳號回來好了。</font></p>
|
|
|
|
|
|
<p><font size="4">再到手機上測試之前建立的Exchange 帳號也是正常收發!</font></p>
|
|
|
|
|
|
<p><font size="4">看起來應該大致可以用了!</font></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p><font size="4">修正RoundCubeMail 的通訊錄</font> <p><font size="4">用人家寫好的plugin 來新增一個公用通訊錄</font></p>
|
|
|
|
|
|
<p><a href="https://github.com/JohnDoh/Roundcube-Plugin-Global-Address-Book" title="https://github.com/JohnDoh/Roundcube-Plugin-Global-Address-Book"><font size="4">https://github.com/JohnDoh/Roundcube-Plugin-Global-Address-Book</font></a></p>
|
|
|
|
|
|
<p><font size="4">下載並解壓縮到 /var/www/roundcubemail/plugins/globaladdressbook</font></p>
|
|
|
|
|
|
<p><font size="4">在config 裡面啟用</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/roundcubemail/config/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">在 plugins 的地方加入 globaladdressbook</font></p>
|
|
|
|
|
|
<p><font size="4">$config[‘plugins’] = array(‘managesieve’, ‘password’,‘globaladdressbook’);</font></p>
|
|
|
|
|
|
<p><font size="4">簡單設定一下</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/roundcubemail/plugins/globaladdressbook/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4">設定通訊錄的讀寫權限</font></p>
|
|
|
|
|
|
<p><font size="4">// 0 - global address book is read only
|
|
|
// 1 - users can add, edit and delete contacts (full permissions)
|
|
|
// 2 - users can add but not edit or delete contacts
|
|
|
// 3 - users can add and edit but not delete contacts
|
|
|
</font></p>
|
|
|
|
|
|
<p><font size="4">$config[‘globaladdressbook_perms’] = 3;</font></p>
|
|
|
|
|
|
<p><font size="4">設定誰是這個通訊錄的擁有者,理論上應該設定給管理公用通訊錄的人</font></p>
|
|
|
|
|
|
<p><font size="4">// global address book admin user
|
|
|
// admin user(s) can always add/edit/delete entries, overrides readonly
|
|
|
// either a single username, an array of usernames, or a regular expression, see README for more info
|
|
|
</font></p>
|
|
|
|
|
|
<p><font size="4">$config[‘globaladdressbook_admin’] = null;</font></p>
|
|
|
|
|
|
<p><font size="4">存檔後離開,在roundcubemail 的通訊錄中,就可以看到多了一個「公用通訊錄」</font></p>
|
|
|
|
|
|
<p><font size="4">每個使用者都可以看到,以目前的設定來說,每個人都可以去編輯,但是不能刪除</font></p>
|
|
|
|
|
|
<p><a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_14-11-09.png"><font size="4"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_14-11-09_thumb.png" alt="firefox_2016-01-28_14-11-09" title="firefox_2016-01-28_14-11-09" /></font></a></p>
|
|
|
|
|
|
<p><font size="4"></p>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<p>設定ROUNDCUBEMAIL去抓AD 的帳號,不過目前搞不定使用者通訊錄排序的問題,群組的排序倒是OK</font> <p><font size="4">//update 使用者通訊錄的排序也搞定啦!</font></p>
|
|
|
|
|
|
<p><font size="4">//底下這行本來被註解掉了,取消註解</font></p>
|
|
|
|
|
|
<p><font size="4">$config[‘addressbook_sort_col’] = ‘name’; </font></p>
|
|
|
|
|
|
<p><font size="4">改一下config</font></p>
|
|
|
|
|
|
<p><font size="4">vim /var/www/roundcubemail/config/config.inc.php</font></p>
|
|
|
|
|
|
<p><font size="4"></font>
|
|
|
> <font size="4">// Global LDAP address book.
|
|
|
> $config[‘ldap_public’][“global_ldap_abook”] = array(
|
|
|
> ‘name’ => ‘Global LDAP Address Book’,
|
|
|
> ‘hosts’ => array(‘192.168.10.243’), //改成AD 的IP
|
|
|
> ‘port’ => 389,
|
|
|
> ‘use_tls’ => false,
|
|
|
> # ‘ldap_version’ => ‘3’, //註解掉這行
|
|
|
> # ‘network_timeout’ => 10, //註解掉這行
|
|
|
> ‘user_specific’ => true,</font>
|
|
|
>
|
|
|
> <font size="4">// Search mail users under same domain.</font>
|
|
|
>
|
|
|
> <font size="4">//修改和AD連線的設定, base_dn , bind_dn , bind_pass 都要設定,如果沒設定DN/pass 會發生驗證錯誤,找不到資料的情況
|
|
|
> ‘base_dn’=> ‘DC=abc,DC=com, DC=tw’,
|
|
|
> ‘bind_dn’ => </font><a href="mailto:"><font size="4">‘abc@abc.com.tw’</font></a><font size="4">,
|
|
|
> ‘bind_pass’ => ‘abcabc’,
|
|
|
> ‘writable’ => false,</font>
|
|
|
>
|
|
|
> <font size="4">//設定USER搜尋通訊錄時,要尋哪些欄位,欄位越多,搜尋時間越久,為了省時間,只設定搜尋兩個欄位</font>
|
|
|
>
|
|
|
> <font size="4">‘search_fields’ => array(‘mail’, ‘cn’),// ‘sn’, ‘givenName’, ‘street’),//, ‘telephoneNumber’, ‘mobile’, ‘stree’, ‘postalCode’),</font>
|
|
|
>
|
|
|
> <font size="4">//<strike>底下這些其實可有可無,大部分的欄位對應都在下面的 fieldmap</strike></font>
|
|
|
>
|
|
|
> <font size="4">//<strike>然後AD的欄位很奇怪,不管怎麼抓,就是很固執,我有測試去抓 description 欄位來當作顯示名稱 (surname) 但就是沒作用…而且似乎會拖慢速度</strike></font>
|
|
|
>
|
|
|
> <font size="4">//<strike>但是在聯絡人的內容卻有出現設定的描述欄位的資料,就很奇怪,不知道怎麼抓
|
|
|
> </strike>#‘name_field’ => ‘cn’, // this field represents the contact’s name
|
|
|
> #‘firstname_field’ => ‘cn’, // this field represents the contact’s first name
|
|
|
> #‘surname_field’ => ‘cn’, // this field represents the contact’s last name
|
|
|
> ‘email_field’ => ‘mail’, // this field represents the contact’s e-mail
|
|
|
> ‘scope’ => ‘sub’, // search mode: sub|base|list //不知道幹嘛的
|
|
|
> ‘filter’ => ‘(&(mail=<em>)(!(msExchHideFromAddressLists=TRUE)))‘, // all mail, except the exchange hidden ,抓取所有 mail 屬性有值的紀錄,除了某些刻意隱藏的
|
|
|
> ‘sort’ => ‘cn’, // The field to sort the listing by. //<strike>排序,不過我測試不出來,改成用 mail 排序也沒作用
|
|
|
> </strike>‘fuzzy_search’ => TRUE ,// server allows wildcard search //預設值</font>
|
|
|
>
|
|
|
> <font size="4">// mapping of contact fields to directory attributes</font>
|
|
|
>
|
|
|
> <font size="4">//這些都是預設值 AD 欄位跟 LDAP 的對應關係,請參考 </font><a href="https://www.manageengine.com/products/ad-manager/help/csv-import-management/active-directory-ldap-attributes.html" title="https://www.manageengine.com/products/ad-manager/help/csv-import-management/active-directory-ldap-attributes.html"><font size="4">https://www.manageengine.com/products/ad-manager/help/csv-import-management/active-directory-ldap-attributes.html</font></a>
|
|
|
>
|
|
|
> <font size="4">//這些都先註解掉
|
|
|
> ‘fieldmap’ => array(
|
|
|
> # ‘name’ => ‘cn’,
|
|
|
> # ‘surname’ => ‘sn’,
|
|
|
> # ‘firstname’ => ‘givenName’,
|
|
|
> # ‘title’ => ‘title’,
|
|
|
> # ‘email’ => ‘mail:</em>’,
|
|
|
> # ‘phone:work’ => ‘telephoneNumber’,
|
|
|
> # ‘phone:mobile’ => ‘mobile’,
|
|
|
> # ‘street’ => ‘street’,
|
|
|
> # ‘zipcode’ => ‘postalCode’,
|
|
|
> # ‘locality’ => ‘l’,
|
|
|
> # ‘department’ => ‘departmentNumber’,
|
|
|
> # ‘notes’ => ‘description’,
|
|
|
> # ‘name’ => ‘cn’,
|
|
|
> # ‘surname’ => ‘sn’,
|
|
|
> # ‘firstname’ => ‘givenName’,
|
|
|
> # ‘title’ => ‘title’,
|
|
|
> # ‘email’ => ‘mail:*‘,
|
|
|
> # ‘phone:work’ => ‘telephoneNumber’,
|
|
|
> # ‘phone:mobile’ => ‘mobile’,
|
|
|
> # ‘phone:workfax’ => ‘facsimileTelephoneNumber’,
|
|
|
> # ‘street’ => ‘street’,
|
|
|
> # ‘zipcode’ => ‘postalCode’,
|
|
|
> # ‘locality’ => ‘l’,
|
|
|
> # ‘department’ => ‘departmentNumber’,
|
|
|
> # ‘notes’ => ‘description’,
|
|
|
> # ‘photo’ => ‘jpegPhoto’,
|
|
|
> ),
|
|
|
> </font>
|
|
|
>
|
|
|
> <font size="4">//fields_map 的內容 改成這樣,留下兩個就夠了,其他有用到再開</font> > <font size="4"><strong>‘fieldmap’ => array(</strong></font>
|
|
|
>
|
|
|
> <font size="4"><strong>‘name’ => ‘displayName’ ,</strong></font>
|
|
|
>
|
|
|
> <font size="4"><strong>‘email’ => ‘mail:*‘,</strong></font>
|
|
|
>
|
|
|
> <font size="4"><strong>),</strong></font> > <font size="4"> ‘sort’ => ‘cn’, //應該是沒作用
|
|
|
> # ‘scope’ => ‘sub’,
|
|
|
> # ‘filter’ => ‘(&(enabledService=mail)(enabledService=deliver)(enabledService=displayedInGlobalAddressBook)(|(objectClass=mailUser)(objectClass=mailList)(objectClass=mailAlias)))‘,
|
|
|
> # ‘fuzzy_search’ => true,
|
|
|
> # ‘vlv’ => false, // Enable Virtual List View to more efficiently fetch paginated data (if server supports it)
|
|
|
> # ‘sizelimit’ => ‘0’, // Enables you to limit the count of entries fetched. Setting this to 0 means no limit.
|
|
|
> # ‘timelimit’ => ‘0’, // Sets the number of seconds how long is spend on the search. Setting this to 0 means no limit.
|
|
|
> # ‘referrals’ => false, // Sets the LDAP_OPT_REFERRALS option. Mostly used in multi-domain Active Directory setups</font>
|
|
|
>
|
|
|
> <font size="4">//底下這是群組的設定</font>
|
|
|
>
|
|
|
> <font size="4">‘group_filters’ => array(
|
|
|
> ‘departments’ => array(
|
|
|
> ‘name’ => ‘群組’,
|
|
|
> ‘scope’ => ‘sub’,
|
|
|
> #‘filter’ = > ‘(&(mail=<em>)(objectClass=group))‘,
|
|
|
> ‘filter’ => ‘(&(mail=</em>)(objectClass=group)(!(msExchHideFromAddressLists=TRUE)))‘,
|
|
|
> ‘name_attr’ => ‘description’,
|
|
|
> ‘email’ => ‘mail’,
|
|
|
> ),
|
|
|
> ),</font>
|
|
|
>
|
|
|
> <font size="4">);
|
|
|
> $config[‘autocomplete_addressbooks’] = array(‘sql’, ‘global_ldap_abook’);
|
|
|
> </font>
|
|
|
>
|
|
|
> <font size="4">群組信箱看到的畫面會是這樣</font>
|
|
|
>
|
|
|
> <a href="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_14-53-22.png"><img src="http://wp.cowbay.org/wp-content/uploads/2016/01/firefox_2016-01-28_14-53-22_thumb.png" alt="firefox_2016-01-28_14-53-22" title="firefox_2016-01-28_14-53-22" /></a></p>
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<div class="footer">
|
|
|
|
|
|
|
|
|
|
|
|
<div class="tags">
|
|
|
<i class="fa fa-tags"></i>
|
|
|
<div class="links">
|
|
|
|
|
|
<a href="/tags/centos-iredmail-postfix-postfixadmin-virtual-domain">centos iredmail postfix postfixadmin virtual domain</a>
|
|
|
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</article>
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<div id="disqus_thread"></div>
|
|
|
<script type="application/javascript">
|
|
|
var disqus_config = function () {
|
|
|
|
|
|
|
|
|
|
|
|
};
|
|
|
(function() {
|
|
|
if (["localhost", "127.0.0.1"].indexOf(window.location.hostname) != -1) {
|
|
|
document.getElementById('disqus_thread').innerHTML = 'Disqus comments not available by default when the website is previewed locally.';
|
|
|
return;
|
|
|
}
|
|
|
var d = document, s = d.createElement('script'); s.async = true;
|
|
|
s.src = '//' + "bilberry-hugo-theme" + '.disqus.com/embed.js';
|
|
|
s.setAttribute('data-timestamp', +new Date());
|
|
|
(d.head || d.body).appendChild(s);
|
|
|
})();
|
|
|
</script>
|
|
|
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
|
|
|
<a href="https://disqus.com" class="dsq-brlink">comments powered by <span class="logo-disqus">Disqus</span></a>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<footer>
|
|
|
<div class="container">
|
|
|
|
|
|
|
|
|
<div class="recent-posts">
|
|
|
<strong>Latest posts</strong>
|
|
|
<ul>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/google-550-5-7-1-sloution/">寄信給google被退信 錯誤 550-5.7.1的解法</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/netdata-linux-system-performance-monitor-dashboard/">Netdata Linux System Performance Monitor Dashboard</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/linux-performance-monitor-dashboard-netdata-md/">Linux 底下極其詳細的System performace Monitor Dashboard - Netdata</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/syntax-test/">Syntax Test</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/psql-create-role-and-assign-priviledges/">psql create role and assign priviledges</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/study-url/">Study URL</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/article/rsync-time-backup/">[筆記] Linux 底下好用的備份工具 rsync-time-backup</a>
|
|
|
</li>
|
|
|
|
|
|
</ul>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<div class="categories">
|
|
|
<a href="/categories/"><strong>Categories</strong></a>
|
|
|
<ul>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/%E6%9C%AA%E5%88%86%E9%A1%9E">未分類 (86)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/%E5%B7%A5%E4%BD%9C%E7%AD%86%E8%A8%98">工作筆記 (68)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/%E5%85%B6%E4%BB%96">其他 (46)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/%E7%AD%86%E8%A8%98">筆記 (30)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/%E5%89%AA%E5%A0%B1">剪報 (18)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/starting">Starting (5)</a>
|
|
|
</li>
|
|
|
|
|
|
<li>
|
|
|
<a href="/categories/blog">Blog (4)</a>
|
|
|
</li>
|
|
|
|
|
|
</ul>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<div class="right">
|
|
|
|
|
|
<div class="external-profiles">
|
|
|
<strong>Social media</strong>
|
|
|
|
|
|
|
|
|
|
|
|
<a href="https://twitter.com/TheRealLednerb" target="_blank"><i class="fa fa-twitter-adblock-proof"></i></a>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<a href="https://github.com/Lednerb" target="_blank"><i class="fa fa-github"></i></a>
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
<div class="languages">
|
|
|
<strong>Other languages</strong>
|
|
|
|
|
|
|
|
|
<a href="/en" class="active">en</a>
|
|
|
|
|
|
|
|
|
|
|
|
<a href="/de">de</a>
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
</div>
|
|
|
</footer>
|
|
|
|
|
|
|
|
|
<div class="credits">
|
|
|
<div class="container">
|
|
|
<div class="copyright">
|
|
|
<a href="https://github.com/Lednerb" target="_blank">
|
|
|
©
|
|
|
|
|
|
2017
|
|
|
|
|
|
by Lednerb
|
|
|
</a>
|
|
|
|
|
|
</div>
|
|
|
<div class="author">
|
|
|
<a href="https://github.com/Lednerb/bilberry-hugo-theme" target="_blank">Bilberry Hugo Theme</a>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript" src="https://h.cowbay.org/js/externalDependencies.39c47e10e241eae2947b3fe21809c572.js" integrity="md5-OcR+EOJB6uKUez/iGAnFcg=="></script>
|
|
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript" src="https://h.cowbay.org/js/theme.ff50ae6dc1bfc220b23bf69dbb41b54e.js" integrity="md5-/1CubcG/wiCyO/adu0G1Tg=="></script>
|
|
|
|
|
|
<script>
|
|
|
$(".moment").each(function() {
|
|
|
$(this).text(
|
|
|
moment( $(this).text() )
|
|
|
.locale( "en" )
|
|
|
.format('LL')
|
|
|
);
|
|
|
});
|
|
|
|
|
|
$(".footnote-return sup").html("");
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
var client = algoliasearch("Y2C4RWMPXW", "50ea7f8c41c0ad233926e0be2b769ed1");
|
|
|
var index = client.initIndex("default-content");
|
|
|
|
|
|
$('#search').autocomplete({ hint: false, autoselect: true, debug: false },
|
|
|
[
|
|
|
{
|
|
|
|
|
|
source: $.fn.autocomplete.sources.hits(index, { hitsPerPage: 5, filters: 'language: en' }),
|
|
|
|
|
|
displayKey: function(suggestion) {
|
|
|
return suggestion.title || suggestion.author
|
|
|
},
|
|
|
templates: {
|
|
|
suggestion: function(suggestion) {
|
|
|
return "<span class='entry " + suggestion.type + "'>"
|
|
|
+ "<span class='title'>" + suggestion.title + "</span>"
|
|
|
+ "<span class='fa fa-fw " + suggestion.iconClass + "'></span>"
|
|
|
+ "</span>"
|
|
|
;
|
|
|
},
|
|
|
empty: function() {
|
|
|
return "<span class='empty'>Nothing found.</span>"
|
|
|
},
|
|
|
footer: function() {
|
|
|
return '<div class="branding">Powered by <img src="https:\/\/h.cowbay.org\/dist\/algolia-logo-light.svg" /></div>'
|
|
|
}
|
|
|
|
|
|
},
|
|
|
}
|
|
|
])
|
|
|
.on('autocomplete:selected', function(event, suggestion, dataset) {
|
|
|
window.location = (suggestion.url);
|
|
|
})
|
|
|
.keypress(function (event, suggestion) {
|
|
|
if (event.which == 13) {
|
|
|
window.location = (suggestion.url);
|
|
|
}
|
|
|
});
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
</html>
|