Skip to content

Instantly share code, notes, and snippets.

View bangpound's full-sized avatar

Benjamin Doherty bangpound

View GitHub Profile
@bangpound
bangpound / vault-token-helper.sh
Created September 9, 2018 15:13
Vault Token helper for the Linux key retention service
#!/usr/bin/env bash
# Vault Token helper for the Linux key retention service.
#
# Since version 2.6, the Linux kernel has included a efficiently store
# authentication data on a per thread, per process, per user, or per session
# bases.
#
# Linux Key Management Utilities (keyutils) provides `keyctl` to control
# the facility from the shell.
@bangpound
bangpound / compass-rgbapng.rb
Created April 24, 2010 20:08
Cross-browser translucent backgrounds. Creates RGBa PNG files at compile time.
# bangpound does not know Ruby.
#
# inspired by http://www.alloycode.com/2009/6/19/fun-with-rmagick
#
# RGBa PNG method described at http://leaverou.me/2009/02/bulletproof-cross-browser-rgba-backgrounds/
module Sass::Script::Functions
def rgbapng(color)
require 'rubygems'
require "RMagick"
@bangpound
bangpound / vault-iam-auth.php
Last active March 18, 2021 21:33
AWS IAM authentication to Vault with AWS SDK v3 on PHP
<?php
// Use the AWS security token service's GetCallerIdentity command
// to produce a request that allows Vault to identify the instance
// that wants to authenticate.
//
// @see https://gist.github.com/joelthompson/378cbe449d541debf771f5a6a171c5ed
$sts = new \Aws\Sts\StsClient([
'region' => 'us-east-1',
@bangpound
bangpound / ui.all.sass
Created January 21, 2010 20:03
jQuery UI 1.6 theme sass
// $Id$
//
jQuery UI screen structure and presentation
This CSS file was generated by ThemeRoller, a Filament Group Project for jQuery UI
Author: Scott Jehl, scott@filamentgroup.com, http://www.filamentgroup.com
Visit themeroller.com
@import compass/utilities/general/reset.sass
@import compass/utilities/general/float.sass
#!/usr/bin/env bash
# Vault Token helper for the Mac OS X Keychain.
#
# Vault allows an external programs to be configured as a token helper
# that can get, store, and erase tokens on behalf of the Vault client.
#
# see https://www.vaultproject.io/docs/commands/token-helper.html
#
# To use this script, make it executable and set your ~/.vault file to
@bangpound
bangpound / README.md
Last active November 5, 2017 18:46
INI File from Ansible for use anywhere

INI File

For example:

  • ini_file.py php.ini --section PHP --option memory_limit --value 256M
@bangpound
bangpound / -
Created November 2, 2017 15:56
diff --git a/app/components/ac-edit-group-modal/permissions/component.js b/app/components/ac-edit-group-modal/permissions/component.js
index ea3e7f4b0..c25dcd786 100644
--- a/app/components/ac-edit-group-modal/permissions/component.js
+++ b/app/components/ac-edit-group-modal/permissions/component.js
@@ -24,7 +24,7 @@ export default Component.extend({
*/
permissionCheckboxToggled: function(permission) {
this.set('group.' + permission.get('slug'), !permission.get('checked'));
- permission.set('checked', !permission.get('checked'));
+ permission.set('checked', !permission.get('checked'));
#!/bin/bash
[ -d ac_global/jsc ] || mkdir ac_global/jsc
[ -d admin/jsc ] || mkdir admin/jsc
closure_compile() {
temp="${1%\'}"
temp="${temp#\'}"
list=()
js=$(jq --raw-output '.["'"$temp"'"] | @sh' < tools/compilejs.json)
# vim: set ft=ruby:
# port on VM => port on host machine
port_mapping = {
80 => 8080,
443 => 4343,
1004 => 8081,
9200 => 9201,
}

RoboFile for ActiveCampaign

  1. composer global require consolidation/robo or download robo.phar from http://robo.li/ and put it in your $PATH.
  2. Copy the RoboFile.php above so that it is a sibling of dev
  3. Modify the properties at the top like the $originPrefix and $allRepos.

Some things

  • robo git:update to add the upstream remote to all of your repositories.