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
$wshell = New-Object -ComObject wscript.shell; | |
# $wshell.AppActivate('title of the application window') | |
while($TRUE) | |
{ | |
Sleep 2 | |
$wshell.SendKeys('~') | |
} |
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
# start | |
docker-compose up -d | |
# curl from whitelisted container | |
docker-compose exec test-whitelisted curl 172.16.238.2:8300/v1/sys/health | |
# curl from blacklisted container | |
docker-compose exec test-blacklisted curl 172.16.238.2:8300/v1/sys/health --max-time 5 | |
# curl from whitelisted container again (this will fail) |
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 | |
cmd="$1" | |
chart="$2" | |
chart=${chart#*/} | |
prepare() { | |
mkdir -p "$chart/templates" |
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
terraform { | |
required_version = ">= 0.11.13" | |
} | |
provider "google" { | |
project = "${local.project}" | |
region = "${local.region}" | |
} | |
provider "google-beta" { |
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
- hosts: all | |
gather_facts: no | |
roles: | |
# Platforms | |
- { role: linux, when: platform == 'linux' } | |
- { role: osx, when: platform == 'osx' } | |
- { role: windows, when: platform == 'windows' } | |
# OS | |
- { role: ubuntu, when: distribution == 'ubuntu' } | |
- { role: void, when: distribution == 'void' } |
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
- name: Check for optional role | |
stat: | |
path: '{{ item }}/optional' | |
register: role_exists | |
loop: "{{ lookup('config', 'DEFAULT_ROLES_PATH') }}" | |
- include_role: | |
name: optional | |
when: true in role_exists.results | map(attribute='stat.exists') |
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
# git commit with "branch: " prefix | |
git config --global alias.cmb '!f() { \ | |
git cm "$(git rev-parse --abbrev-ref HEAD): $1" "${@:2}"; \ | |
}; f' |
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
pipeline { | |
agent any | |
stages { | |
stage('Build') { | |
steps { | |
echo 'Build' | |
} | |
post { | |
always { | |
echo 'Build Cleanup' |
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
; thrizen | |
; Three column layout for GridMove. | |
[Groups] | |
NumberOfGroups = 5 | |
; 2 wide - left [x|x| ] | |
[1] | |
TriggerTop = [Monitor1Top] | |
TriggerBottom = [Monitor1Height] * 1/16 |
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
<?php | |
// This is just an example of how you could generate that json file in the first place (this is likely more complicated that you need, but is what I need) | |
if (PROFILE_MEMORY && function_exists('tideways_enable')) { | |
// Start profiler | |
tideways_enable(TIDEWAYS_FLAGS_MEMORY); | |
// Stop profiler on shutdown | |
register_shutdown_function(function() { |