[{"data":1,"prerenderedAt":399},["ShallowReactive",2],{"articles-page-2":3},{"articles":4,"total":398},[5,65,122,155,303,331,372],{"path":6,"title":7,"description":8,"image":9,"createdAt":10,"authorKey":11,"tags":12,"codeLinks":17,"readingTime":21,"excerpt":22},"\u002Farticles\u002F20210826-email-autoconf","Automated Mail Client Configuration with email-autoconf","Automated mail client configuration using email-autoconf as automx2 replacement.","\u002Fimages\u002Fcovers\u002Femail-autoconf.jpg","2021-08-26","philip",[13,14,15,16],"sysadmin","linux","email","python",[18],{"link":19,"desc":20},"https:\u002F\u002Fgitlab.com\u002Fonlime\u002Femail-autoconf\u002F","onlime\u002Femail-autoconf",9,{"type":23,"value":24},"minimark",[25,29,41],[26,27,28],"p",{},"How nice would it be, if every email client could be auto-configured and the user would just need to enter his credentials? Entering his email address plus password, hit enter, done. How come nowadays people still need to care about incoming IMAP and outgoing SMTP servers, encryption (SSL\u002FTLS vs. STARTTLS protocols), ports (for a regular end user this is just a number without any meaning, right?), and maybe even wondering what was the username if that differs from the actual email address?",[26,30,31,32,36,37,40],{},"You may tell me: ",[33,34,35],"em",{},"Hey, we're in 2021, email is so old-school!"," Or you may tell me: ",[33,38,39],{},"Oh, don't you know there is a thing called auto-configuration?"," – Unfortunately, both statements are wrong. Email today is still widely used for serious communication (and yes, you're right, it should have been replaced long time ago by something better! But it didn't.), and there is such a thing called auto-configuration, but there is just no real standardized protocol that works for every mail client out there. There was no real development in that field during the last 10+ years, sadly.",[26,42,43,44,51,52,57,58],{},"So, let me present that small Python project ",[45,46,50],"a",{"href":47,"rel":48},"https:\u002F\u002Fwww.wittwer-it.ch\u002F",[49],"nofollow","Martin"," and I have been developing for ",[45,53,56],{"href":54,"rel":55},"https:\u002F\u002Fwww.onlime.ch\u002F",[49],"Onlime GmbH"," back in Feb 2020 and which I have now finally published on GitLab.com: ",[59,60,61],"strong",{},[45,62,20],{"href":63,"rel":64},"https:\u002F\u002Fgitlab.com\u002Fonlime\u002Femail-autoconf",[49],{"path":66,"title":67,"description":68,"image":69,"createdAt":70,"authorKey":11,"tags":71,"codeLinks":76,"readingTime":80,"excerpt":81},"\u002Farticles\u002F20210808-gitlab-cd-rsync-deployment","GitLab CI\u002FCD of a Nuxt.js frontend over SSH\u002Frsync","Simple SSH\u002Frsync based Continuous Deployment of a Nuxt.js static frontend project with GitLab CI\u002FCD.","\u002Fimages\u002Fcovers\u002Fgitlab-ci-cd-test-deploy.png","2021-08-08 12:10",[72,73,14,74,75],"devops","gitlab","vue.js","nuxt.js",[77],{"link":78,"desc":79},"https:\u002F\u002Fgist.github.com\u002Fonlime\u002F410d2f45642b4397bcad669a25db6ba7","Gist",8,{"type":23,"value":82},[83,107],[26,84,85,86,90,91,94,95,100,101,106],{},"Continuous deployment is great and a must for every modern web app. Forget about the times when you had to constantly log into your production server over SSH to run some ",[87,88,89],"code",{},"git pull"," based deployment and cumbersome and error-prone build tasks, or building your project locally and then deploying it with ",[87,92,93],{},"rsync"," to production, which is not that sexy either. It is all doable and scriptable, but we want to have the whole process automated without any manual work involved. I much prefer to use ",[45,96,99],{"href":97,"rel":98},"https:\u002F\u002Fdocs.gitlab.com\u002Fee\u002Fci\u002F",[49],"GitLab CI\u002FCD"," over ",[45,102,105],{"href":103,"rel":104},"https:\u002F\u002Fgithub.com\u002Ffeatures\u002Factions",[49],"GitHub Actions"," - ok, mainly just because I am more into it and prefer to run a self-hosted GitLab instance. GitLab just gets the job done very well!",[26,108,109,110,115,116,121],{},"We want the whole process to be straightforward without any fancy extras. It should be a matter of 15mins to set it up on every new project and I don't like to introduce any extra dependencies. I am just talking about deployment of a static site \u002F SPA, a ",[45,111,114],{"href":112,"rel":113},"https:\u002F\u002Fvuejs.org\u002F",[49],"Vue.js"," based frontend that is generated by ",[45,117,120],{"href":118,"rel":119},"https:\u002F\u002Fnuxtjs.org\u002F",[49],"Nuxt.js",". So let's keep it simple here! I am going to present you the solution I am using to deploy this TechBlog.",{"path":123,"title":124,"description":125,"image":126,"createdAt":127,"authorKey":11,"tags":128,"codeLinks":130,"readingTime":133,"excerpt":134},"\u002Farticles\u002F20210806-zfs-destroy-snapshots","Cleanup helper script to destroy old ZFS snapshots","A small helper script written in Python to destroy legacy ZFS snapshots.","\u002Fimages\u002Fcovers\u002Fopen-zfs-blueprint.jpg","2021-08-06 13:00",[13,14,129,16],"zfs",[131],{"link":132,"desc":79},"https:\u002F\u002Fgist.github.com\u002Fonlime\u002F530c27b71056efd6edd7a38b7369457d",4,{"type":23,"value":135},[136,139],[26,137,138],{},"For years now, I am using this little helper script written in Python, which solves a very basic task: Destroy legacy ZFS snapshots. We all know ZFS snapshots are so lightweight and we tend to create so many snapshots, either manually (e.g. before a major system upgrade) or automated (e.g. by our replication or backup jobs). It can somtimes be cumbersome to destroy legacy ZFS snapshots that are no longer needed.",[26,140,141,142,145,146,149,150,154],{},"So, here comes help with ",[87,143,144],{},"zfs-destroy-snapshots.py"," which you could deploy to ",[87,147,148],{},"\u002Fusr\u002Flocal\u002Fsbin"," to have that handy script ready. I know, this is like a really small snipped I could just post to Github Gist (ok, here you go: ",[45,151,153],{"href":132,"rel":152},[49],"onlime\u002Fzfs-destroy-snapshots.py",") or Pastebin, but I think it still deserves a full blown blog post.",{"path":156,"title":157,"description":158,"image":159,"createdAt":160,"authorKey":11,"tags":161,"codeLinks":165,"readingTime":168,"excerpt":169},"\u002Farticles\u002F20210805-eslint-prettier-for-vscode","Configure ESLint and Prettier for Vue\u002FNuxt.js project in VS Code","Quick and dirty VS Code setup of ESLint and Prettier for your next Vue\u002FNuxt.js project.","\u002Fimages\u002Fcovers\u002Fprettier.jpg","2021-08-05 17:48",[162,74,75,163,164],"frontend","js","vscode",[166],{"link":167,"desc":79},"https:\u002F\u002Fgist.github.com\u002Fonlime\u002F4025b7535550b7a31c75f3ff89f926c5",2,{"type":23,"value":170},[171,200,222,299],[26,172,173,174,179,180,185,186,189,190,193,194,199],{},"I'd like to share my recommended ",[45,175,178],{"href":176,"rel":177},"https:\u002F\u002Feslint.org\u002F",[49],"ESLint"," and ",[45,181,184],{"href":182,"rel":183},"https:\u002F\u002Fprettier.io\u002F",[49],"Prettier"," configuration for a ",[45,187,114],{"href":112,"rel":188},[49]," project built with ",[45,191,120],{"href":118,"rel":192},[49]," (loving it!). As preferred IDE, I am using - guess what? - ",[45,195,198],{"href":196,"rel":197},"https:\u002F\u002Fcode.visualstudio.com\u002F",[49],"VS Code",". This article is just considered as simple dev notes without digging any deeper, and it's based on my current \"best practices\".",[26,201,202,203,179,206,209,210,213,214,217,218,221],{},"Install ",[45,204,178],{"href":176,"rel":205},[49],[45,207,184],{"href":182,"rel":208},[49]," with all recommended plugins into ",[87,211,212],{},"devDependencies"," using ",[87,215,216],{},"yarn"," (you might as well use ",[87,219,220],{},"npm","):",[223,224,229],"pre",{"className":225,"code":226,"language":227,"meta":228,"style":228},"language-bash shiki shiki-themes github-light-default github-light-default github-dark-default","$ yarn add --dev eslint eslint-plugin-nuxt eslint-plugin-vue\n$ yarn add --dev eslint-config-prettier prettier eslint-plugin-prettier\n$ yarn add --dev @nuxtjs\u002Feslint-module @nuxtjs\u002Feslint-config @babel\u002Feslint-parser\n","bash","",[87,230,231,260,279],{"__ignoreMap":228},[232,233,236,240,244,247,251,254,257],"span",{"class":234,"line":235},"line",1,[232,237,239],{"class":238},"sQJ0q","$",[232,241,243],{"class":242},"s-BGO"," yarn",[232,245,246],{"class":242}," add",[232,248,250],{"class":249},"sDkKp"," --dev",[232,252,253],{"class":242}," eslint",[232,255,256],{"class":242}," eslint-plugin-nuxt",[232,258,259],{"class":242}," eslint-plugin-vue\n",[232,261,262,264,266,268,270,273,276],{"class":234,"line":168},[232,263,239],{"class":238},[232,265,243],{"class":242},[232,267,246],{"class":242},[232,269,250],{"class":249},[232,271,272],{"class":242}," eslint-config-prettier",[232,274,275],{"class":242}," prettier",[232,277,278],{"class":242}," eslint-plugin-prettier\n",[232,280,282,284,286,288,290,293,296],{"class":234,"line":281},3,[232,283,239],{"class":238},[232,285,243],{"class":242},[232,287,246],{"class":242},[232,289,250],{"class":249},[232,291,292],{"class":242}," @nuxtjs\u002Feslint-module",[232,294,295],{"class":242}," @nuxtjs\u002Feslint-config",[232,297,298],{"class":242}," @babel\u002Feslint-parser\n",[300,301,302],"style",{},"html pre.shiki code .sQJ0q, html code.shiki .sQJ0q{--shiki-light:#953800;--shiki-default:#953800;--shiki-dark:#FFA657}html pre.shiki code .s-BGO, html code.shiki .s-BGO{--shiki-light:#0A3069;--shiki-default:#0A3069;--shiki-dark:#A5D6FF}html pre.shiki code .sDkKp, html code.shiki .sDkKp{--shiki-light:#0550AE;--shiki-default:#0550AE;--shiki-dark:#79C0FF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .s_bOF, html code.shiki .s_bOF{--shiki-light:#1F2328;--shiki-default:#1F2328;--shiki-dark:#E6EDF3}html pre.shiki code .sfEsd, html code.shiki .sfEsd{--shiki-light:#116329;--shiki-default:#116329;--shiki-dark:#7EE787}html pre.shiki code .s5nWI, html code.shiki .s5nWI{--shiki-light:#CF222E;--shiki-default:#CF222E;--shiki-dark:#FF7B72}html pre.shiki code .s9BHP, html code.shiki .s9BHP{--shiki-light:#6E7781;--shiki-default:#6E7781;--shiki-dark:#8B949E}",{"path":304,"title":305,"description":306,"image":307,"createdAt":308,"authorKey":11,"tags":309,"codeLinks":311,"readingTime":312,"excerpt":313},"\u002Farticles\u002F20210803-ssh-allowed-commands","Restrict commands by SSH authorized_keys command option","Limit SSH access to specific commands by the lovely command option in authorized_keys.","\u002Fimages\u002Fcovers\u002Fssh-key.png","2021-08-03 16:00",[13,14,310],"security",null,5,{"type":23,"value":314},[315,326],[26,316,317,318,321,322,325],{},"SSH ",[87,319,320],{},"authorized_keys"," allows you to define a command which is executed upon authentication with a specific key by prefixing it with the ",[87,323,324],{},"command=\"cmd\""," option.",[26,327,328,330],{},[87,329,320],{}," man page explains this wonderful feature as follows:",{"path":332,"title":333,"description":334,"image":335,"createdAt":336,"authorKey":11,"tags":337,"codeLinks":340,"readingTime":343,"excerpt":344},"\u002Farticles\u002F20210803-secure-zfs-encrypted-extbackup","Secure External Backup with ZFS Native Encryption","How to set up a secure offsite and offline backup server solution based on snapshots and ZFS native encryption.","\u002Fimages\u002Fcovers\u002Fsamsung-ssd-870-qvo-1tb.jpg","2021-08-03 12:00",[13,14,338,339,310,129],"proxmoxve","backup",[341],{"link":342,"desc":79},"https:\u002F\u002Fgist.github.com\u002Fonlime\u002Fb374d988baf1f5ada6a0b1d4ce203b0d",28,{"type":23,"value":345},[346],[26,347,348,349,353,354,356,357,360,361,363,364,367,368,371],{},"Let's improve our ",[45,350,352],{"href":351},"\u002Farticles\u002F20180306-simple-and-secure-external-backup","Simple and Secure External Backup"," solution I have published back in 2018. Back then, I was using ",[87,355,93],{}," over SSH to pull backup data, and ",[87,358,359],{},"LUKS"," encryption as full disk encryption for the external drives. As we all know, transferring data with rsync can get horribly slow and blow up your I\u002FO if you're transferring millions of small files. Also, ",[87,362,359],{}," encryption may be a bit low level and inflexible. What we want to accomplish: A performant and secure backup solution based on ",[59,365,366],{},"ZFS",", using ",[87,369,370],{},"zfs send|recv"," for efficient data transfer, and ZFS native encryption to secure our external drives. So let's go ahead and built that thing from scratch on a fresh 2021 stack!",{"path":373,"title":374,"description":375,"image":376,"createdAt":377,"authorKey":11,"tags":378,"codeLinks":311,"readingTime":168,"excerpt":380},"\u002Farticles\u002F20210728-apfs-encryption-status","APFS Encryption Status","Show APFS encryption status of an external drive on macOS.","\u002Fimages\u002Fcovers\u002Fapfs-apple-file-system.jpg","2021-07-28",[379,310],"macos",{"type":23,"value":381},[382,391],[26,383,384,385,390],{},"macOS offers us a super simple way to fully encrypt an APFS formatted external drive: Right-click on the volume in the Finder and choose the option \"Encrypt\". Carbon Copy Cloner (CCC) also recommends this in its KB article ",[45,386,389],{"href":387,"rel":388},"https:\u002F\u002Fbombich.com\u002Fkb\u002Fccc6\u002Fworking-filevault-encryption",[49],"Enabling encryption on a volume that will not contain an installation of macOS",".",[26,392,393,394,397],{},"But macOS is a bit too transparent on that task. It simply starts encrypting the volume without any feedback or progress bar (WTF?). Even Disk Utility just shows the volume as ",[87,395,396],{},"APFS (Encrypted)"," - as it would have already completed full volume encryption.",29,1794961390517]