Stan's blog Thanks for stopping by.
Posts with the tag linux:

Setup a network bridge for your LXC containers with lxc-net

After having played around a bit with LXC and discovered its main features, you may want to have a proper network setup for your containers. There are multiple network setups possible and multiple ways to implement them. In this post, we are going to setup a bridge, using lxc-net. It requires very little configuration and should be enough for a simple LXC architecture. More details about this bridge setup: Containers will have an IPv4 within their own subnet Containers will be able to access each other within this subnet The host will be able to access the containers trough this subnet Containers will have access to the internet thanks to the bridge interface Note that I’m using Debian 9 for this tutorial.

Configure the Unbound plugin for Munin

Munin has plugins that allow us to get nice graphs of the DNS queries made to Unbound on the machine. However, they aren’t working by default! This tutorial assumes Munin and Unbound are already configured and working on your server. I’m using Debian 8 and 9, but it should work on Ubuntu, and certainly most distributions. .notice{padding:18px;line-height:24px;margin-bottom:24px;border-radius:4px;color:#444;background:#e7f2fa}.notice p:last-child{margin-bottom:0}.notice-title{margin:-18px -18px 12px;padding:4px 18px;border-radius:4px 4px 0 0;font-weight:700;color:#fff;background:#6ab0de}.notice.warning .notice-title{background:rgba(217,83,79,.9)}.notice.warning{background:#fae2e2}.notice.info .notice-title{background:#f0b37e}.notice.info{background:#fff2db}.notice.note .notice-title{background:#6ab0de}.notice.note{background:#e7f2fA}.notice.tip .notice-title{background:rgba(92,184,92,.8)}.notice.tip{background:#e6f9e6}.icon-notice{display:inline-flex;align-self:center;margin-right:8px}.icon-notice img,.icon-notice svg{height:1em;width:1em;fill:currentColor}.icon-notice img,.

How to set up a diaspora* pod on Debian and Ubuntu

In this tutorial, we will install a diaspora* pod on a Debian/Ubuntu server. I use the official Debian 8 guide as a base, and I used it myself on Debian 9 for dspr.io, but it should work on most recent Debian and Ubuntu versions. Our setup will use Nginx, PostgreSQL and Systemd. Table of content Hardware requirements Installation Dependencies PostgreSQL Creating the diaspora user Ruby installation Install exim4 Download diaspora* Configure diaspora* Install bundle and the gems Setup the database Precompile assets Systemd services Nginx reverse proxy Logrotate Admin stuff Update diaspora* Backup Enjoy!

Add a dynamic MOTD to your Linux server

Setting up a MOTD on your server adds a nice touch that welcomes you warmly every time you connect to it. I used to make my own MOTD in ASCII text, but I’ve been using dynamic-motd by ldidry for a few years. It’s simple Bash and Python scripts that are executed in place of the MOTD. It seems they are only compatible with Debian-based distributions, though. It’s very easy to setup.

Do a speedtest from your terminal with speedtest-cli

Have you ever wanted to make a speedtest from your terminal, and not from these heavy websites stuffed with ads? How about from a headless machine like a server? .notice{padding:18px;line-height:24px;margin-bottom:24px;border-radius:4px;color:#444;background:#e7f2fa}.notice p:last-child{margin-bottom:0}.notice-title{margin:-18px -18px 12px;padding:4px 18px;border-radius:4px 4px 0 0;font-weight:700;color:#fff;background:#6ab0de}.notice.warning .notice-title{background:rgba(217,83,79,.9)}.notice.warning{background:#fae2e2}.notice.info .notice-title{background:#f0b37e}.notice.info{background:#fff2db}.notice.note .notice-title{background:#6ab0de}.notice.note{background:#e7f2fA}.notice.tip .notice-title{background:rgba(92,184,92,.8)}.notice.tip{background:#e6f9e6}.icon-notice{display:inline-flex;align-self:center;margin-right:8px}.icon-notice img,.icon-notice svg{height:1em;width:1em;fill:currentColor}.icon-notice img,.icon-notice.baseline svg{top:0.125em;position:relative} Tip Update: there is now an official and more reliable CLI. Well you can, with speedtest-cli, a open source python script that uses the speedtest.

Micro: a modern and intuitive terminal-based text editor

Text editors are a very personal choice and can lead to endless debates to discuss which one is the best. Across terminal editors, Vim and Nano are certainly the most popular. Vim is complex, but highly customizable and incredibly efficient when you master it, and Nano is easy to approach and use but is way less powerful. And in between, there is now micro: it’s a terminal text editor like the two above, but with the best of both worlds.