Skip to content

Instantly share code, notes, and snippets.

@gizmotronic
gizmotronic / Dockerfile
Last active April 10, 2019 23:25
How to run the official Atlassian Bamboo Server image using a context path
FROM atlassian/bamboo-server:6.8.1
LABEL maintainer="alex.smythe@example.com"
RUN sed -i -e 's/Context path=""/Context path="${com.example.catalina.ContextPath}"/' ${BAMBOO_SERVER_INSTALL_DIR}/conf/server.xml
@gizmotronic
gizmotronic / user_data
Last active June 8, 2019 12:24
RancherOS cloud-config snippet for alternate SSH port
runcmd:
- [ sed, -i, -e, "/^#*[\\s]*Port\\s.*/s//Port 1022/", /etc/ssh/sshd_config ]
@gizmotronic
gizmotronic / post-receive
Last active June 14, 2018 10:55
Mirror gitlab repository via post-receive
#!/bin/sh
BACKUPPATH="/path/to/backup/location"
REPOPATH=`dirname $0`
REPOPATH=`cd -P "${REPOPATH}/.."; pwd`
cd "${REPOPATH}"
REPONAME=`basename "${REPOPATH}"`
@gizmotronic
gizmotronic / evc.coffee
Created June 30, 2013 01:51
Compare Node.js event signaling using callbacks vs. the event emitter class
EventEmitter = require('events').EventEmitter
class TestSubject extends EventEmitter
constructor: (callback) ->
@callback = callback
start: ->
started = Date.now()
while (Date.now() - started) < 10000
@emit 'fire'
@gizmotronic
gizmotronic / README.md
Last active December 14, 2015 05:39 — forked from dz0ny/99java

#Flash, java, mp3 and mp4 and pdf support for Chromium OS builds by hexxeh

This script downloads and installs libraries needed for Chromium, so that you can actually "TEST" multimedia experience.

##How to use?

Simply run as root user

curl -L http://goo.gl/WJRBFy | bash