Skip to content

Instantly share code, notes, and snippets.

View alexs77's full-sized avatar

Alexander alexs77

View GitHub Profile
<!DOCTYPE html>
<html>
<body>
<h1>My First Heading</h1>
<p>My first paragraph.</p>
</body>
</html>
@alexs77
alexs77 / google-translate-codes.txt
Created April 25, 2019 09:22
Google Translate Language Codes
af
sq
ar
hy
az
eu
be
bn
bs
bg
[terragrunt] 2019/03/13 15:55:09 Setting working directory to /Users/alex/SysOps/AWS/QA/cloudcraft/ap-south-1/ap-south-1/keypair/.terragrunt-cache/7FJACLBEMlnpJeba-LhQbRwG95E/TrprSvuoV_MVKNhRWamm3LGfqCA
[terragrunt] 2019/03/13 15:55:10 Detected 1 Hooks
[terragrunt] 2019/03/13 15:55:10 Running command: terraform output -json key_pair_name
The output variable requested could not be found in the state
file. If you recently added this to your configuration, be
sure to run `terraform apply`, since the state won't be updated
with new output variables until that command is run.
[terragrunt] 2019/03/13 15:55:13 Detected 1 Hooks
[terragrunt] 2019/03/13 15:55:13 Hit multiple errors:
exit status 1
@alexs77
alexs77 / compress-benchmark.sh
Last active November 1, 2018 13:33
Comparing gzip, bzip2 and xz
#!/bin/bash
time (
# pp-complete.csv from http://prod.publicdata.landregistry.gov.uk.s3-website-eu-west-1.amazonaws.com/pp-complete.csv
f=pp-complete.csv; for p in gzip bzip2 xz; do
[[ $p = gzip ]] && continue
for m in 1 2 3 4 5 6 7 8 9; do
log=$f.log.$m.$p
out=$f.$m.$p
echo $(date "+%Y-%m-%d--%H:%M:%S.%N"): $p $m start | tee -a $log
time $p -$m -c -k $f > $out
@alexs77
alexs77 / qr.sh
Last active March 1, 2024 20:24
Create QR codes for UUIDs and index.htm
#!/usr/local/bin/fish
mkdir -p qr
echo '<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>
QR Codes
</title>
@alexs77
alexs77 / chef-run-error.txt
Created July 6, 2018 08:57
chef-run error on Ubuntu 18.04
alex@alex-MacBookPro:~$ LC_ALL=C chef-run -i ~/.ssh/id_ecdsa localhost log HelloWorld
[✔] Generated local policyfile
[✔] [localhost] Connected.
[✔] [localhost] Chef client version 14.2.0 already installed on target.
[✖] [localhost] The command 'bash -c 'd=$(mktemp -d -p${TMPDIR:-/tmp} chef_XXXXXX); chmod 777 $d; echo $d'' exited with return code '2' on 'localhost'.
CHEFRMT001
The command 'bash -c 'd=$(mktemp -d -p${TMPDIR:-/tmp} chef_XXXXXX); chmod 777 $d; echo $d'' exited with return code '2' on 'localhost'.
@alexs77
alexs77 / vimrc
Created March 2, 2018 15:02
cVimrc
" You can use <Space>, which is interpreted as a
" literal " " character, to enter buffer completion mode
map gb :buffer<Space>
@alexs77
alexs77 / Multi-Value_Options.yaml
Created March 1, 2018 08:16
Rundeck Multiple Multi-Value Options
- description: Testing Multi-Value Options
executionEnabled: true
id: 0ff8c9cc-2115-4864-8296-2649df0f1da2
loglevel: INFO
name: Multi-Value Options
nodeFilterEditable: false
nodefilters:
dispatch:
excludePrecedence: true
keepgoing: false
@alexs77
alexs77 / Debug_Multi-Value_Options.xml
Created February 28, 2018 16:09
Debugging "Multi-Value Options" in Rundeck
<joblist>
<job>
<context>
<options preserveOrder='true'>
<option delimiter=' ' multivalueAllSelected='true' multivalued='true' name='wert' required='true'>
<description>Werte</description>
</option>
</options>
</context>
<description>Debug für Multi-Value Options</description>
@alexs77
alexs77 / E-Mails_entfernen.xml
Last active February 28, 2018 15:20
Rundeck Job for removing E-Mails
<joblist>
<job>
<context>
<options preserveOrder='true'>
<option delimiter=' ' multivalueAllSelected='true' multivalued='true' name='patterns' required='true'>
<description>Pattern aus der `mailq` Zeile.</description>
</option>
</options>
</context>
<description>Lösche E-Mails, deren Mail Queue Zeile auf das angegebene Muster passt.</description>