硬核編程:30天=一個網站+一份週刊

{"type":"doc","content":[{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"有朋友問:爲什麼又是辦網站又是出週刊的?我說:網站提供了自由發揮的平臺,週刊讓最新的信息得以聚合,做這些都是爲了讓事情變得可持續。","attrs":{}}]},{"type":"horizontalrule","attrs":{}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"30 天,也就是一個月的時間,對於從事多年開發的編程人員來說,我們能在這段期間做哪些有價值的事情呢?在這篇文章裏,我總結了我在過去一段時間裏的建站實踐。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"本人是從事 Web 開發近十年的“老鳥”,對技術和文字情有獨鍾。爲了踐行技術和寫作,也爲了更好地進入互聯網世界,於是我手擼了一個","attrs":{}},{"type":"link","attrs":{"href":"https://www.yulisay.com","title":""},"content":[{"type":"text","text":"個人網站","attrs":{}}]},{"type":"text","text":"。此外,爲了持續地提升個人能力,又出了一份每週發佈的[探知刊物](https://www.yulisay.com/weekly.html)。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"傳送門:☞","attrs":{}},{"type":"link","attrs":{"href":"https://www.yulisay.com","title":""},"content":[{"type":"text","text":"魚立說個人網站","attrs":{}}]},{"type":"text","text":"☜ ≧◠◡◠≦ ☞[探知刊物](https://www.yulisay.com/weekly.html)☜","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"本文將作爲新建網站的第一篇技術稿亮相,也是很長一段時間內進行技術寫作的方向大綱。歡迎欣賞,吐槽不足之處。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":"1. 擼一個網站","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"完全手擼一個網站,是件很辛苦的事情。那麼,我爲什麼選擇要手擼呢?","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"首先,鑑於以前幫人建站的經歷,以及學習流行的建站內容,我摸清楚了個人網站的功能模塊。比如,一個完整的網站應該包括:首頁、文章列表、文章詳情頁、網站標籤、評論等,以及後臺對用戶、權限、文章、標籤、評論等模塊的管理。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"其次,通過學習 Hexo、Hugo 等特色主題和靜態網頁生成思路,瞭解 Typecho、WordPress 等博客搭建技術,我也清楚了建站的技術架構。於是,我採取動靜網頁結合、接口+頁面的方式,同時基於一些成熟的前後端框架進行了開發。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"最後,之所以選擇手擼,更多的是","attrs":{}},{"type":"text","marks":[{"type":"strong","attrs":{}}],"text":"希望通過這次的建站經歷,讓自己對 Web 應用有一個全新而獨立的認知。並且,能夠把控網站的關鍵技術,不對外界產生過多的依賴。","attrs":{}},{"type":"text","text":"就像網站統計,也是 DIY 出來的,完全沒有引進第三方統計工具。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"如上所述,開發整個網站不可能一蹴而就,而是需要前期較長時間的調查和規劃,也需要後期的購買服務器、部署&維護、申請備案等。但是,就網站的核心開發時間,可能也就不到 30 天吧。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"關於搭建網站的技術細節,這裏就先不多說了,因爲後面會整理出專門的文章系列出來,歡迎有識之士前來閱讀和建議。下圖是手擼網站前臺部分的效果圖:","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https://static001.geekbang.org/infoq/0e/0e5727bcfd1df2942a4f5bdcec849595.gif","alt":null,"title":"魚立說個人網站","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"https://www.yulisay.com/","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":"2. 出一份週刊","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"建站是爲了更好地踐行技術和寫作,所以不能讓這個網站靜起來,我便萌生了出一份週刊的想法。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"這份新出的週刊名字定爲“","attrs":{}},{"type":"link","attrs":{"href":"https://www.yulisay.com/weekly.html","title":""},"content":[{"type":"text","text":"探知週刊","attrs":{}}]},{"type":"text","text":"”,口號是:“","attrs":{}},{"type":"text","marks":[{"type":"strong","attrs":{}}],"text":"世界之大,精彩紛呈,我們的眼睛不應只關注一處,還應看看技術、科技、經濟、社會、自然、人文等林林總總的方面。","attrs":{}},{"type":"text","text":"”於我而言,它可以輔助 Web 或隨筆等主題的學習和寫作;於大家而言,也希望通過這些最新的素材,對你有所啓發、欣賞與提升。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"探知週刊的內容主要來源於","attrs":{}},{"type":"link","attrs":{"href":"https://www.yulisay.com/weekly/news","title":""},"content":[{"type":"text","text":"探知推薦","attrs":{}}]},{"type":"text","text":",推薦的信息是從幾千數據源中精選出來的,每次的信息更新時間不超過 1 小時。該推薦支持 PC 端和移動端實時翻看,其效果如下圖:","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https://static001.geekbang.org/infoq/e0/e0b35a12f42947274f5877d5ea15d493.jpeg","alt":null,"title":"探知推薦,左側爲PC版,右側爲移動版","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"https://www.yulisay.com/weekly/news","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"探知週刊會在每週一進行發佈,推薦的主要依據是訪客在“探知推薦”中的點贊推薦數。除了在網站發佈外,還將在微信公衆號(於立爲文)與 GitHub 保持同步更新,大家可以進行長期關注哦。發佈的週刊效果如圖:","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"image","attrs":{"src":"https://static001.geekbang.org/infoq/ed/ed7f48071b795322ec519977db136741.jpeg","alt":null,"title":"探知週刊","style":[{"key":"width","value":"75%"},{"key":"bordertype","value":"none"}],"href":"https://www.yulisay.com/weekly.html","fromPaste":false,"pastePass":false}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"此外,也羅列了一些供你繼續探知的網站列表,比如今日熱榜、推酷、開發者頭條、InfoQ 等。如果你有新發現的話,也歡迎推薦給本站。或者,看到有價值的資訊,也可以補充到探知推薦列表中。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"heading","attrs":{"align":null,"level":2},"content":[{"type":"text","text":"3. 更多的實踐","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"一個完整的網站除了前臺系統外,也離不開後臺管理系統,有時候還需要數據分析系統、監控系統、延伸系統等。比如,我使用了基於 Prometheus + Grafana 的監控系統,目的是實現對 LNMPR 服務的監控。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"關於這部分也先不說了,如果感興趣歡迎繼續關注。需要說明的是,網站的內容均屬免費,但是受限於不多的帶寬,有些內容可能需要註冊才能閱讀,請多多諒解。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"最後,引用一下我的 ","attrs":{}},{"type":"link","attrs":{"href":"https://www.yulisay.com/","title":""},"content":[{"type":"text","text":"魚立說","attrs":{}}]},{"type":"text","text":" 口號語爲網站打個氣:“","attrs":{}},{"type":"text","marks":[{"type":"strong","attrs":{}}],"text":"書與代碼,技與藝術,讓人生有所不同!","attrs":{}},{"type":"text","text":"”歡迎大家的訪問,多提意見,不勝感激~","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"horizontalrule","attrs":{}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null},"content":[{"type":"text","text":"本文來源:魚立說。本文鏈接:https://www.yulisay.com/d/30day.html,支持微信瀏覽器打開。","attrs":{}}]},{"type":"paragraph","attrs":{"indent":0,"number":0,"align":null,"origin":null}}]}
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章