This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
set -u | |
POSTGRESQLUSER="postgres" | |
POSTGRESQLHOST="localhost" | |
LOCKFILE="/var/run/postgresql_vacuum.lock" | |
RETRIES=3 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
set -u | |
POSTGRESQLUSER="postgres" | |
POSTGRESQLHOST="localhost" | |
BACKUPDIR="/srv/postgresql-backup-datastore" | |
# 25 days (24 * 25 = 600 hours) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
set -u | |
BACKUPDIR="/srv/contents-backup-datastore" | |
# 25 days (24 * 25 = 600 hours) | |
SAVED=600 | |
TARGETS=("/path/to/1st" "/path/to/2nd") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
psql --user=postgres --list --tuples-only --pset="format=unaligned" --pset="fieldsep=," | sed 's!^postgres=CTc/postgres$!!g' | cut --delimiter="," --fields=1 | sed -e 's/^template[01]$//g' -e '/^$/d' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
perl -ane 'printf("%s\n", crypt("opensesame", $F[0]))' salt.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
php -r '$f = file("salt.txt"); foreach($f as $r) echo crypt("opensesame", trim($r)), PHP_EOL;' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ruby -ane 'puts "opensesame".crypt($F[0]);' salt.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <crypt.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
int main(int argc, char *argv[]) | |
{ | |
if (argc < 3) { | |
fprintf(stderr, "%s [string] [salt]\n", argv[0]); | |
exit(1); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
set -u | |
WEBDAV_PATH="/var/www/WebDAV" | |
WEBDAV_URL="https://www.example.com/WebDAV/" | |
HTPASSWD=".htpasswd" | |
PASSWORD_LENGTH=16 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -u | |
INITIAL_GROUP="users" | |
INITIAL_SHELL="/usr/bin/rssh" | |
SSHTYPE="rsa" | |
RSSH_CONFIG="/etc/rssh.conf" | |
RSSH_SKELETON="/var/rssh_skeleton" |
OlderNewer