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 | |
| # Create a CA Key & Cert | |
| openssl genrsa -out ca.key 4096 | |
| openssl req -x509 -new -key ca.key -out ca.crt -days 730 -subj /CN="MyFirstCA" | |
| # Create a server Key & CSR | |
| openssl genrsa -out server.key 4096 | |
| openssl req -new -out server.csr -key server.key -config openssl.cnf | 
  
    
      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
    
  
  
    
  | if [[ ${disk_ephemeral} -eq 1 ]]; then | |
| echo "START: Mount the ephemeral disk" | |
| sudo mkfs.ext4 /dev/nvme0n1 | |
| sudo mount -t ext4 /dev/nvme0n1 /opt | |
| echo '/dev/nvme0n1 /opt auto noatime 0 0' | sudo tee -a /etc/fstab | |
| sudo mount -a | |
| sudo chmod -R 777 /opt | |
| echo "DONE: Mount the ephemeral disk" | 
  
    
      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
    
  
  
    
  | // go run main.go | |
| // curl -XPOST "localhost:9999/person?name=ryan&age=88" | |
| // curl -XGET "localhost:9999/person?name=ryan" | |
| // Philosophy: Write the least amount of code to get to the DB which includes | |
| // internal/external packages | |
| package main | |
| import ( | 
  
    
      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 | |
| arr=() | |
| arr[0]="[AU] $(TZ=Australia/Melbourne date +'%I:%M %p')" | |
| arr[1]="[LA] $(TZ=America/Los_Angeles date +'%I:%M %p')" | |
| arr[2]="[TX] $(TZ=US/Central date +'%I:%M %p')" | |
| arr[3]="[NY] $(TZ=America/New_York date +'%I:%M %p')" | |
| rand=$[$RANDOM % ${#arr[@]}] | |
| echo "${arr[$rand]} | size=12" | 
  
    
      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 | |
| help() { | |
| echo "Usage: | |
| ryan container CONTAINER_NAME # Get container ID | |
| " 1>&2 | |
| exit 1 | 
  
    
      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 gc --aggressive --prune=now | |
| git reflog expire --all --expire=now | 
  
    
      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
    
  
  
    
  | schema: | |
| - name: project-name | |
| path: . | |
| commands: | |
| install: | |
| status: true | |
| method: go build -o ./project-name | |
| run: | |
| status: true | |
| method: ./project-name | 
  
    
      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 [[ ! -d "busybox" ]]; then | |
| curl -o busybox.tar.xz -L https://github.com/docker-library/busybox/blob/82bc0333a9ae148fbb4246bcbff1487b3fc0c510/uclibc/busybox.tar.xz?raw=true | |
| mkdir busybox | |
| tar -zxvf busybox.tar.xz -C busybox | |
| rm busybox.tar.xz | |
| fi | |
| docker run -it --rm --entrypoint sh -v $(pwd)/busybox/bin:/bin hello-world | 
  
    
      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 | |
| eval $(assume-role dev-account) | |
| aws eks update-kubeconfig --region us-east-1 --name dev-eks | 
  
    
      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 | |
| export AWS_PROFILE=personal | |
| $(aws ecr get-login --region us-east-1 --no-include-email) |