9 ms·
Host Your Own Blog with Gitlab and Netlify
- rahimnathwani 7y agoThis is a nice write-up, and it's great that it includes instructions for things like creating a GitLab account, which may be unfamiliar for non-developers. But if you're going to maintain a blog as a set of markdown files, it'a worth considering using Netlify CMS (a web-based CMS for managing markdown files in a git repo). This is especially the case if you don't use a command line or git often, e.g. if you're not a developer or sysadmin. A good starter repo for a blog based on Gatsby, git and Netlify CMS: https://github.com/alxshelepenok/gatsby-starter-lumen https://github.com/alxshelepenok/gatsby-starter-lumen I used the above for my blog, with only minor changes: https://www.encona.com/ https://www.encona.com/
- jfaat 7y agoSo if you’re not a developer and familiar with git you suggest for people to use the ridiculously complex, react-based gatsy, and still use git too?
- gexla 7y agoI have never used Gatsby, but another in the space is Hugo. If you want a blog then you can choose from one of the many different templates. In terms of PITA, this isn't far off from a self-hosted Wordpress option. Netlify even gives you the option to drag and drop your entire site rather than using a tool such as Git. Yes, Hugo and all these other tools can get to be a massive headache, but you can get a blog going really easy.
- rahimnathwani 7y agoNot exactly. I suggest using Netlify CMS, which uses git under the hood, and means git is invisible to you. One way to set something like this up is to use the gatsby template I linked, which can be used without knowing what React, GraphQL (or even Gatsby) are.
- chiefalchemist 7y agoOh. Thx. That's a nice find. I started to play with Gatsby a couple of weeks ago. I want to do / maintain my CV via markdown and a straightforward static site.
- giglamesh 7y agoI'm using Hugo for a neighborhood non-profit and really stuck on the non-developer front end. I looked into the Netlify CMS but it allows only one (or a few?) accounts to access a site under the free plan. The non-profit has no budget for kind of thing.
- rahimnathwani 7y agoNetlify CMS is released under the MIT Licence. But if you're using Netlify for hosting, you'll need the 'Netlify Identity' service to allow your users to log in. The free tier has a limit of 5 users (or 1000 if you allow open sign-ups). Does your neighbourhood non-profit have more than 5 non-developers who need that front-end to add/edit pages?
- lixtra 7y agoWhy would you do this? Who else does it? And how is it superior to just signing up with a hosted Wordpress (like 30% of the Internet)? EDIT: Feel free to downvote but please answer. TFA does not answer it.
- skilled 7y agoA lot of people do it. Performance and minimal maintenance are among the reasons. WordPress is good, but some see it as overkill.
- indigodaddy 7y agoYou'd be very surprised just how many people are doing this (sort of thing). A ton. Netlify itself is a revelation.
- dictum 7y agoPlease avoid "why would you do X?" when discussing some tool or workflow. It's needlessly confrontational (and through that, restrictive of diversity, as different groups can have different needs and preferences), devoid of information (it doesn't explain the converse, why you shouldn't do X), and lacking in imagination (establishes tradition as a hard principle, and not just a guideline that can be broken depending on the context). It's good to want to know why some people want to do X, but try to ask it in a way that doesn't make a negative assumption about the people taking a certain approach.
- vortexman100 7y agoThe way you wrote this is amazing. I am creating a database of great comments like this just for you.
- dvtrn 7y agotry to ask it in a way that doesn't make a negative assumption about the people taking a certain approach. I feel like there is a LOT in this comment that is reading much more into a question that very likely are not even there, to take the position of scolding someone just because their inquiry was delivered in brevity.
- skinnyarms 7y agoI've hosted several small apps with Netlify, and I recently setup my first blog/brochure type site using Netlify CMS. It's awkward, but it's amazing to me what you can accomplish with a (free) build server, a couple small 3p services, and a CDN with so little effort. Great dev experience, great user experience.
- omerh 7y agoI did almost exactly the same yesterday. https://blog.omerh.me/post/2019/05/17/first_post/ https://blog.omerh.me/post/2019/05/17/first_post/
- OrgNet 7y agoThat is pretty cheap ($10/year with own domain), but I pay $12/year for a full-blown VPS and it is pretty stable (would not use it if my life depended on it though but it is more stable then my Comcast Internet service)... found it here: https://www.lowendstock.com/ https://www.lowendstock.com/
- detaro 7y agoThat $12 VPS includes a domain? Because that's the only paid thing in the blog post.
- OrgNet 7y agoI thought that this $10/year was for using a domain that you already owned... yes I did need to pay another $10 for a domain.
- mosselman 7y agoHow legit is this? Seems too good to be true and more like a scam. Any experience anyone?
- indigodaddy 7y agoIt's legit. Not a scam. I have no idea how Netlify can offer so much in their free tier, but they do. They are likely to get bought out by a Cloudflare, etc, at some point, so time will tell if the free tier will remain so feature-full.
- revvx 7y agoThe parent asked about Low End Stock, not about Netlify
- indigodaddy 7y agoOh you were referring to lowendstock.com. Yeah, you'll need to be careful when considering low-end price VPS providers in general. Some can certainly be fly-by-night. You can find reviews and discussion at lowendtalk.com and lowendbox.com. Here's some that are for sure legit and been around for a long time though (does not imply necessarily that providers not listed are not legit though): Ramnode BuyVM Securedragon Lowendspirit I personally use BuyVM and Netcup.eu.
- pierreprinetti 7y agoI am loving Netlify! However: > The site will have free TLS and IPv6 Unfortunately, the DNS provider (dns1) does not expose DNS over IPv6. Therefore your site is exposed over IPv6 by Netlify, but it will not be reachable by a (probably non-existant) IPv6-only client. Try: dig AAAA dns1.p04.nsone.net
- cimnine 7y agoYes. And no. It depends on the resolver. If the resolver is IPv6-only as well, then yes. But thanks for pointing this out!
- indigodaddy 7y agoThis not correct. The auth DNS resolves ipv6 records for that domain: bash-4.4$ dig @dns1.p04.nsone.net AAAA brainfood.xyz +short 2604:a880:400:d1::8b0:4001
- cimnine 7y agoThe thing is that `dig AAAA dns1.p04.nsone.net` does not resolve anything. A pure-ipv6 network would not be able to resolve my domain, as there is no way to contact dns1.p04.nsone.net via IPv6.
- indigodaddy 7y agoAh, ok I get now.
- ilaksh 7y agoIt's not using a blog hosting service but it's also not really hosting your own since Netlify is actually hosting it.
- jjeaff 7y agoI think even using WordPress.com would be considered "hosting your own" in this context. I think most of the time, "host your own" means you can do more or less whatever you want with your site. Rather than putting your content somewhere like medium or Facebook or Instagram where you are in a closed and controlled system.
- leverage_55 7y agoI just did this for my product website. It’s been wonderful using netlify and Hugo with the universal theme. https://homemadegrow.com https://homemadegrow.com
- phillc73 7y agoAlso did something similar two weeks ago.[1] It's a big work in progress! I'm using Rstudio's Distill framework[2], writing RMarkdown, hosting on Gitlab and publishing on Netlify. Netlify is dead simple to setup, even the domain name and DNS re-direction. I'm also using one of their contact forms. [1] https://goodinplaces.net/ https://goodinplaces.net/ [2] https://rstudio.github.io/distill/ https://rstudio.github.io/distill/
- tchaffee 7y agoHas anyone done something similar with GatsbyJS by any chance?
- indigodaddy 7y agoBrowse down to rahimnathwani's comment
- wildmindwriting 7y agoYou know, I've been using the Bitbucket & Netlify ecosystem for my Wild Mind[1] website for a little over a year. I moved from a self-install of WordPress on Digital Ocean to the Victor Hugo[2] boilerplate and then used my own theme. It's been an absolute joy to build with and I've actually been excited to continue to write because the friction to doing so is largely gone. Really can't recommend Netlify or Hugo enough. [1]: https://www.wildmind.io https://www.wildmind.io [2]: https://github.com/netlify-templates/victor-hugo https://github.com/netlify-templates/victor-hugo Edit: formatting
- theNJR 7y agoI’ve been self hosting word press for my blog since 2006. What made you switch? And why do you like it better?
- wildmindwriting 7y agoI switched because I've done a lot of WordPress development over the years and I wanted to learn something else. Liking it better is because it's a far simpler set-up for me: no database, write in the terminal, don't have to worry about comments or malicious log-in attempts. WordPress is great, don't get me wrong, but using the same platform became boring for me.
- indigodaddy 7y agoYour site is very easy to look at. Well done. I read your "about me" and like your writing style as well. And agree, Netlify is pure gold.
- wildmindwriting 7y agoWhat a lovely comment to read. Thank you! Netlify has taken the pain of maintaining a server away.
- tomcam 7y agoThat’s one of the best-designed websites I’ve ever seen. Good writing too. But wow, Medium should just hire you to do a redesign.
- meeby 7y agoWe use Django + Distill on Netlify for static output from Django projects. Netlify is awesome. Example: https://github.com/mgrp/django-distill-example https://github.com/mgrp/django-distill-example
- als0 7y agoI'm interested to know what the advantage of using Netlify is over simply using Github Pages.
- anater 7y agoidk if GH pages has added this, but Netlify lets you determine your build command and environment for deployments. You can also have different deployments per branch with easy rollback functionality. In short, its built for this exact problem where GH pages is a tacked on feature for repos.
- davidivadavid 7y agoYou need "different deployments per branch with easy rollback functionality" to run a blog with a couple markdown files? Talk about over-engineering.
- anater 7y agoThere’s utility for different deployments per branch and rollbacks when you’re connected to a headless CMS (Contentful, Wordpress API) and managing more complex statically-generated web sites.
- aw3c2 7y agoGitLab
- deftturtle 7y agoYou can receive form submissions, which is very nice for some websites. You can also bundle assets and minify CSS, JS, etc. You can set header rules and cache settings. All of this is not possible with Github as far as I know.
- greenyouse 7y agoI guess this is might be easier to set up but you could get something similar on AWS by posting to an S3 bucket and putting pages into CloudFront CDN. Adding CodeCommit could automate deployment for $1/month or you could write a script to publish new pages for free.
- Xylakant 7y agoYou’ve just reinvented netlify without the polish. But the polish is what makes it great. I’ve moved a few websites off S3 to netlify and the level of integration they offer is great. DNS, TLS certs via let’s encrypt, preview builds for PRs, ..., that’s exactly what I’m willing to pay for. And I know that if they make a business move I don’t like, I can always move off again. No lock-in except the polish.
- neon_me 7y agoWhy u dont use just regular Gitlab Pages without Netlify?
- noja 7y agoAnyone know?
- gcells 7y agoWell Netlify does give you an option to add custom headers, redirects etc. Add CDN and cache busting along with branch deploys, that's something you cannot do with gitlab pages or github pages. Also github pages takes a long time to get live for the first time (at least it did for me).
- neon_me 7y agoAfaik you can specify custom headers in Cloudflare - same as CDN/Cache support and you can definitely use custom branches for release and dev in gitlab - all you have to do is specify them in config.yaml ... I have been running a bunch of generated static pages via GH (and now GitLab) and never seen any disadvantage, but don't take me wrong - I am always learning :)
- acd 7y agoWhat does Netlify bring to the table? Gitlab already has CI/CD. https://docs.gitlab.com/ee/ci/ https://docs.gitlab.com/ee/ci/ Deploy a Blog site with Gitlab pages and Cloudflare https://blog.zenggyu.com/en/post/2019-02-08/deploying-a-blogdown-website-with-gitlab-pages/ https://blog.zenggyu.com/en/post/2019-02-08/deploying-a-blog...
- dsumenkovic 7y agoThanks for sharing the links. The GitLab Pages doc [1] and product vision [2] may be an interesting read as well. [1] - https://docs.gitlab.com/ee/user/project/pages/ https://docs.gitlab.com/ee/user/project/pages/ [2] - https://about.gitlab.com/direction/release/pages/ https://about.gitlab.com/direction/release/pages/
- jimmyislive 7y agoI have done the same for https://jimmyislive.dev/ https://jimmyislive.dev/ (using Github and Netlify). All the code for this site is on GitHub (see the About page)
- tarasmatsyk 7y agoHa-ha, good one! I did the same but in 2 hours. Really recommend Netlify + GoHugo. Here is my review of popular static site generators plus hosting: https://medium.com/@tarasmatsyk/how-to-kick-off-a-blog-in-2-hours-4bb142922185 https://medium.com/@tarasmatsyk/how-to-kick-off-a-blog-in-2-...
- tkjef 7y agojust started using netlify after making my own tool that did something similar and being a holdout for awhile. it was a smooth experience and i am now a happy user. put up a mortgage calculator app: https://www.mortgagecalculator.io/ https://www.mortgagecalculator.io/
- mothsonasloth 7y agoIts cool but I think hosting and configuring your own site/blog can be a rewarding experience. Only last week I had to figure out why a file called btmp in /var/log was so huge. Then I discovered fail2ban
- jjmiv 7y agoi've used netlify for a few years, its great. I use it with github. wanted to use github pages but was tired with having to use submodules in order for it to recognize the docs folder.