This file contains 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
#!/bin/bash | |
# Custom scripts here | |
echo "This is an extended entrypoint!" | |
# Run the original entrypoint located at | |
# /docker-entrypoint.sh | |
exec /docker-entrypoint.sh "$@" |
This file contains 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
/** | |
* @param InstallContext $context | |
*/ | |
public function install(InstallContext $context) | |
{ | |
$serviceIds = $this->container->getServiceIds(); | |
$services = []; | |
$incr = 1; |
This file contains 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
// install docker-registry-api: npm install docker-registry-api | |
// fill in options | |
// run this: node docker-registry.js | |
const dockerRegistry = require('docker-registry-api'); | |
async function main() { | |
const options = { | |
user: "myuser", |
This file contains 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
#!/bin/bash | |
# http://www.camptocamp.com/en/actualite/flexible-docker-entrypoints-scripts/ | |
DIR=/docker-entrypoint.d | |
if [[ -d "$DIR" ]] | |
then | |
/usr/bin/run-parts --exit-on-error --verbose --arg "$@" "$DIR" | |
fi |
This file contains 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
# https://blog.hypriot.com/post/setup-simple-ci-pipeline-for-arm-images/ | |
### Choose a base image with QEMU binary | |
# FROM hypriot/rpi-alpine | |
# FROM resin/rpi-raspbian | |
# FROM resin/raspberry-pi-alpine-node:slim | |
### Register QEMU in the build agent | |
docker run --rm --privileged multiarch/qemu-user-static:register --reset |
This file contains 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
@echo off | |
:: %~dp0 = directory of this batch file | |
:: %CD% = pass cwd | |
:: %* = pass all arguments | |
php %~dp0\encode_base64.php %* | |
:: Usage: encode_base64 <path-to-file> |
This file contains 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
root@dcoker-registry:/root # pkg install -y py27-supervisor libevent2 py27-pip-1.5.6 | |
Updating repository catalogue | |
FreeBSD repository is up-to-date | |
All repositories are up-to-date | |
pkg: mplayerxp has a missing dependency: win32-codecs | |
The following 10 packages will be affected (of 0 checked): | |
New packages to be INSTALLED: | |
py27-supervisor: 3.0_1,1 | |
py27-meld3: 0.6.8_1 |
This file contains 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
node { | |
stage("composer_install") { | |
sh 'composer install' | |
} | |
stage("php_lint") { | |
sh 'find . -name "*.php" -print0 | xargs -0 -n1 php -l' | |
} | |
stage("phpunit") { |
This file contains 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
function and(first, second) { | |
return Number(first && second); | |
} | |
function or(first, second) { | |
return Number(first || second); | |
} | |
function not(first) { | |
return Number(!first); |
This file contains 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 | |
const NL = "\n"; | |
function getCmdArg($key, $default = '') | |
{ | |
global $argv; | |
$arguments = array_reverse($argv); |