Tag: ansible

  1. Using Ansible to restart a bunch of services running under systemd in --user mode.

    05 December 2019

    Let's say that you have a bunch of servers that you admin en masse using Ansible.  You have all of them listed and organized in your /etc/ansible/hosts file.  Let's say that each server is running a system service (like my Systembot) running under systemd in --user mode.  (Yes, I'm going to use my exocortex-halo/ repository for this, because I just worked out a good way to keep everything up to date and want to share the technique for everyone new to Ansible.  Pay it forward, you know?)  You want to use Ansible to update your copy of Systembot …

    Read more...

  2. Ansible: Reboot the server and pick up where it left off.

    03 December 2018

    Here's the situation: You're using Ansible to configure a machine on your network, like a new Raspberry Pi.  Ansible has done a bunch of things to the machine and needs to reboot it - for example, when you grow a Raspbian disk image so that it takes up the entire device, it has to be rebooted to notice the change.  The question is, how do you reboot the machine, have Ansible pick up where it left off, and do it in one playbook only (instead of two or more)?

    I spent the last couple of days searching for specifics and found …

    Read more...

  3. Administering servers over Tor using Ansible.

    08 December 2017

    Difficulty rating: 8.  Highly specific use case, highly specific setup, assumes that you know what these tools are already.

    Let's assume that you have a couple of servers that you can SSH into over Tor as hidden services.

    Let's assume that your management workstation has SSH, the Tor Browser Bundle and Ansible installed.  Ansible does all over its work over an SSH connection, so there's no agent to install on any of your servers.

    Let's assume that you only use SSH public key authentication to log into those servers.  Password authentication is disabled with the directive PasswordAuthentication no in the …

    Read more...