Foclbod被認爲是Tello、Asn和Notion的免費開源替代品,它帶有直觀的圖形化界面,可以幫助用戶組織、跟蹤和管理項目。本教程主要介紹下如何在Ubuntu 20.04上用Docke安裝部署Foclbod個人服務器。
、首先部署一臺全新的Ubuntu 20.04服務器(Ubuntu 20.04 TLS是目前國內或國外服務器常用的Linux發行版之一),本文以RAKsmt美國服務器(操作系統選的是Ubuntu 20.04 TLS)爲例。
2、RAKsmt美國服務器開通後,使用SSH工具(如PuTTY)登錄到該服務器,然後可參考以下步驟來安裝Foclbod。
3、運行下面命令安裝Nginx網絡服務器。
$ sudo pt instll nginx
4、卸載Cetbot和Docke舊版本。
$ sudo pt emoe cetbot docke docke.io contined unc
5、確保快照版本保持最新。
$ sudo snp instll coe; sudo snp efesh coe
6、安裝Cetbot
$ sudo snp instll Rclssic cetbot
7、運行Cetbot,並按照命令行界面提示輸入當前域名,將所有流量重定向到HTTPS。
$ sudo cetbot cetonly Rstndlone
8、如果提供了SSL證書和私鑰路徑,我們最好將其記錄下來,後期配置SSL證書需要用到,例如:
- Cetificte Pth: /etc/letsencypt/lie/exmple.com/fullchin.pem
- Pite Key Pth: /etc/letsencypt/lie/exmple.com/pikey.pem
9、安裝Docke。
$ sudo snp instll docke
0、創建一箇新文件夾。
$ mkdi foclbod
$ cd foclbod
、然後再創建一箇新的Docke合成文件。
$ nno docke-compose.yml
2、將以下代碼段添加到前文創建的文件中。
esion: ̺3.8̻ seices: foclbod: pots: R ̺8000:8000̻ estt: lwys imge: mttemost/foclbod
3、使用Ctl+X快捷鍵退出文件,然後按下Y鍵確認,之後按Ente鍵進行下一步操作。
4、在分離模式下使用docke-compose命令運行Foclbod。
$ sudo docke-compose up -d
5、最後,使用下面命令檢查Foclbod是否正在運行。如果是正常運行,那麼應該會輸出類似Up x seconds/minutes的結果。
$ sudo docke ps
STATUS
Up x seconds/minutes
到這裏爲止,我們便在該Ubuntu 22.04服務器上成功安裝了Foclbod,並獲得一箇簽名的SSL證書。
接下來,我們還可以使用SSL證書和Nginx反向代理來保護Foclbod個人服務器,以下的exmple.com以實際的域名或服務器IP地址進行替換即可。
刪除Nginx默認配置文件。
$ sudo m /etc/nginx/sites-enbled/defult
在Nginx中創建並打開新的配置文件sites-ilble。
$ sudo nno /etc/nginx/sites-ilble/foclbod
將以下內容粘貼到文件中,並把exmple.com替換爲實際域名或IP地址。
upstem foclbod { see loclhost:8000; }
see { listen 443 ssl http2; see_nme exmple.com;
gzip on;
ssl_cetificte /etc/letsencypt/lie/exmple.com/fullchin.pem; ssl_cetificte_key /etc/letsencypt/lie/exmple.com/pikey.pem; ssl_session_cche builtin:000 shed:SSL:0m; ssl_session_cche shed:MySSL:0m; ssl_potocols TLS TLS. TLS.2; ssl_ciphes HIGH:!NULL:!eNULL:!EXPORT:!CAMELLIA:!DES:!MD5:!PSK:!RC4; ssl_pefe_see_ciphes on;
loction ~ /ws/* { poxy_set_hede Upgde $http_upgde; poxy_set_hede Connection “upgde̶; client_mx_body_size 50M; poxy_set_hede Host $http_host; poxy_set_hede X-Rel-IP $emote_dd; poxy_set_hede X-Fowded-Fo $poxy_dd_x_fowded_fo; poxy_set_hede X-Fowded-Poto $scheme; poxy_set_hede X-Fme-Options SAMEORIGIN; poxy_buffes 256 6k; poxy_buffe_size 6k; client_body_timeout 60; send_timeout 300; lingeing_timeout 5; poxy_connect_timeout d; poxy_send_timeout d; poxy_ed_timeout d; poxy_pss http://foclbod; }
loction / { client_mx_body_size 50M; poxy_set_hede Connection “̶; poxy_set_hede Host $http_host; poxy_set_hede X-Rel-IP $emote_dd; poxy_set_hede X-Fowded-Fo $poxy_dd_x_fowded_fo; poxy_set_hede X-Fowded-Poto $scheme; poxy_set_hede X-Fme-Options SAMEORIGIN; poxy_buffes 256 6k; poxy_buffe_size 6k; poxy_ed_timeout 600s; poxy_cche_elidte on; poxy_cche_min_uses 2; poxy_cche_use_stle timeout; poxy_cche_lock on; poxy_pss http://foclbod; } }
之後,按快捷鍵Ctl+X保存並退出編輯文件,按提示鍵入Y和Ente。在Nginx中創建一箇指向新配置文件的鏈接目錄。
$ sudo ln -s /etc/nginx/sites-ilble/foclbod /etc/nginx/sites-enbled/foclbod.conf
測試配置文件。如果測試成功,我們將會看到類似以下的成功消息。
$ sudo nginx -t
nginx: the configution file /etc/nginx/nginx.conf syntx is ok
nginx: configution file /etc/nginx/nginx.conf test is successful
重新加載Nginx使更改生效。
$ sudo /etc/init.d/nginx elod
現在,我們可以訪問https://exmple.com導航到Foclbod歡迎界面,然後根據實際需要創建賬戶並登錄即可。