This file contains hidden or 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
#!/usr/bin/env groovy | |
import java.util.logging.* | |
System.setProperty("java.util.logging.SimpleFormatter.format", '%1$tF %1$tT - [%4$s] - %5$s %n') | |
Logger logger = Logger.getLogger("logger") | |
logger.info ("I am a test info log") | |
logger.warning("I am a test warning log") | |
logger.severe("I am a test error log") |
This file contains hidden or 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
#!/usr/bin/env bash | |
Check-AWSCreds(){ | |
while read -r PROFILE; do | |
printf "%-20s - " "$PROFILE"; | |
aws sts get-session-token --profile "$PROFILE" &> /dev/null && | |
printf "\e[38;5;2mworking\e[0m\n" || | |
printf "\e[38;5;1mbroken\e[0m\n" | |
done < <( | |
grep '\[' ~/.aws/credentials | \ |
This file contains hidden or 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
function Show-Warning { | |
param( | |
[Parameter(Mandatory=$true)][string]$Message, | |
[int]$TimeoutInSeconds = 10 | |
) | |
Add-Type -AssemblyName System.Windows.Forms | |
$global:balloon = New-Object System.Windows.Forms.NotifyIcon | |
$path = (Get-Process -id $pid).Path |
This file contains hidden or 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
#!/usr/bin/env bash | |
AWS_PROFILE='test' | |
UPDATE_POLICY='{ | |
"Statement" : [ | |
{ | |
"Effect" : "Allow", | |
"Action" : "Update:*", | |
"Principal": "*", |
This file contains hidden or 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
#!/usr/bin/env groovy | |
import java.util.logging.Logger | |
class global { | |
static String WEBHOOK = "https://hooks.slack.com/services/not/telling/you" | |
} | |
def call(status, channel) { | |
Logger logger = Logger.getLogger(this.getClass().getName()) |
This file contains hidden or 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
echo sh(returnStdout: true, script: 'env') |
This file contains hidden or 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
FROM ubuntu:18.04 | |
COPY [".", "/tmp"] | |
RUN apt-get update | |
RUN apt-get install -y ffmpeg | |
RUN ffmpeg \ | |
-i /tmp/audio.wav \ | |
-codec:a libmp3lame \ | |
-qscale:a 2 \ |
This file contains hidden or 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
#!/usr/bin/env bash | |
set -e | |
AUTHOR="Robert J." | |
GIT_DIR="$HOME/Git" | |
print(){ | |
var="$1"; | |
size="${#var}"; | |
printf -v sep "%${size}s" "-"; |
This file contains hidden or 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
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Sid": "", | |
"Effect": "Allow", | |
"Action": "sts:AssumeRole", | |
"Resource": "*", | |
"Condition": { | |
"BoolIfExists": { |
This file contains hidden or 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
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Effect": "Allow", | |
"Action": "iam:*", | |
"Resource": [ | |
"arn:aws:iam::*:user/${aws:username}", | |
"arn:aws:iam::*:mfa/${aws:username}" | |
] |