Filter Salt Stack Return Data Output

Sometimes you only want to see what has changed, and that is OK. Create a file like this: filter.py #!/usr/bin/python from json import loads from json import dumps import fileinput stdin_lines = [line for line in fileinput.input()] ret = loads(”.join(stdin_lines)) for minion_id, data in ret.items(): print(minion_id) print(‘=’*len(minion_id)) for key, value in ret[minion_id].items(): if value['changes'] or […]

Configuration Management and the Golden Image

When operations first became a thing, system administrators stood up servers using a base image from their favourite distribution. Things were done manually. Some administrators created their own distros, some wrote customised shell scripts to be run once-and-only-once to provision software and settings. This method worked, but it was slow, manual, and the human element […]

Automatic Backups

I maintain many scripts and applications for creating automatic backups or various systems. This page will act as a hub to each of those solutions. tar-back tar-back is a backup utility to tar and gzip target filesystems. It supports a custom retention, filter exclusions, and backup directory. virt-back virt-back virt-back is a python application that […]

tar-back

tar-back is a backup utility to tar and gzip target filesystems. It supports a custom retention, filter exclusions, and backup directory. I use tar-back in combination with cron to perform regular backups of all localhost filesystems into /archive/fs. I then have a central long term storage server that collects the /archive partition from every host. […]

mysql-back

mysql-backis a backup utility script to dump (backup) and gzip every MySQL database on a host. I use mysql-back in combination with cron to perform regular database dumps of MySQL servers to the /archive/db partition on localhost. I then have a central long term storage server that collects the /archive partition from every host. mysql-back: […]