|
1 | 1 | +++
|
2 | 2 | title="Building a blog"
|
3 |
| -date=2023-05-01 |
| 3 | +date=2023-08-04 |
4 | 4 |
|
5 | 5 | [taxonomies]
|
6 | 6 | categories = ["General"]
|
7 | 7 | tags = ["blog", "zola"]
|
| 8 | + |
| 9 | +[extra] |
| 10 | +comments = true |
8 | 11 | +++
|
9 | 12 |
|
10 |
| -TBD ... |
| 13 | +As tradition requires it, this post will do a tour of how this blog is built but also about the rationale behind the blog itself. |
| 14 | +As a blog owner I cheated because this is in fact not my first post but who cares ? |
| 15 | + |
| 16 | +So without further ado, let's get started ! |
| 17 | + |
| 18 | +# Why ? |
| 19 | +The reason is pretty simple, I always liked to share knowledge with others. |
| 20 | +Mostly via conferences and some articles posted on my previous companies blogs. |
| 21 | + |
| 22 | +But multiple factors made me reduce this activity: |
| 23 | +* I changed job and I don't have the same amount of time to dedicate to this |
| 24 | +* I also became a dad thus I have less time out of work to prepare for such events |
| 25 | + |
| 26 | +So If I have less time, and I still want to share knowledge, what can I do ? |
| 27 | + |
| 28 | +* I am not very active on social media (twitter and mastodon), I am more there to look for knowledge. |
| 29 | + Also, I am not very comfortable with the threads format, and I don't want to be limited by the number of characters. |
| 30 | +* I don't have the competency nor the time to work on video contents. I used to stream on Twitch, and may come back to this in the future, |
| 31 | + but It's too time-consuming for me. |
| 32 | + |
| 33 | +So it leaves me with writing blog posts. Even though a lot is already available on the internet, |
| 34 | +I feel that writing contents for myself can help my future self and maybe others ? |
| 35 | +After 10 years in the IT industry working in multiple domains (consulting, gambling, health startup), |
| 36 | +I want to share tips, I want to share my experience, I want to share my knowledge and this on multiple subjects: technical and organizational ones. |
| 37 | + |
| 38 | +My current company don't really have a company blog (for now) and I want to keep something for me. |
| 39 | +My previous blog posts are still available, but It is a bit sad that I somehow never really had ownership on those. |
| 40 | +So let's change that, and build my own blog ! I already have a lot of content In my mind that I want to share. |
| 41 | + |
| 42 | +# How ? |
| 43 | +I wanted to build something simple, something that I can easily maintain and host. |
| 44 | +That's why I decided to use a static site generator. |
| 45 | + |
| 46 | +## Static site generator |
| 47 | +A static site generator is a tool that takes a bunch of files and generate a static website out of them. |
| 48 | +So nothing too complex on my side, I can just write content and don't have to bother about what's around it. |
| 49 | +I preferably wanted to use a static site generator that uses markdown files, I use markdown a lot in my daily life, and I am very comfortable with it. |
| 50 | +Like this our blog is a stateless website that serve HTML files, like in the good old days. |
| 51 | + |
| 52 | +No JS ! No CSS ! No HTML ! No Database ! Just markdown files ! |
| 53 | + |
| 54 | +### Zola |
| 55 | +Zola is a static site generator, it's comparable with Hugo, Jekyll, Pelican, etc... |
| 56 | +It's based on [CommonMark](https://commonmark.org/) a specification for Markdown. |
| 57 | + |
| 58 | +One of the main reason I chose to use Zola instead of the competition is that it's an OSS project written in Rust, with an active community. |
| 59 | +I am a Rust enthusiast, I've used the language in the past (not during my day jobs) and I really like it. |
| 60 | +Having my site generator written in Rust will allow me to contribute to it if I need to. |
| 61 | + |
| 62 | +To use Zola you only need a static binary, no need to install a runtime like NodeJS or Ruby. |
| 63 | +Also, I am not good in all the design things (👋CSS), and Zola has a lot of themes available for free. |
| 64 | + |
| 65 | +This was enough to convince me. |
| 66 | + |
| 67 | +## Hosting |
| 68 | +One of the first thing that I thought was that I am not sure how much time I will be able to dedicate to this blog. |
| 69 | +My family is my priority and I also maintain an open source project that takes some time. I plan to feed this blog when the occasions arise. |
| 70 | +For now, I don't want to invest money if I am not active enough here, So finding something free was one of the criteria. |
| 71 | + |
| 72 | +### Github pages |
| 73 | +I chose to use [GitHub pages](https://pages.github.com/) to host this blog. |
| 74 | +It is a free hosting solution for static websites, it's very simple to use and has a lot of features. |
| 75 | + |
| 76 | +Why did I choose GitHub pages ? |
| 77 | +* I am already familiar with GitHub and it's ecosystem. That's where my OSS projects are versioned. |
| 78 | +* I also used GitHub actions in the past, and I am very comfortable with them. |
| 79 | +* It's free |
| 80 | + |
| 81 | +# Conclusion |
| 82 | +Now you know almost everything behind the technical choices I made. |
| 83 | +Piping Zola and GitHub pages together is very simple and documented in Zola. |
| 84 | +You can check the source code of this blog [here](https://github.com/ImFlog/Imflog.github.io) |
| 85 | +and the CI/CD pipeline [here](https://github.com/ImFlog/imflog.github.io/blob/main/.github/workflows/build.yml) |
| 86 | + |
| 87 | +Hope you will enjoy reading my future posts, and don't hesitate to comment on them ! |
| 88 | + |
| 89 | +Flo. |
0 commit comments