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 node | |
const readline = require('readline'); | |
const rl = readline.createInterface({input: process.stdin, output: process.stdout}); | |
const prompt = (query) => new Promise((resolve) => rl.question(query, resolve)); | |
//usage inside aync function do not need closure demo only* | |
(async () => { | |
try { |
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
stages: | |
- test | |
- docker-build | |
- version-push | |
- deploy | |
- cleanup | |
variables: | |
# The prefix to add to commit messages that only include upgrades of versions | |
# Due to the limitations of the workflow expressions. You must also update the workflow rules below if you change this |
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 | |
# Colors | |
red='\033[0;31m' | |
no_color='\033[0m' | |
# Inputs | |
gitlab_host=$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 | |
hdiutil attach /Applications/Install\ macOS\ Mojave\.app/Contents/SharedSupport/InstallESD.dmg -noverify -mountpoint /Volumes/mojave | |
hdiutil create -o ./MojaveBase.cdr -size 7316m -layout SPUD -fs HFS+J | |
hdiutil attach ./MojaveBase.cdr.dmg -noverify -mountpoint /Volumes/install_build | |
asr restore -source /Applications/Install\ macOS\ Mojave\.app/Contents/SharedSupport/BaseSystem.dmg -target /Volumes/install_build -noprompt -noverify -erase | |
rm -rf /Volumes/OS\ X\ Base\ System/System/Installation/Packages | |
sudo mkdir -p /Volumes/OS\ X\ Base\ System/System/Installation/Packages | |
sudo cp -R /Volumes/mojave/Packages/* /Volumes/OS\ X\ Base\ System/System/Installation/Packages/ | |
hdiutil detach /Volumes/macOS\ Base\ System | |
hdiutil detach /Volumes/mojave/ |
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
# 1. Open Shell window 1 | |
namespace="annoying-namespace-to-delete" | |
# 2. Dump the namespace into a data file | |
kubectl get namespace ${namespace} -o json > tmp.json | |
# 3. Edit the namespace manually and make all the finalizers an empty array | |
# 4. Start kubectl proxy so we can use curl commands instead of kubectl (which doesn't work) | |
kubectl proxy --port=8787 |