Nuke everything in a namespace following a grep pattern
  
    
      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: "2" | |
| services: | |
| master: | |
| image: eeacms/jenkins-master | |
| ports: | |
| - "80:8080" | |
| environment: | |
| - JAVA_OPTS=-Xmx2048m | |
| volumes: | |
| - jenkins-master:/var/jenkins_home | 
  
    
      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
    
  
  
    
  | # https://superuser.com/questions/790451/how-to-prevent-usb-from-fseventsd-trashes-spotlight-v100-folders-and-ds-st | |
| cd "/Volumes/USB Drive" | |
| touch .metadata_never_index | |
| chmod 444 .metadata_never_index | 
  
    
      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
    
  
  
    
  | import hmac | |
| import hashlib | |
| def equal_hash(event): | |
| secret_value = "secret-value-put-in-github-webhook-ui" | |
| sigExpected = str(event["headers"]["X-Hub-Signature"].replace("sha1=", "")) | |
| sigCalculated = str(hmac.new(secret_value, event["body"], hashlib.sha1).hexdigest()) | |
| return hmac.compare_digest(sigCalculated, sigExpected) | 
  
    
      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 | |
| if ! cmdOut=$(ssm-diff -p /ns init 2>&1) || echo "$cmdOut" | grep -i failed; then | |
| echo "ERROR: Failed pulling from SSM" | |
| exit 1 | |
| fi | 
  
    
      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 | |
| header="col1,col2,col3" | |
| cat << EOF > raw.csv | |
| 4,1,5 | |
| 3,1,4 | |
| 6,8,11 | |
| EOF | 
  
    
      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
    
  
  
    
  | <?xml version="1.0" encoding="UTF-8"?> | |
| <testsuites duration="0.705"> | |
| <testsuite failures="0" name="Suite 1" package="tests/suites/casper/agent" tests="3" time="0.256"> | |
| <testcase classname="tests/suites/casper/agent" name="Default user agent matches /CasperJS/" time="0.103"/> | |
| <testcase classname="tests/suites/casper/agent" name="Default user agent matches /plop/" time="0.146"/> | |
| <testcase classname="tests/suites/casper/agent" name="Default user agent matches /plop/" time="0.007"/> | |
| </testsuite> | |
| <testsuite failures="0" name="Suite 2" package="tests/suites/casper/alert" tests="1" time="0.449"> | |
| <testcase classname="tests/suites/casper/alert" name="alert event has been intercepted" time="0.449"/> | |
| </testsuite> | 
  
    
      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 | |
| git ls-files -z -- . | xargs -0 -n1 -I{} -- git log -1 --format="%at {}" {} | sort | 
  
    
      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 alpine | |
| ARG GITHUB_ACCESS_TOKEN | |
| RUN apk update && \ | |
| apk add -U git && \ | |
| git config --global url."https://${GITHUB_ACCESS_TOKEN}:[email protected]/".insteadOf "https://github.com/" && \ | |
| # Then when you're done doing stuff... clean up | |
| rm -rf ~/.gitconfig | 
  
    
      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 | |
| mkdir /tmp/etc-letsencrypt | |
| docker run -it --rm -v /tmp/etc-letsencrypt:/etc/letsencrypt certbot/certbot certonly --manual --preferred-challenges dns-01 | |
| cp -R /tmp/etc-letsencrypt ~/etc-letsencrypt |