├── .gitignore ├── README.md ├── builder ├── base │ ├── Dockerfile │ ├── golang.sh │ ├── rootfs │ │ ├── etc │ │ │ ├── apt │ │ │ │ └── apt.conf.d │ │ │ │ │ └── 90forceyes │ │ │ ├── bash.bashrc │ │ │ ├── drone.d │ │ │ │ ├── golang.sh │ │ │ │ ├── gradle.sh │ │ │ │ ├── nodejs.sh │ │ │ │ ├── rbenv.sh │ │ │ │ └── xvfb.sh │ │ │ ├── init.d │ │ │ │ └── xvfb │ │ │ ├── resolv.conf │ │ │ └── sudoers │ │ ├── home │ │ │ └── ubuntu │ │ │ │ ├── .gitconfig │ │ │ │ └── .ssh │ │ │ │ └── config │ │ └── root │ │ │ ├── .gitconfig │ │ │ └── .ssh │ │ │ └── config │ └── scripts │ │ ├── all.sh │ │ ├── build-essential.sh │ │ ├── chrome.sh │ │ ├── chromium.sh │ │ ├── firefox.sh │ │ ├── fonts.sh │ │ ├── gcc.sh │ │ ├── golang.sh │ │ ├── libcurl.sh │ │ ├── libffi.sh │ │ ├── libgdbm.sh │ │ ├── libmagick.sh │ │ ├── libmemcache.sh │ │ ├── libmysql.sh │ │ ├── libncurses.sh │ │ ├── libossp-uuid.sh │ │ ├── libpq.sh │ │ ├── libqt4.sh │ │ ├── libreadline.sh │ │ ├── libsqlite.sh │ │ ├── libssl.sh │ │ ├── libxml.sh │ │ ├── libyaml.sh │ │ ├── libzmq.sh │ │ ├── mysql-cli.sh │ │ ├── nodejs.sh │ │ ├── openjdk.sh │ │ ├── phantomjs.sh │ │ ├── postgres-client.sh │ │ ├── python.sh │ │ ├── ruby.sh │ │ ├── scons.sh │ │ └── zlib.sh ├── cleanup ├── clojure │ └── lein │ │ └── Dockerfile ├── dart │ ├── dart_dev │ │ ├── Dockerfile │ │ └── dart.sh │ └── dart_stable │ │ ├── Dockerfile │ │ └── dart.sh ├── dlang │ └── dmd_2.064.2 │ │ └── Dockerfile ├── docker-in-docker │ └── Dockerfile ├── erlang │ ├── erlang_R14B02 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R14B03 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R14B04 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R15B │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R15B01 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R15B02 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R15B03 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R16B │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R16B01 │ │ ├── Dockerfile │ │ └── kerl.sh │ ├── erlang_R16B02 │ │ ├── Dockerfile │ │ └── kerl.sh │ └── kerl │ │ └── Dockerfile ├── gcc │ ├── gcc_4.6 │ │ └── Dockerfile │ └── gcc_4.8 │ │ └── Dockerfile ├── golang │ ├── go_1.0 │ │ ├── Dockerfile │ │ └── golang.sh │ ├── go_1.1 │ │ ├── Dockerfile │ │ └── golang.sh │ ├── go_1.2 │ │ ├── Dockerfile │ │ └── golang.sh │ ├── go_1.3 │ │ ├── Dockerfile │ │ └── golang.sh │ ├── go_1.4 │ │ ├── Dockerfile │ │ └── golang.sh │ └── go_gae │ │ ├── .dronerc │ │ └── Dockerfile ├── haskell │ └── haskell_7.4 │ │ └── Dockerfile ├── java │ ├── java_openjdk6 │ │ └── Dockerfile │ ├── java_openjdk7 │ │ └── Dockerfile │ ├── java_oraclejdk7 │ │ └── Dockerfile │ └── java_oraclejdk8 │ │ └── Dockerfile ├── node │ ├── node_0.10 │ │ ├── Dockerfile │ │ └── nodejs.sh │ ├── node_0.8 │ │ ├── Dockerfile │ │ └── nodejs.sh │ └── nvm │ │ └── Dockerfile ├── php │ ├── php_5.3 │ │ ├── Dockerfile │ │ └── phpenv.sh │ ├── php_5.4 │ │ ├── Dockerfile │ │ └── phpenv.sh │ ├── php_5.5 │ │ ├── Dockerfile │ │ └── phpenv.sh │ └── phpenv │ │ ├── Dockerfile │ │ └── phpenv.sh ├── python │ ├── pypy │ │ ├── Dockerfile │ │ └── python.sh │ ├── python_2.6 │ │ ├── Dockerfile │ │ └── python.sh │ ├── python_2.7 │ │ ├── Dockerfile │ │ └── python.sh │ ├── python_3.1 │ │ ├── Dockerfile │ │ └── python.sh │ ├── python_3.2 │ │ ├── Dockerfile │ │ └── python.sh │ ├── python_3.3 │ │ ├── Dockerfile │ │ └── python.sh │ └── virtualenv │ │ └── Dockerfile ├── rlang │ └── rlang │ │ └── Dockerfile ├── ruby │ ├── jruby_1.7.11_openjdk6 │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── jruby_1.7.11_openjdk7 │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── rbenv │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── ruby_1.9.3 │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── ruby_2.0.0 │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── ruby_2.1.0 │ │ ├── Dockerfile │ │ └── rbenv.sh │ ├── ruby_2.1.1 │ │ ├── Dockerfile │ │ └── rbenv.sh │ └── ruby_2.1.4 │ │ ├── Dockerfile │ │ └── rbenv.sh ├── scala │ ├── scala_2.10.3 │ │ ├── Dockerfile │ │ └── scala.sh │ └── scala_2.9.3 │ │ ├── Dockerfile │ │ └── scala.sh └── setup ├── database ├── couchdb │ ├── couchdb_1.0 │ │ └── Dockerfile │ ├── couchdb_1.4 │ │ └── Dockerfile │ └── couchdb_1.5 │ │ └── Dockerfile ├── elasticsearch │ ├── elasticsearch_0.20 │ │ └── Dockerfile │ ├── elasticsearch_0.90.8 │ │ └── Dockerfile │ ├── elasticsearch_0.90 │ │ └── Dockerfile │ └── elasticsearch_1.0.1 │ │ └── Dockerfile ├── memcached │ └── memcached_1.4 │ │ └── Dockerfile ├── mongodb │ ├── mongodb_2.2 │ │ └── Dockerfile │ └── mongodb_2.4 │ │ └── Dockerfile ├── mysql │ ├── mysql_5.5-jp │ │ └── Dockerfile │ └── mysql_5.5 │ │ └── Dockerfile ├── neo4j │ └── neo4j_1.9 │ │ └── Dockerfile ├── postgres │ ├── postgres_9.1 │ │ ├── Dockerfile │ │ ├── pg_hba.conf │ │ └── postgresql.conf │ └── postgres_9.3 │ │ ├── Dockerfile │ │ ├── pg_hba.conf │ │ └── postgresql.conf ├── redis │ ├── redis_2.6 │ │ └── Dockerfile │ └── redis_2.8 │ │ └── Dockerfile └── riak │ └── Dockerfile ├── service └── rabbitmq │ └── rabbitmq_3.2 │ └── Dockerfile └── ubuntu ├── rootfs ├── etc │ ├── apt │ │ └── apt.conf.d │ │ │ └── 90forceyes │ ├── bash.bashrc │ ├── init.d │ │ └── xvfb │ ├── resolv.conf │ └── sudoers ├── home │ └── ubuntu │ │ ├── .bashrc │ │ ├── .gitconfig │ │ └── .ssh │ │ └── config └── root │ ├── .gitconfig │ └── .ssh │ └── config └── setup.sh /.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Scripts and Dockerfiles used to generate build machines for the Drone 2 | Continuous Integration server. 3 | 4 | ## ubuntu 5 | 6 | We create a root Ubuntu image using the Ubuntu Cloud ISO. This means 7 | our root image will be almost identical to an Ubuntu 12.04 Amazon AMI, 8 | but with added software packages (git, svn, hg, bzr, xvfb). 9 | 10 | We recommend installing this image directly from the Docker index: 11 | 12 | ``` 13 | sudo docker pull bradrydzewski/ubuntu 14 | ``` 15 | 16 | ## base 17 | 18 | We create a base image with common compilers (gcc), toolchains (make, cmake, etc), 19 | libraries (libcurl, libssl, etc) and base languages (python, ruby, go, java, node). 20 | 21 | ``` 22 | sudo docker build -rm -t bradrydzewski/base base/Dockerfile 23 | ``` 24 | 25 | ## builders 26 | 27 | We create language-specific Docker images from the `base` image. These images 28 | are intended to build and test your code. 29 | 30 | Base Image 31 | 32 | ```sh 33 | sudo docker build -rm -t bradrydzewski/base builder/base/ 34 | ``` 35 | 36 | Dart Images 37 | 38 | ``` 39 | sudo docker build -rm -t bradrydzewski/dart builder/dart/dart_stable/ 40 | sudo docker build -rm -t bradrydzewski/dart:dev builder/dart/dart_dev/ 41 | ``` 42 | 43 | Erlang Images 44 | 45 | ```sh 46 | sudo docker build -rm -t bradrydzewski/erlang builder/erlang/erlang/ 47 | sudo docker build -rm -t bradrydzewski/erlang:R16B02 builder/erlang/erlang_R16B02/ 48 | sudo docker build -rm -t bradrydzewski/erlang:R16B01 builder/erlang/erlang_R16B01/ 49 | sudo docker build -rm -t bradrydzewski/erlang:R16B builder/erlang/erlang_R16B/ 50 | sudo docker build -rm -t bradrydzewski/erlang:R15B03 builder/erlang/erlang_R15B03/ 51 | sudo docker build -rm -t bradrydzewski/erlang:R15B02 builder/erlang/erlang_R15B02/ 52 | sudo docker build -rm -t bradrydzewski/erlang:R15B01 builder/erlang/erlang_R15B01/ 53 | sudo docker build -rm -t bradrydzewski/erlang:R15B builder/erlang/erlang_R15B/ 54 | sudo docker build -rm -t bradrydzewski/erlang:R14B04 builder/erlang/erlang_R14B04/ 55 | sudo docker build -rm -t bradrydzewski/erlang:R14B03 builder/erlang/erlang_R14B03/ 56 | sudo docker build -rm -t bradrydzewski/erlang:R14B02 builder/erlang/erlang_R14B02/ 57 | sudo docker build -rm -t bradrydzewski/erlang:R14B01 builder/erlang/erlang_R14B01/ 58 | sudo docker build -rm -t bradrydzewski/erlang:R14A builder/erlang/erlang_R14A/ 59 | ``` 60 | 61 | Go Images 62 | 63 | ```sh 64 | sudo docker build -rm -t bradrydzewski/go:1.0 builder/golang/go_1.0/ 65 | sudo docker build -rm -t bradrydzewski/go:1.1 builder/golang/go_1.1/ 66 | sudo docker build -rm -t bradrydzewski/go:1.2 builder/golang/go_1.2/ 67 | ``` 68 | 69 | Haskell Images 70 | 71 | ```sh 72 | sudo docker build -rm -t bradrydzewski/haskell builder/haskell/haskell_7.4/ 73 | ``` 74 | 75 | Node Images 76 | 77 | ```sh 78 | sudo docker build -rm -t bradrydzewski/node builder/node/node/ 79 | sudo docker build -rm -t bradrydzewski/node:0.10 builder/node/node_0.10/ 80 | sudo docker build -rm -t bradrydzewski/node:0.8 builder/node/node_0.8/ 81 | sudo docker build -rm -t bradrydzewski/node:0.6 builder/node/node_0.6/ 82 | ``` 83 | 84 | PHP Images 85 | 86 | ```sh 87 | sudo docker build -rm -t bradrydzewski/php builder/php/php 88 | sudo docker build -rm -t bradrydzewski/php:5.5 builder/php/php_5.5 89 | sudo docker build -rm -t bradrydzewski/php:5.4 builder/php/php_5.4 90 | sudo docker build -rm -t bradrydzewski/php:5.3 builder/php/php_5.3 91 | ``` 92 | 93 | Python Images 94 | 95 | ```sh 96 | sudo docker build -rm -t bradrydzewski/python builder/python/python/ 97 | sudo docker build -rm -t bradrydzewski/python:2.6 builder/python/python_2.6/ 98 | sudo docker build -rm -t bradrydzewski/python:2.7 builder/python/python_2.7/ 99 | sudo docker build -rm -t bradrydzewski/python:3.2 builder/python/python_3.2/ 100 | sudo docker build -rm -t bradrydzewski/python:3.3 builder/python/python_3.3/ 101 | sudo docker build -rm -t bradrydzewski/python:pypy builder/python/pypy/ 102 | ``` 103 | 104 | Ruby Images 105 | 106 | ```sh 107 | sudo docker build -rm -t bradrydzewski/ruby:1.9.3 builder/ruby/ruby_1.9.3/ 108 | sudo docker build -rm -t bradrydzewski/ruby:2.0.0 builder/ruby/ruby_2.0.0/ 109 | sudo docker build -rm -t bradrydzewski/ruby:2.1.0 builder/ruby/ruby_2.1.0/ 110 | sudo docker build -rm -t bradrydzewski/ruby:2.1.1 builder/ruby/ruby_2.1.1/ 111 | sudo docker build -rm -t bradrydzewski/jruby:1.7.11-openjdk6 builder/ruby/jruby_1.7.11_openjdk6/ 112 | sudo docker build -rm -t bradrydzewski/jruby:1.7.11-openjdk7 builder/ruby/jruby_1.7.11_openjdk7/ 113 | ``` 114 | 115 | TODO 116 | 117 | * Java 118 | * Clojure 119 | * Scala 120 | * Groovy 121 | 122 | TODO 123 | 124 | * Perl 125 | * Rust 126 | -------------------------------------------------------------------------------- /builder/base/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/ubuntu 2 | MAINTAINER Brad Rydzewski 3 | 4 | ADD rootfs/etc /etc/ 5 | ADD rootfs/root /root/ 6 | ADD rootfs/home/ubuntu /home/ubuntu/ 7 | RUN whoami && chown -R ubuntu:ubuntu /home/ubuntu && chmod 0440 /etc/sudoers 8 | 9 | 10 | WORKDIR /home/ubuntu 11 | USER ubuntu 12 | ENV HOME /home/ubuntu 13 | ENV LANG en_US.UTF-8 14 | ENV LANGUAGE en_US:en 15 | ENV LOGNAME ubuntu 16 | ENV TERM xterm 17 | 18 | ADD scripts /var/cache/drone/scripts 19 | RUN cd /var/cache/drone/scripts && sudo chmod +x *.sh && ./all.sh && sudo rm -rf /var/cache/drone/scripts 20 | -------------------------------------------------------------------------------- /builder/base/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/lib/go 3 | export GOPATH=/home/ubuntu 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/base/rootfs/etc/apt/apt.conf.d/90forceyes: -------------------------------------------------------------------------------- 1 | APT::Get::Assume-Yes "true";APT::Get::force-yes "true"; -------------------------------------------------------------------------------- /builder/base/rootfs/etc/bash.bashrc: -------------------------------------------------------------------------------- 1 | # System-wide .bashrc file for interactive bash(1) shells. 2 | 3 | # To enable the settings / commands in this file for login shells as well, 4 | # this file has to be sourced in /etc/profile. 5 | 6 | # Load default environemnt scripts to be used by the Drone 7 | # continuous integration system. 8 | if [ -d /etc/drone.d ]; then 9 | for i in /etc/drone.d/*.sh; do 10 | if [ -r $i ]; then 11 | . $i 12 | fi 13 | done 14 | unset i 15 | fi 16 | 17 | # If not running interactively, don't do anything 18 | [ -z "$PS1" ] && return 19 | 20 | # check the window size after each command and, if necessary, 21 | # update the values of LINES and COLUMNS. 22 | shopt -s checkwinsize 23 | 24 | # set variable identifying the chroot you work in (used in the prompt below) 25 | if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then 26 | debian_chroot=$(cat /etc/debian_chroot) 27 | fi 28 | 29 | # set a fancy prompt (non-color, overwrite the one in /etc/profile) 30 | PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' 31 | 32 | # Commented out, don't overwrite xterm -T "title" -n "icontitle" by default. 33 | # If this is an xterm set the title to user@host:dir 34 | #case "$TERM" in 35 | #xterm*|rxvt*) 36 | # PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"' 37 | # ;; 38 | #*) 39 | # ;; 40 | #esac 41 | 42 | # enable bash completion in interactive shells 43 | #if [ -f /etc/bash_completion ] && ! shopt -oq posix; then 44 | # . /etc/bash_completion 45 | #fi 46 | 47 | # sudo hint 48 | if [ ! -e "$HOME/.sudo_as_admin_successful" ] && [ ! -e "$HOME/.hushlogin" ] ; then 49 | case " $(groups) " in *\ admin\ *) 50 | if [ -x /usr/bin/sudo ]; then 51 | cat <<-EOF 52 | To run a command as administrator (user "root"), use "sudo ". 53 | See "man sudo_root" for details. 54 | 55 | EOF 56 | fi 57 | esac 58 | fi 59 | 60 | # if the command-not-found package is installed, use it 61 | if [ -x /usr/lib/command-not-found -o -x /usr/share/command-not-found/command-not-found ]; then 62 | function command_not_found_handle { 63 | # check because c-n-f could've been removed in the meantime 64 | if [ -x /usr/lib/command-not-found ]; then 65 | /usr/bin/python /usr/lib/command-not-found -- "$1" 66 | return $? 67 | elif [ -x /usr/share/command-not-found/command-not-found ]; then 68 | /usr/bin/python /usr/share/command-not-found/command-not-found -- "$1" 69 | return $? 70 | else 71 | printf "%s: command not found\n" "$1" >&2 72 | return 127 73 | fi 74 | } 75 | fi 76 | -------------------------------------------------------------------------------- /builder/base/rootfs/etc/drone.d/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/lib/go 3 | export GOPATH=/home/ubuntu 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/base/rootfs/etc/drone.d/gradle.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/usr/local/gradle-1.9/bin -------------------------------------------------------------------------------- /builder/base/rootfs/etc/drone.d/nodejs.sh: -------------------------------------------------------------------------------- 1 | . /home/ubuntu/nvm/nvm.sh 2 | nvm use v0.10.22 > /dev/null -------------------------------------------------------------------------------- /builder/base/rootfs/etc/drone.d/rbenv.sh: -------------------------------------------------------------------------------- 1 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 2 | 3 | # set default env vars 4 | export RBENV_VERSION=2.0.0-p353 5 | export RAILS_ENV=${RAILS_ENV:-test} 6 | 7 | # initialize and set ruby version 8 | eval "$(rbenv init -)" 9 | rbenv global 2.0.0-p353 10 | -------------------------------------------------------------------------------- /builder/base/rootfs/etc/drone.d/xvfb.sh: -------------------------------------------------------------------------------- 1 | export DISPLAY=:0 -------------------------------------------------------------------------------- /builder/base/rootfs/etc/init.d/xvfb: -------------------------------------------------------------------------------- 1 | XVFB=/usr/bin/Xvfb 2 | XVFBARGS=":99 -ac -screen 0 1024x768x24" 3 | PIDFILE=/tmp/cucumber_xvfb_99.pid 4 | case "$1" in 5 | start) 6 | echo -n "Starting virtual X frame buffer: Xvfb" 7 | /sbin/start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile --background --exec $XVFB -- $XVFBARGS 8 | echo "." 9 | ;; 10 | stop) 11 | echo -n "Stopping virtual X frame buffer: Xvfb" 12 | /sbin/start-stop-daemon --stop --quiet --pidfile $PIDFILE 13 | rm -f $PIDFILE 14 | echo "." 15 | ;; 16 | restart) 17 | $0 stop 18 | $0 start 19 | ;; 20 | *) 21 | echo "Usage: /etc/init.d/xvfb {start|stop|restart}" 22 | exit 1 23 | esac 24 | exit 0 25 | -------------------------------------------------------------------------------- /builder/base/rootfs/etc/resolv.conf: -------------------------------------------------------------------------------- 1 | nameserver 4.2.2.2 2 | nameserver 8.8.8.8 -------------------------------------------------------------------------------- /builder/base/rootfs/etc/sudoers: -------------------------------------------------------------------------------- 1 | # 2 | # This file MUST be edited with the 'visudo' command as root. 3 | # 4 | # Please consider adding local content in /etc/sudoers.d/ instead of 5 | # directly modifying this file. 6 | # 7 | # See the man page for details on how to write a sudoers file. 8 | # 9 | Defaults env_reset 10 | Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" 11 | 12 | # Host alias specification 13 | 14 | # User alias specification 15 | 16 | # Cmnd alias specification 17 | 18 | # User privilege specification 19 | root ALL=(ALL:ALL) ALL 20 | ubuntu ALL=NOPASSWD: ALL 21 | 22 | # Members of the admin group may gain root privileges 23 | %admin ALL=(ALL) ALL 24 | 25 | # Allow members of group sudo to execute any command 26 | %sudo ALL=(ALL:ALL) ALL 27 | 28 | # See sudoers(5) for more information on "#include" directives: 29 | 30 | #includedir /etc/sudoers.d 31 | -------------------------------------------------------------------------------- /builder/base/rootfs/home/ubuntu/.gitconfig: -------------------------------------------------------------------------------- 1 | [user] 2 | name = drone 3 | email = build@drone.io -------------------------------------------------------------------------------- /builder/base/rootfs/home/ubuntu/.ssh/config: -------------------------------------------------------------------------------- 1 | StrictHostKeyChecking no -------------------------------------------------------------------------------- /builder/base/rootfs/root/.gitconfig: -------------------------------------------------------------------------------- 1 | [user] 2 | name = drone 3 | email = build@drone.io -------------------------------------------------------------------------------- /builder/base/rootfs/root/.ssh/config: -------------------------------------------------------------------------------- 1 | StrictHostKeyChecking no -------------------------------------------------------------------------------- /builder/base/scripts/all.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -x 4 | set -e 5 | 6 | # update packages 7 | sudo apt-get -qq update 8 | 9 | # essential 10 | sudo apt-get -y install git git-core subversion mercurial bzr fossil xvfb socat 11 | 12 | # gcc and build tools 13 | ./gcc.sh 14 | ./build-essential.sh 15 | ./scons.sh 16 | 17 | # install a ton of libraries 18 | ./libcurl.sh 19 | ./libffi.sh 20 | ./libgdbm.sh 21 | ./libmagick.sh 22 | ./libmemcache.sh 23 | ./libmysql.sh 24 | ./libncurses.sh 25 | ./libossp-uuid.sh 26 | ./libpq.sh 27 | ./libqt4.sh 28 | ./libreadline.sh 29 | ./libsqlite.sh 30 | ./libssl.sh 31 | ./libxml.sh 32 | ./libyaml.sh 33 | ./libzmq.sh 34 | ./zlib.sh 35 | 36 | # database clients 37 | ./mysql-cli.sh 38 | ./postgres-client.sh 39 | 40 | # WARNING: ITEMS BELOW WILL CHANGE OVER TIME 41 | 42 | # install browsers 43 | ./chromium.sh 44 | ./firefox.sh 45 | ./chrome.sh 46 | ./phantomjs.sh 47 | 48 | # install base languages 49 | ./openjdk.sh 50 | ./python.sh 51 | ./nodejs.sh 52 | ./ruby.sh 53 | ./golang.sh 54 | 55 | 56 | # browser.sh (chromium, chrome, firefox, phantomjs) 57 | # compiler.sh (gcc, go) 58 | # lib.sh (...) 59 | # runtime.sh (node, ruby, java, python, go) 60 | # toolchain.sh (make, cmake) 61 | 62 | exit 0 63 | -------------------------------------------------------------------------------- /builder/base/scripts/build-essential.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install build-essential -------------------------------------------------------------------------------- /builder/base/scripts/chrome.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | # Installs the Google Chrome Browser (unstable) to /usr/bin/google-chrome 3 | pushd /tmp 4 | 5 | # update apt to include Google repository 6 | #wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add - 7 | #sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list' 8 | #sudo apt-get update 9 | 10 | # install chrome unstable 11 | #sudo apt-get -y install google-chrome-stable 12 | 13 | # install chrome driver 14 | wget http://chromedriver.storage.googleapis.com/2.7/chromedriver_linux64.zip --quiet 15 | unzip chromedriver_linux64.zip 16 | sudo install -t /usr/local/bin chromedriver 17 | rm chromedriver_linux64.zip 18 | 19 | popd -------------------------------------------------------------------------------- /builder/base/scripts/chromium.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | # install libqt4-dev 4 | sudo apt-get -y install libqt4-dev 5 | 6 | # install webkit headers and browser 7 | sudo apt-get -y install libqtwebkit-dev chromium-browser -------------------------------------------------------------------------------- /builder/base/scripts/firefox.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install firefox -------------------------------------------------------------------------------- /builder/base/scripts/fonts.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e -------------------------------------------------------------------------------- /builder/base/scripts/gcc.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | # installs the GNU C compiler 4 | sudo apt-get -y install gcc clang 5 | 6 | # the debian repository suggests we install autotools: 7 | sudo apt-get -y install automake autoconf autogen libtool 8 | 9 | # the debian repository also recommends we install these: 10 | sudo apt-get -y install make cmake gdb bison unzip flex -------------------------------------------------------------------------------- /builder/base/scripts/golang.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | set -e 3 | 4 | pushd /tmp 5 | 6 | # install dependencies 7 | sudo apt-get -y install pkg-config 8 | 9 | # download and install Go binaries 10 | wget https://go.googlecode.com/files/go1.1.2.linux-amd64.tar.gz --quiet 11 | sudo tar -C /usr/lib -xzf go1.1.2.linux-amd64.tar.gz 12 | rm go1.1.2.linux-amd64.tar.gz 13 | 14 | # ubuntu user must have access to the go 15 | # standard library 16 | sudo chown -R ubuntu:ubuntu /usr/lib/go 17 | 18 | popd -------------------------------------------------------------------------------- /builder/base/scripts/libcurl.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libcurl3 libcurl3-gnutls libcurl4-openssl-dev -------------------------------------------------------------------------------- /builder/base/scripts/libffi.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libffi-dev libffi6 -------------------------------------------------------------------------------- /builder/base/scripts/libgdbm.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libgdbm-dev -------------------------------------------------------------------------------- /builder/base/scripts/libmagick.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libgvc5 libmagickwand-dev imagemagick -------------------------------------------------------------------------------- /builder/base/scripts/libmemcache.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libmemcache-dev -------------------------------------------------------------------------------- /builder/base/scripts/libmysql.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libmysqlclient-dev -------------------------------------------------------------------------------- /builder/base/scripts/libncurses.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libncurses5 libncurses5-dev libncurses5-dbg -------------------------------------------------------------------------------- /builder/base/scripts/libossp-uuid.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libossp-uuid-dev -------------------------------------------------------------------------------- /builder/base/scripts/libpq.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | sudo apt-get -y install libpq-dev -------------------------------------------------------------------------------- /builder/base/scripts/libqt4.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libqt4-dev -------------------------------------------------------------------------------- /builder/base/scripts/libreadline.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libreadline6 libreadline6-dev -------------------------------------------------------------------------------- /builder/base/scripts/libsqlite.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libsqlite3-dev sqlite3 sqlite3-doc -------------------------------------------------------------------------------- /builder/base/scripts/libssl.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libssl-dev -------------------------------------------------------------------------------- /builder/base/scripts/libxml.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libxml2-dev libxslt1-dev libxslt-dev -------------------------------------------------------------------------------- /builder/base/scripts/libyaml.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libyaml-0-2 libyaml-dev libtool -------------------------------------------------------------------------------- /builder/base/scripts/libzmq.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install libzmq-dev -------------------------------------------------------------------------------- /builder/base/scripts/mysql-cli.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | sudo apt-get install -y mysql-client 4 | -------------------------------------------------------------------------------- /builder/base/scripts/nodejs.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # add the ubuntu PPA for Node 4 | #sudo apt-get install software-properties-common 5 | #sudo add-apt-repository --yes ppa:chris-lea/node.js 6 | #sudo apt-get -qq update 7 | 8 | # install latest stable version of nodejs 9 | #sudo apt-get -y install nodejs 10 | 11 | git clone git://github.com/creationix/nvm.git /home/ubuntu/nvm 12 | . /home/ubuntu/nvm/nvm.sh 13 | nvm install v0.10.22 -------------------------------------------------------------------------------- /builder/base/scripts/openjdk.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # install openjdk7 by default 4 | sudo apt-get -y install openjdk-7-jdk 5 | 6 | # install commonly used Java build tools 7 | sudo apt-get -y install ant ant-contrib ivy maven 8 | 9 | # install utility that allows us to switch JDK versions 10 | sudo apt-get -y install default-jdk 11 | 12 | # Download gradle 1.3 13 | wget http://services.gradle.org/distributions/gradle-1.9-bin.zip --quiet 14 | unzip -q gradle-1.9-bin.zip 15 | rm gradle-1.9-bin.zip 16 | sudo mv gradle-1.9 /usr/local 17 | sudo chown -R ubuntu:ubuntu /usr/local/gradle-1.9 18 | chmod +x /usr/local/gradle-1.9/bin/gradle -------------------------------------------------------------------------------- /builder/base/scripts/phantomjs.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | # see http://phantomjs.org/build.html 3 | set -e 4 | 5 | pushd /tmp 6 | 7 | # install dependencies 8 | sudo apt-get update 9 | sudo apt-get install build-essential chrpath git-core libssl-dev libfontconfig1-dev 10 | 11 | # download phantomjs and decompress 12 | wget https://phantomjs.googlecode.com/files/phantomjs-1.9.2-linux-x86_64.tar.bz2 13 | tar xjf phantomjs-1.9.2-linux-x86_64.tar.bz2 14 | 15 | # install binary 16 | sudo install -t /usr/local/bin phantomjs-1.9.2-linux-x86_64/bin/phantomjs 17 | 18 | # cleanup after ourselves 19 | rm -rf phantomjs-1.9.2-linux-x86_64 20 | rm phantomjs-1.9.2-linux-x86_64.tar.bz2 21 | 22 | popd -------------------------------------------------------------------------------- /builder/base/scripts/postgres-client.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install postgresql-client-9.1 -------------------------------------------------------------------------------- /builder/base/scripts/python.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | # install python 2.7, headers, setuptools, etc 4 | sudo apt-get -y install python2.7 python-software-properties python-setuptools python-dev 5 | 6 | # install pip and distribute 7 | sudo easy_install pip 8 | sudo pip install distribute --upgrade 9 | 10 | # make sure the ubuntu user can add packages without sudo 11 | sudo chown -R 1000:1000 /usr/local/lib/python2.7 -------------------------------------------------------------------------------- /builder/base/scripts/ruby.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | pushd /tmp 3 | 4 | git clone git://github.com/sstephenson/rbenv.git /home/ubuntu/.rbenv && \ 5 | git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build 6 | 7 | export PATH=$PATH:/home/ubuntu/.rbenv/bin 8 | export RBENV_VERSION=2.0.0-p353 9 | eval "$(rbenv init -)" 10 | CC=gcc rbenv install 2.0.0-p353 11 | rbenv rehash 12 | rbenv global 2.0.0-p353 13 | rbenv rehash 14 | gem install bundler 15 | rbenv rehash 16 | 17 | popd -------------------------------------------------------------------------------- /builder/base/scripts/scons.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install scons -------------------------------------------------------------------------------- /builder/base/scripts/zlib.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash -e 2 | 3 | sudo apt-get -y install zlib1g zlib1g-dev -------------------------------------------------------------------------------- /builder/cleanup: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | 3 | # clojure 4 | remove("lein"); 5 | 6 | # dart 7 | remove("dart:stable"); 8 | remove("dart:dev"); 9 | 10 | # dlang 11 | remove("dmd:2.064.2"); 12 | 13 | # rlang 14 | remove("rlang:rlang"); 15 | 16 | # erlang 17 | remove("erlang:R16B02"); 18 | remove("erlang:R16B01"); 19 | remove("erlang:R16B"); 20 | remove("erlang:R15B"); 21 | remove("kerl"); 22 | 23 | # gcc 24 | remove("gcc:4.6"); 25 | remove("gcc:4.8"); 26 | 27 | # golang 28 | remove("go:1.2"); 29 | remove("go:1.1"); 30 | remove("go:1.0"); 31 | 32 | # groovy 33 | skip("groovy"); 34 | 35 | # haskell 36 | remove("haskell:7.4"); 37 | 38 | # java 39 | remove("java:openjdk6"); 40 | remove("java:openjdk7"); 41 | remove("java:oraclejdk7"); 42 | remove("java:oraclejdk8"); 43 | skip("java:android"); 44 | 45 | # node 46 | remove("node:0.10"); 47 | remove("node:0.8"); 48 | remove("nvm"); 49 | 50 | # php 51 | remove("php:5.4"); 52 | remove("php:5.5"); 53 | remove("phpenv"); 54 | 55 | # python 56 | remove("python:2.7"); 57 | remove("python:3.2"); 58 | remove("python:3.3"); 59 | remove("python:pypy"); 60 | remove("virtualenv"); 61 | 62 | # ruby 63 | remove("ruby:1.9.3"); 64 | remove("ruby:2.0.0"); 65 | remove("ruby:2.1.0"); 66 | remove("ruby:2.1.1"); 67 | remove("jruby:1.7.11-openjdk6"); 68 | remove("jruby:1.7.11-openjdk7"); 69 | remove("rbenv"); 70 | 71 | # scala 72 | remove("scala:2.10.3"); 73 | remove("scala:2.9.3"); 74 | 75 | # base 76 | skip("base"); 77 | 78 | # function to remove Docker images and print out 79 | # the result. If image removal fails, we'll print 80 | # out the stderr. 81 | sub remove { 82 | $name=$_[0]; 83 | 84 | @result = `docker rmi bradrydzewski/$name 2>&1`; 85 | if ( $? == 0 ) 86 | { 87 | print "\033[32m ✓ REMOVED\033[0m $name\n"; 88 | } 89 | else 90 | { 91 | print "\033[31m ✗ FAILURE\033[0m $name\n"; 92 | } 93 | } 94 | 95 | sub skip { 96 | $name=$_[0]; 97 | print "\033[33m – SKIPPED\033[0m $name\n"; 98 | } 99 | -------------------------------------------------------------------------------- /builder/clojure/lein/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN wget https://raw.github.com/technomancy/leiningen/stable/bin/lein && \ 7 | sudo install -t /usr/local/bin lein && \ 8 | rm lein -------------------------------------------------------------------------------- /builder/dart/dart_dev/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD dart.sh /etc/drone.d/ 5 | 6 | RUN wget http://storage.googleapis.com/dart-archive/channels/dev/release/latest/editor/darteditor-linux-x64.zip --quiet && \ 7 | unzip darteditor-linux-x64 "-d" /home/ubuntu && \ 8 | rm darteditor-linux-x64.zip 9 | 10 | # install content_shell 11 | RUN dart/chromium/download_contentshell.sh && \ 12 | unzip content_shell-linux-x64-release.zip && \ 13 | mv drt-* content_shell && \ 14 | rm content_shell-linux-x64-release.zip -------------------------------------------------------------------------------- /builder/dart/dart_dev/dart.sh: -------------------------------------------------------------------------------- 1 | export DART_SDK=/home/ubuntu/dart/dart-sdk 2 | export PATH=$PATH:$DART_SDK/bin:/home/ubuntu/dart/chromium:/home/ubuntu/content_shell -------------------------------------------------------------------------------- /builder/dart/dart_stable/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD dart.sh /etc/drone.d/ 5 | 6 | RUN wget http://storage.googleapis.com/dart-archive/channels/stable/release/latest/editor/darteditor-linux-x64.zip --quiet && \ 7 | unzip darteditor-linux-x64 "-d" /home/ubuntu && \ 8 | rm darteditor-linux-x64.zip 9 | 10 | # install content_shell 11 | RUN dart/chromium/download_contentshell.sh && \ 12 | unzip content_shell-linux-x64-release.zip && \ 13 | mv drt-* content_shell && \ 14 | rm content_shell-linux-x64-release.zip -------------------------------------------------------------------------------- /builder/dart/dart_stable/dart.sh: -------------------------------------------------------------------------------- 1 | export DART_SDK=/home/ubuntu/dart/dart-sdk 2 | export PATH=$PATH:$DART_SDK/bin:/home/ubuntu/dart/chromium:/home/ubuntu/content_shell -------------------------------------------------------------------------------- /builder/dlang/dmd_2.064.2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN sudo apt-get -qq update 7 | RUN sudo apt-get --assume-yes install gcc-multilib xdg-utils libcurl4-openssl-dev 8 | 9 | RUN wget -q http://downloads.dlang.org/releases/2013/dmd_2.064.2-0_amd64.deb && \ 10 | sudo dpkg -i dmd_2.064.2-0_amd64.deb && \ 11 | rm dmd_2.064.2-0_amd64.deb 12 | 13 | RUN wget -q http://code.dlang.org/files/dub-0.9.20-linux-x86_64.tar.gz && \ 14 | tar -xf dub-0.9.20-linux-x86_64.tar.gz && \ 15 | rm dub-0.9.20-linux-x86_64.tar.gz && \ 16 | sudo mv dub /usr/local/bin/dub 17 | -------------------------------------------------------------------------------- /builder/docker-in-docker/Dockerfile: -------------------------------------------------------------------------------- 1 | # see https://registry.hub.docker.com/u/igneoussystems/docker-client/dockerfile/ 2 | FROM bradrydzewski/go:1.3 3 | MAINTAINER udzura@udzura.jp 4 | 5 | RUN sudo apt-get install -y aufs-tools ca-certificates curl git xz-utils 6 | 7 | ENV DOCKER_VERSION 1.3.1 8 | RUN sudo curl -SL https://get.docker.io/builds/Linux/x86_64/docker-$DOCKER_VERSION -o /usr/bin/docker \ 9 | && sudo chmod +x /usr/bin/docker 10 | 11 | # Total hack since this is typically a client looking at the host 12 | ENV DOCKER_HOST tcp://172.17.42.1:2375 13 | -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B02/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R14B02 R14B02 && \ 8 | sudo mkdir /opt/R14B02 && \ 9 | sudo chown -R 1000:1000 /opt/R14B02 && \ 10 | kerl install R14B02 /opt/R14B02 -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B02/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R15B02/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B03/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R14B03 R14B03 && \ 8 | sudo mkdir /opt/R14B03 && \ 9 | sudo chown -R 1000:1000 /opt/R14B03 && \ 10 | kerl install R14B03 /opt/R14B03 -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B03/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R14B03/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B04/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R14B04 R14B04 && \ 8 | sudo mkdir /opt/R14B04 && \ 9 | sudo chown -R 1000:1000 /opt/R14B04 && \ 10 | kerl install R14B04 /opt/R14B04 -------------------------------------------------------------------------------- /builder/erlang/erlang_R14B04/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R14B04/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R15B R15B && \ 8 | sudo mkdir /opt/R15B && \ 9 | sudo chown -R 1000:1000 /opt/R15B && \ 10 | kerl install R15B /opt/R15B -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R15B/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B01/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R15B01 R15B01 && \ 8 | sudo mkdir /opt/R15B01 && \ 9 | sudo chown -R 1000:1000 /opt/R15B01 && \ 10 | kerl install R15B01 /opt/R15B01 -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B01/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R15B01/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B02/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R15B02 R15B02 && \ 8 | sudo mkdir /opt/R15B02 && \ 9 | sudo chown -R 1000:1000 /opt/R15B02 && \ 10 | kerl install R15B02 /opt/R15B02 -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B02/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R15B02/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B03/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R15B03 R15B03 && \ 8 | sudo mkdir /opt/R15B03 && \ 9 | sudo chown -R 1000:1000 /opt/R15B03 && \ 10 | kerl install R15B03 /opt/R15B03 -------------------------------------------------------------------------------- /builder/erlang/erlang_R15B03/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R15B03/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R16B R16B && \ 8 | sudo mkdir /opt/R16B && \ 9 | sudo chown -R 1000:1000 /opt/R16B && \ 10 | kerl install R16B /opt/R16B -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R16B/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B01/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R16B01 R16B01 && \ 8 | sudo mkdir /opt/R16B01 && \ 9 | sudo chown -R 1000:1000 /opt/R16B01 && \ 10 | kerl install R16B01 /opt/R16B01 -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B01/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R16B01/activate -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B02/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/kerl 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD kerl.sh /etc/drone.d/ 6 | 7 | RUN kerl build R16B02 R16B02 && \ 8 | sudo mkdir /opt/R16B02 && \ 9 | sudo chown -R 1000:1000 /opt/R16B02 && \ 10 | kerl install R16B02 /opt/R16B02 -------------------------------------------------------------------------------- /builder/erlang/erlang_R16B02/kerl.sh: -------------------------------------------------------------------------------- 1 | . /opt/R16B02/activate -------------------------------------------------------------------------------- /builder/erlang/kerl/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | USER ubuntu 3 | WORKDIR /home/ubuntu 4 | 5 | # install rebar 6 | RUN wget https://github.com/rebar/rebar/wiki/rebar && \ 7 | sudo install -t /usr/local/bin rebar && \ 8 | rm rebar 9 | 10 | # install kerl 11 | RUN curl -O https://raw.github.com/spawngrid/kerl/master/kerl && \ 12 | sudo install -t /usr/local/bin kerl && \ 13 | rm kerl -------------------------------------------------------------------------------- /builder/gcc/gcc_4.6/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN sudo apt-get -qq update && \ 7 | sudo apt-get --assume-yes install libtiff4-dev libpng-dev libjpeg-dev ffmpeg freeglut3-dev libfreetype6-dev && \ 8 | 9 | sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test && \ 10 | sudo apt-get -qq update && \ 11 | sudo apt-get --assume-yes install gcc-4.6 && \ 12 | sudo apt-get --assume-yes install g++-4.6 -------------------------------------------------------------------------------- /builder/gcc/gcc_4.8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN sudo apt-get -qq update && \ 7 | sudo apt-get --assume-yes install libtiff4-dev libpng-dev libjpeg-dev ffmpeg freeglut3-dev libfreetype6-dev && \ 8 | 9 | sudo add-apt-repository --yes ppa:ubuntu-toolchain-r/test && \ 10 | sudo apt-get -qq update && \ 11 | sudo apt-get --assume-yes install gcc-4.8 && \ 12 | sudo apt-get --assume-yes install g++-4.8 && \ 13 | 14 | sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 60 --slave /usr/bin/g++ g++ /usr/bin/g++-4.6 && \ 15 | sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.8 40 --slave /usr/bin/g++ g++ /usr/bin/g++-4.8 && \ 16 | echo 2 | sudo update-alternatives --config gcc -------------------------------------------------------------------------------- /builder/golang/go_1.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD golang.sh /etc/drone.d/ 5 | RUN wget http://go.googlecode.com/files/go1.0.3.linux-amd64.tar.gz --quiet && \ 6 | sudo tar -C /usr/local -xzf go1.0.3.linux-amd64.tar.gz && \ 7 | sudo chown -R ubuntu:ubuntu /usr/local/go && \ 8 | rm go1.0.3.linux-amd64.tar.gz -------------------------------------------------------------------------------- /builder/golang/go_1.0/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/local/go 3 | export GOPATH=/var/cache/drone 4 | export PATH=$PATH:$GOROOT/bin 5 | 6 | #[ -d $GOPATH/src ] || mkdir -p $GOPATH/src 7 | #[ -d $GOPATH/pkg ] || mkdir -p $GOPATH/pkg 8 | #[ -d $GOPATH/bin ] || mkdir -p $GOPATH/bin -------------------------------------------------------------------------------- /builder/golang/go_1.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD golang.sh /etc/drone.d/ 5 | RUN wget http://go.googlecode.com/files/go1.1.2.linux-amd64.tar.gz --quiet && \ 6 | sudo tar -C /usr/local -xzf go1.1.2.linux-amd64.tar.gz && \ 7 | sudo chown -R ubuntu:ubuntu /usr/local/go && \ 8 | rm go1.1.2.linux-amd64.tar.gz -------------------------------------------------------------------------------- /builder/golang/go_1.1/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/local/go 3 | export GOPATH=/var/cache/drone 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/golang/go_1.2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD golang.sh /etc/drone.d/ 5 | RUN wget http://go.googlecode.com/files/go1.2.linux-amd64.tar.gz --quiet && \ 6 | sudo tar -C /usr/local -xzf go1.2.linux-amd64.tar.gz && \ 7 | sudo chown -R ubuntu:ubuntu /usr/local/go && \ 8 | rm go1.2.linux-amd64.tar.gz -------------------------------------------------------------------------------- /builder/golang/go_1.2/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/local/go 3 | export GOPATH=/var/cache/drone 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/golang/go_1.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD golang.sh /etc/drone.d/ 5 | RUN wget http://golang.org/dl/go1.3.linux-amd64.tar.gz --quiet && \ 6 | sudo tar -C /usr/local -xzf go1.3.linux-amd64.tar.gz && \ 7 | sudo chown -R ubuntu:ubuntu /usr/local/go && \ 8 | rm go1.3.linux-amd64.tar.gz 9 | -------------------------------------------------------------------------------- /builder/golang/go_1.3/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/local/go 3 | export GOPATH=/var/cache/drone 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/golang/go_1.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ENV GOVERSION 1.4.1 5 | ADD golang.sh /etc/drone.d/ 6 | RUN wget http://golang.org/dl/go$GOVERSION.linux-amd64.tar.gz --quiet && \ 7 | sudo tar -C /usr/local -xzf go$GOVERSION.linux-amd64.tar.gz && \ 8 | sudo chown -R ubuntu:ubuntu /usr/local/go && \ 9 | rm go$GOVERSION.linux-amd64.tar.gz 10 | -------------------------------------------------------------------------------- /builder/golang/go_1.4/golang.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/local/go 3 | export GOPATH=/var/cache/drone 4 | export PATH=$PATH:$GOROOT/bin -------------------------------------------------------------------------------- /builder/golang/go_gae/.dronerc: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/lib/go 3 | export GOPATH=/home/ubuntu 4 | export PATH=$PATH:$GOROOT/bin 5 | 6 | [ -d $GOPATH/src ] || mkdir -p $GOPATH/src 7 | [ -d $GOPATH/pkg ] || mkdir -p $GOPATH/pkg 8 | [ -d $GOPATH/bin ] || mkdir -p $GOPATH/bin 9 | 10 | # enable ruby support via rbenv 11 | 12 | # enable python support via virtualenv 13 | 14 | # enable nodejs support via nvm 15 | 16 | # enable java support via JAVA_HOME, MAVEN_HOME, etc -------------------------------------------------------------------------------- /builder/golang/go_gae/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | USER ubuntu 3 | ADD .dronerc /home/ubuntu/ -------------------------------------------------------------------------------- /builder/haskell/haskell_7.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN sudo apt-get -qq update && \ 7 | sudo apt-get install haskell-platform && \ 8 | cabal update && \ 9 | cabal install hunit c2hs -------------------------------------------------------------------------------- /builder/java/java_openjdk6/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ENV JAVA_HOME /usr/lib/jvm/java-6-openjdk-amd64 6 | 7 | RUN sudo apt-get -y install openjdk-6-jdk default-jdk && \ 8 | sudo apt-get -y install ant ant-contrib ivy maven gradle && \ 9 | sudo update-java-alternatives -s java-1.6.0-openjdk-amd64 2> /dev/null -------------------------------------------------------------------------------- /builder/java/java_openjdk7/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ENV JAVA_HOME /usr/lib/jvm/java-7-openjdk-amd64 6 | 7 | RUN sudo apt-get -y install openjdk-7-jdk default-jdk && \ 8 | sudo apt-get -y install ant ant-contrib ivy maven gradle && \ 9 | sudo update-java-alternatives -s java-1.7.0-openjdk-amd64 2> /dev/null -------------------------------------------------------------------------------- /builder/java/java_oraclejdk7/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ENV JAVA_HOME /usr/lib/jvm/java-7-oracle 6 | 7 | RUN sudo add-apt-repository --yes ppa:webupd8team/java && \ 8 | sudo apt-get -qq update && \ 9 | echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections && \ 10 | sudo apt-get -y install oracle-java7-installer && \ 11 | sudo apt-get -y install oracle-java7-set-default 12 | -------------------------------------------------------------------------------- /builder/java/java_oraclejdk8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ENV JAVA_HOME /usr/lib/jvm/java-8-oracle 6 | 7 | RUN sudo add-apt-repository --yes ppa:webupd8team/java && \ 8 | sudo apt-get -qq update && \ 9 | echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections && \ 10 | sudo apt-get -y install oracle-java8-installer && \ 11 | sudo apt-get -y install oracle-java8-set-default -------------------------------------------------------------------------------- /builder/node/node_0.10/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD nodejs.sh /etc/drone.d/ 6 | 7 | # we currently install node 10.22 in the base image 8 | # so we'll comment this out for now 9 | #RUN /bin/bash -c ". /home/ubuntu/nvm/nvm.sh && nvm install v0.10.22" -------------------------------------------------------------------------------- /builder/node/node_0.10/nodejs.sh: -------------------------------------------------------------------------------- 1 | . /home/ubuntu/nvm/nvm.sh 2 | nvm use v0.10.22 -------------------------------------------------------------------------------- /builder/node/node_0.8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD nodejs.sh /etc/drone.d/ 6 | 7 | RUN /bin/bash -c ". /home/ubuntu/nvm/nvm.sh && nvm install v0.8.26" -------------------------------------------------------------------------------- /builder/node/node_0.8/nodejs.sh: -------------------------------------------------------------------------------- 1 | . /home/ubuntu/nvm/nvm.sh 2 | nvm use v0.8.26 -------------------------------------------------------------------------------- /builder/node/nvm/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | 5 | RUN git clone git://github.com/creationix/nvm.git /home/ubuntu/nvm && \ 6 | chown -R ubuntu:ubuntu /home/ubuntu/nvm -------------------------------------------------------------------------------- /builder/php/php_5.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/phpenv 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD phpenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.phpenv/bin && \ 8 | php-build -i development --pear 5.3.27 /home/ubuntu/.phpenv/versions/5.3.27 && \ 9 | sed -i 's/128M/512M/' /home/ubuntu/.phpenv/versions/5.3.27/etc/php.ini && \ 10 | phpenv init - && \ 11 | phpenv rehash && \ 12 | phpenv global 5.3.27 && \ 13 | curl -sS https://getcomposer.org/installer | php && \ 14 | sudo mv composer.phar /usr/local/bin/composer && \ 15 | sudo chmod +x /usr/local/bin/composer && \ 16 | sudo pear channel-discover pear.phpunit.de && \ 17 | sudo pear channel-discover pear.symfony.com && \ 18 | sudo pear channel-discover pear.symfony-project.com && \ 19 | sudo pear channel-discover components.ez.no && \ 20 | sudo pear config-set auto_discover 1 && \ 21 | sudo pear install --alldeps pear.phpunit.de/PHPUnit && \ 22 | sudo pecl -q install mongo && \ 23 | sudo echo "extension=mongo.so" | sudo tee /home/ubuntu/.phpenv/versions/5.3.27/etc/php.ini -------------------------------------------------------------------------------- /builder/php/php_5.3/phpenv.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/home/ubuntu/.phpenv/bin 2 | phpenv init - 3 | phpenv global 5.3.27 4 | -------------------------------------------------------------------------------- /builder/php/php_5.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/phpenv 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD phpenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.phpenv/bin && \ 8 | php-build -i development --pear 5.4.22 /home/ubuntu/.phpenv/versions/5.4.22 && \ 9 | sed -i 's/128M/512M/' /home/ubuntu/.phpenv/versions/5.4.22/etc/php.ini && \ 10 | phpenv init - && \ 11 | phpenv rehash && \ 12 | phpenv global 5.4.22 && \ 13 | curl -sS https://getcomposer.org/installer | php && \ 14 | sudo mv composer.phar /usr/local/bin/composer && \ 15 | sudo chmod +x /usr/local/bin/composer && \ 16 | sudo pear channel-discover pear.phpunit.de && \ 17 | sudo pear channel-discover pear.symfony.com && \ 18 | sudo pear channel-discover pear.symfony-project.com && \ 19 | sudo pear channel-discover components.ez.no && \ 20 | sudo pear config-set auto_discover 1 && \ 21 | sudo pear install --alldeps pear.phpunit.de/PHPUnit && \ 22 | sudo pecl -q install mongo && \ 23 | sudo echo "extension=mongo.so" | sudo tee /home/ubuntu/.phpenv/versions/5.4.22/etc/php.ini -------------------------------------------------------------------------------- /builder/php/php_5.4/phpenv.sh: -------------------------------------------------------------------------------- 1 | # enable go language support 2 | export GOROOT=/usr/lib/go 3 | export GOPATH=/home/ubuntu 4 | export PATH=$PATH:$GOROOT/bin 5 | 6 | [ -d $GOPATH/src ] || mkdir -p $GOPATH/src 7 | [ -d $GOPATH/pkg ] || mkdir -p $GOPATH/pkg 8 | [ -d $GOPATH/bin ] || mkdir -p $GOPATH/bin 9 | 10 | # enable ruby support via rbenv 11 | 12 | # enable python support via virtualenv 13 | 14 | # enable nodejs support via nvm 15 | 16 | # enable java support via JAVA_HOME, MAVEN_HOME, etc 17 | 18 | 19 | # add phpenv to the path 20 | export PATH=$PATH:/home/ubuntu/.phpenv/bin 21 | phpenv init - 22 | phpenv global 5.4.22 23 | -------------------------------------------------------------------------------- /builder/php/php_5.5/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/phpenv 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD phpenv.sh /etc/drone.d/ 6 | ENV HOME /home/ubuntu 7 | 8 | # install default php version 9 | RUN export PATH=$PATH:/home/ubuntu/.phpenv/bin && \ 10 | php-build -i development --pear 5.5.6 /home/ubuntu/.phpenv/versions/5.5.6 && \ 11 | sed -i 's/128M/512M/' /home/ubuntu/.phpenv/versions/5.5.6/etc/php.ini && \ 12 | phpenv init - && \ 13 | phpenv rehash && \ 14 | phpenv global 5.5.6 && \ 15 | curl -sS https://getcomposer.org/installer | php && \ 16 | sudo mv composer.phar /usr/local/bin/composer && \ 17 | sudo chmod +x /usr/local/bin/composer && \ 18 | sudo pear channel-discover pear.phpunit.de && \ 19 | sudo pear channel-discover pear.symfony.com && \ 20 | sudo pear channel-discover pear.symfony-project.com && \ 21 | sudo pear channel-discover components.ez.no && \ 22 | sudo pear config-set auto_discover 1 && \ 23 | sudo pear install --alldeps pear.phpunit.de/PHPUnit && \ 24 | sudo pecl -q install mongo && \ 25 | sudo echo "extension=mongo.so" | sudo tee /home/ubuntu/.phpenv/versions/5.5.6/etc/php.ini -------------------------------------------------------------------------------- /builder/php/php_5.5/phpenv.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/home/ubuntu/.phpenv/bin 2 | phpenv init - 3 | phpenv global 5.5.6 4 | -------------------------------------------------------------------------------- /builder/php/phpenv/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD phpenv.sh /etc/drone.d/ 5 | ENV HOME /home/ubuntu 6 | 7 | # install apt dependencies 8 | RUN sudo add-apt-repository -y ppa:ondrej/php5 && \ 9 | sudo apt-get -qq update && \ 10 | sudo apt-get install php5-dev php5 php5-xdebug php-pear && \ 11 | sudo apt-get install libmcrypt-dev libtidy-dev re2c php5-curl php5-gd php5-intl php5-xmlrpc php5-mcrypt php5-mysql php5-pgsql php5-sqlite php5-tidy 12 | 13 | # install phpbuild 14 | RUN git clone git://github.com/CHH/php-build.git && \ 15 | sudo php-build/install.sh && \ 16 | sudo chown -R ubuntu:ubuntu /usr/local/share/php-build && \ 17 | rm -rf php-build/ 18 | 19 | # install phpenv 20 | RUN git clone https://github.com/CHH/phpenv.git && \ 21 | phpenv/bin/phpenv-install.sh && \ 22 | rm -rf phpenv/ -------------------------------------------------------------------------------- /builder/php/phpenv/phpenv.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/home/ubuntu/.phpenv/bin 2 | phpenv init - 3 | -------------------------------------------------------------------------------- /builder/python/pypy/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install pypy 7 | RUN sudo add-apt-repository --yes ppa:pypy/ppa && \ 8 | sudo apt-get -qq update && \ 9 | sudo apt-get install pypy 10 | 11 | # setup default virtualenv for pypy 12 | RUN virtualenv --python=/usr/bin/pypy /home/ubuntu/virtualenv/pypy && \ 13 | . /home/ubuntu/virtualenv/pypy/bin/activate && \ 14 | pip install --use-mirrors nose && \ 15 | pip install -U pytest -------------------------------------------------------------------------------- /builder/python/pypy/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/pypy/bin/activate -------------------------------------------------------------------------------- /builder/python/python_2.6/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install python 2.6 7 | RUN sudo apt-get update && sudo apt-get install python2.6 python2.6-dev 8 | 9 | # setup default virtualenv for python 2.6 10 | RUN virtualenv --python=/usr/bin/python2.6 /home/ubuntu/virtualenv/python2.6 --system-site-packages && \ 11 | . /home/ubuntu/virtualenv/python2.6/bin/activate && \ 12 | pip install --use-mirrors nose && \ 13 | pip install -U pytest -------------------------------------------------------------------------------- /builder/python/python_2.6/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/python2.6/bin/activate -------------------------------------------------------------------------------- /builder/python/python_2.7/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install python 2.7 7 | RUN sudo apt-get update && sudo apt-get install python2.7 python2.7-dev 8 | 9 | # setup default virtualenv for python 2.7 10 | RUN virtualenv --python=/usr/bin/python2.7 /home/ubuntu/virtualenv/python2.7 --system-site-packages && \ 11 | . /home/ubuntu/virtualenv/python2.7/bin/activate && \ 12 | pip install --use-mirrors nose && \ 13 | pip install -U pytest -------------------------------------------------------------------------------- /builder/python/python_2.7/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/python2.7/bin/activate -------------------------------------------------------------------------------- /builder/python/python_3.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install python 3.1 7 | RUN sudo apt-get update && sudo apt-get install python3.1 python3.1-dev 8 | 9 | # setup default virtualenv for python 3.1 10 | RUN virtualenv --python=/usr/bin/python3.1 /home/ubuntu/virtualenv/python3.1 --system-site-packages 11 | 12 | # NOTE: pypi seems to be incompatible with 3.1, so we don't pre-install any software -------------------------------------------------------------------------------- /builder/python/python_3.1/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/python3.1/bin/activate -------------------------------------------------------------------------------- /builder/python/python_3.2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install python 3.2 7 | RUN sudo apt-get update && sudo apt-get install python3.2 python3.2-dev 8 | 9 | # setup default virtualenv for python 3.2 10 | RUN virtualenv --python=/usr/bin/python3.2 /home/ubuntu/virtualenv/python3.2 --system-site-packages && \ 11 | . /home/ubuntu/virtualenv/python3.2/bin/activate && \ 12 | pip install --use-mirrors nose && \ 13 | pip install -U pytest -------------------------------------------------------------------------------- /builder/python/python_3.2/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/python3.2/bin/activate -------------------------------------------------------------------------------- /builder/python/python_3.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/virtualenv 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | ADD python.sh /etc/drone.d/ 5 | 6 | # install python 3.3 7 | RUN sudo apt-get update && sudo apt-get install python3.3 python3.3-dev 8 | 9 | # setup default virtualenv for python 3.3 10 | RUN virtualenv --python=/usr/bin/python3.3 /home/ubuntu/virtualenv/python3.3 --system-site-packages && \ 11 | . /home/ubuntu/virtualenv/python3.3/bin/activate && \ 12 | pip install --use-mirrors nose && \ 13 | pip install -U pytest -------------------------------------------------------------------------------- /builder/python/python_3.3/python.sh: -------------------------------------------------------------------------------- 1 | source /home/ubuntu/virtualenv/python3.3/bin/activate -------------------------------------------------------------------------------- /builder/python/virtualenv/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | 5 | RUN sudo easy_install virtualenv && \ 6 | sudo add-apt-repository --yes ppa:fkrull/deadsnakes && \ 7 | mkdir -p /home/ubuntu/virtualenv -------------------------------------------------------------------------------- /builder/rlang/rlang/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | 6 | RUN echo 'deb http://cran.cnr.Berkeley.edu/bin/linux/ubuntu precise/' | sudo tee -a /etc/apt/sources.list && \ 7 | sudo apt-get update && \ 8 | sudo apt-get install r-base && sudo apt-get install r-base-dev 9 | -------------------------------------------------------------------------------- /builder/ruby/jruby_1.7.11_openjdk6/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/java:openjdk6 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 8 | cd ~/.rbenv/plugins/ruby-build && \ 9 | git pull && \ 10 | export RBENV_VERSION=jruby-1.7.11 && \ 11 | eval "$(rbenv init -)" && \ 12 | rbenv install jruby-1.7.11 && \ 13 | rbenv rehash && \ 14 | rbenv global jruby-1.7.11 && \ 15 | rbenv rehash && \ 16 | gem install bundler && \ 17 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/jruby_1.7.11_openjdk6/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=jruby-1.7.11 6 | export RAILS_ENV=test 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global jruby-1.7.11 -------------------------------------------------------------------------------- /builder/ruby/jruby_1.7.11_openjdk7/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/java:openjdk7 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 8 | cd ~/.rbenv/plugins/ruby-build && \ 9 | git pull && \ 10 | export RBENV_VERSION=jruby-1.7.11 && \ 11 | eval "$(rbenv init -)" && \ 12 | rbenv install jruby-1.7.11 && \ 13 | rbenv rehash && \ 14 | rbenv global jruby-1.7.11 && \ 15 | rbenv rehash && \ 16 | gem install bundler && \ 17 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/jruby_1.7.11_openjdk7/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=jruby-1.7.11 6 | export RAILS_ENV=test 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global jruby-1.7.11 -------------------------------------------------------------------------------- /builder/ruby/rbenv/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | WORKDIR /home/ubuntu 3 | USER ubuntu 4 | 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | RUN git clone git://github.com/sstephenson/rbenv.git /home/ubuntu/.rbenv && \ 8 | git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build -------------------------------------------------------------------------------- /builder/ruby/rbenv/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RAILS_ENV=${RAILS_ENV:-test} 6 | 7 | # initialize and set ruby version 8 | eval "$(rbenv init -)" 9 | -------------------------------------------------------------------------------- /builder/ruby/ruby_1.9.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 8 | export RBENV_VERSION=1.9.3-p484 && \ 9 | eval "$(rbenv init -)" && \ 10 | CC=gcc rbenv install 1.9.3-p484 && \ 11 | rbenv rehash && \ 12 | rbenv global 1.9.3-p484 && \ 13 | rbenv rehash && \ 14 | gem install bundler && \ 15 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/ruby_1.9.3/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=1.9.3-p484 6 | export RAILS_ENV=${RAILS_ENV:-test} 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global 1.9.3-p484 11 | -------------------------------------------------------------------------------- /builder/ruby/ruby_2.0.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | # we already install ruby 2.0.0 in the base image 8 | # so we'll comment this out for now 9 | #RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 10 | # export RBENV_VERSION=2.0.0-p353 && \ 11 | # eval "$(rbenv init -)" && \ 12 | # CC=gcc rbenv install 2.0.0-p353 && \ 13 | # rbenv rehash && \ 14 | # rbenv global 2.0.0-p353 && \ 15 | # rbenv rehash && \ 16 | # gem install bundler && \ 17 | # rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/ruby_2.0.0/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=2.0.0-p353 6 | export RAILS_ENV=${RAILS_ENV:-test} 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global 2.0.0-p353 11 | -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | # we already install ruby 2.1.0 in the base image 8 | # so we'll comment this out for now 9 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 10 | cd ~/.rbenv/plugins/ruby-build && \ 11 | git pull && \ 12 | export RBENV_VERSION=2.1.0 && \ 13 | eval "$(rbenv init -)" && \ 14 | CC=gcc rbenv install 2.1.0 && \ 15 | rbenv rehash && \ 16 | rbenv global 2.1.0 && \ 17 | rbenv rehash && \ 18 | gem install bundler && \ 19 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.0/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=2.1.0-p0 6 | export RAILS_ENV=${RAILS_ENV:-test} 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global 2.1.0-p0 11 | -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | # we already install ruby 2.1.1 in the base image 8 | # so we'll comment this out for now 9 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 10 | cd ~/.rbenv/plugins/ruby-build && \ 11 | git pull && \ 12 | export RBENV_VERSION=2.1.1 && \ 13 | eval "$(rbenv init -)" && \ 14 | CC=gcc rbenv install 2.1.1 && \ 15 | rbenv rehash && \ 16 | rbenv global 2.1.1 && \ 17 | rbenv rehash && \ 18 | gem install bundler && \ 19 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.1/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=2.1.1 6 | export RAILS_ENV=${RAILS_ENV:-test} 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global 2.1.1 11 | -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD rbenv.sh /etc/drone.d/ 6 | 7 | RUN export PATH=$PATH:/home/ubuntu/.rbenv/bin && \ 8 | cd ~/.rbenv/plugins/ruby-build && \ 9 | git pull && \ 10 | export RBENV_VERSION=2.1.4 && \ 11 | eval "$(rbenv init -)" && \ 12 | CC=gcc rbenv install 2.1.4 && \ 13 | rbenv rehash && \ 14 | rbenv global 2.1.4 && \ 15 | rbenv rehash && \ 16 | gem install bundler && \ 17 | rbenv rehash -------------------------------------------------------------------------------- /builder/ruby/ruby_2.1.4/rbenv.sh: -------------------------------------------------------------------------------- 1 | # add rbenv to path 2 | export PATH="/home/ubuntu/.rbenv/bin:$PATH" 3 | 4 | # set default env vars 5 | export RBENV_VERSION=2.1.4 6 | export RAILS_ENV=${RAILS_ENV:-test} 7 | 8 | # initialize and set ruby version 9 | eval "$(rbenv init -)" 10 | rbenv global 2.1.4 11 | -------------------------------------------------------------------------------- /builder/scala/scala_2.10.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD scala.sh /etc/drone.d/ 6 | 7 | RUN wget http://repo.scala-sbt.org/scalasbt/sbt-native-packages/org/scala-sbt/sbt/0.13.0/sbt.deb && \ 8 | sudo dpkg -i sbt.deb && \ 9 | rm sbt.deb && \ 10 | 11 | wget http://www.scala-lang.org/files/archive/scala-2.10.3.tgz && \ 12 | sudo tar -xzf scala-2.10.3.tgz && \ 13 | sudo mv scala-2.10.3 /opt/scala-2.10.3 && \ 14 | sudo chown -R ubuntu:ubuntu /opt/scala-2.10.3 15 | -------------------------------------------------------------------------------- /builder/scala/scala_2.10.3/scala.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/opt/scala-2.10.3/bin 2 | export JAVA_HOME=/usr/lib/jvm/default-java -------------------------------------------------------------------------------- /builder/scala/scala_2.9.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/base 2 | 3 | WORKDIR /home/ubuntu 4 | USER ubuntu 5 | ADD scala.sh /etc/drone.d/ 6 | 7 | RUN wget http://repo.scala-sbt.org/scalasbt/sbt-native-packages/org/scala-sbt/sbt/0.13.0/sbt.deb && \ 8 | sudo dpkg -i sbt.deb && \ 9 | rm sbt.deb && \ 10 | 11 | wget http://www.scala-lang.org/files/archive/scala-2.9.3.tgz && \ 12 | sudo tar -xzf scala-2.9.3.tgz && \ 13 | sudo mv scala-2.9.3 /opt/scala-2.9.3 && \ 14 | sudo chown -R ubuntu:ubuntu /opt/scala-2.9.3 15 | -------------------------------------------------------------------------------- /builder/scala/scala_2.9.3/scala.sh: -------------------------------------------------------------------------------- 1 | export PATH=$PATH:/opt/scala-2.9.3/bin 2 | export JAVA_HOME=/usr/lib/jvm/default-java -------------------------------------------------------------------------------- /builder/setup: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | 3 | # base 4 | skip("base", "base/"); 5 | 6 | # clojure 7 | build("lein", "clojure/lein/"); 8 | 9 | # dart 10 | build("dart:stable", "dart/dart_stable/"); 11 | build("dart:dev", "dart/dart_dev/"); 12 | 13 | # dlang 14 | build("dmd:2.064.2", "dlang/dmd_2.064.2/"); 15 | 16 | # rlang 17 | build("rlang:rlang", "rlang/rlang/"); 18 | 19 | # erlang 20 | build("kerl", "erlang/kerl/"); 21 | build("erlang:R16B", "erlang/erlang_R16B/"); 22 | build("erlang:R16B02", "erlang/erlang_R16B02/"); 23 | build("erlang:R16B01", "erlang/erlang_R16B01/"); 24 | skip("erlang:R15B", "erlang/erlang_R15B/"); 25 | skip("erlang:R15B03", "erlang/erlang_R15B03/"); 26 | skip("erlang:R15B02", "erlang/erlang_R15B02/"); 27 | skip("erlang:R15B01", "erlang/erlang_R15B01/"); 28 | 29 | # gcc 30 | build("gcc:4.6", "gcc/gcc_4.6/"); 31 | build("gcc:4.8", "gcc/gcc_4.8/"); 32 | 33 | # golang 34 | build("go:1.2", "golang/go_1.2/"); 35 | build("go:1.1", "golang/go_1.1/"); 36 | build("go:1.0", "golang/go_1.0/"); 37 | 38 | # groovy 39 | skip("groovy", "groovy/groovy/"); 40 | 41 | # haskell 42 | build("haskell:7.4", "haskell/haskell_7.4/"); 43 | 44 | # java 45 | build("java:openjdk6", "java/java_openjdk6/"); 46 | build("java:openjdk7", "java/java_openjdk7/"); 47 | build("java:oraclejdk7", "java/java_oraclejdk7/"); 48 | build("java:oraclejdk8", "java/java_oraclejdk8/"); 49 | skip("java:android", "java/android/"); 50 | 51 | # node 52 | build("node:0.10", "node/node_0.10/"); 53 | build("node:0.8", "node/node_0.8/"); 54 | 55 | # php 56 | build("phpenv", "php/phpenv"); 57 | build("php:5.4", "php/php_5.4/"); 58 | build("php:5.5", "php/php_5.5/"); 59 | 60 | # python 61 | build("virtualenv", "python/virtualenv"); 62 | build("python:2.7", "python/python_2.7/"); 63 | build("python:3.2", "python/python_3.2/"); 64 | build("python:3.3", "python/python_3.3/"); 65 | build("python:pypy", "python/pypy/"); 66 | 67 | # ruby 68 | build("ruby:1.9.3", "ruby/ruby_1.9.3/"); 69 | build("ruby:2.0.0", "ruby/ruby_2.0.0/"); 70 | build("ruby:2.1.0", "ruby/ruby_2.1.0/"); 71 | build("ruby:2.1.1", "ruby/ruby_2.1.1/"); 72 | build("jruby:1.7.11-openjdk6", "ruby/jruby_1.7.11_openjdk6/"); 73 | build("jruby:1.7.11-openjdk7", "ruby/jruby_1.7.11_openjdk7/"); 74 | 75 | # scala 76 | build("scala:2.10.3", "scala/scala_2.10.3/"); 77 | build("scala:2.9.3", "scala/scala_2.9.3/"); 78 | 79 | 80 | # function to create Docker images and print out 81 | # the result. If image creation fails, we'll print 82 | # out the stderr. 83 | sub build { 84 | $name=$_[0]; 85 | $path=$_[1]; 86 | 87 | @result = `docker build -rm -t bradrydzewski/$name $path 2>&1`; 88 | if ( $? == 0 ) 89 | { 90 | print "\033[32m ✓ CREATED\033[0m $name\n"; 91 | } 92 | else 93 | { 94 | # print only the last 50 lines of a failed 95 | # container build. 96 | print @result[-50 .. -1]; 97 | print "\033[31m ✗ FAILURE\033[0m $name\n"; 98 | } 99 | 100 | # docker doesn't seem to exit with an error code 101 | # if the Dockerfile fails to create an image. 102 | # so let's proactively check to see if it exists. 103 | `docker images | grep bradrydzewski/$name 2>&1`; 104 | if ( $? == 1 ) 105 | { 106 | print @result[-50 .. -1]; 107 | print "\033[31m ✗ FAILURE\033[0m $name\n"; 108 | } 109 | } 110 | 111 | sub skip { 112 | $name=$_[0]; 113 | $path=$_[1]; 114 | print "\033[33m – SKIPPED\033[0m $name\n"; 115 | } 116 | -------------------------------------------------------------------------------- /database/couchdb/couchdb_1.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN echo "deb http://archive.ubuntu.com/ubuntu precise main" >> /etc/apt/sources.list && \ 3 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates main" >> /etc/apt/sources.list && \ 4 | echo "deb http://security.ubuntu.com/ubuntu precise-security main" >> /etc/apt/sources.list && \ 5 | echo "deb http://archive.ubuntu.com/ubuntu precise universe" >> /etc/apt/sources.list && \ 6 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates universe" >> /etc/apt/sources.list && \ 7 | apt-get -qq update && \ 8 | apt-get install -y couchdb && \ 9 | sed -e 's/^bind_address = .*$/bind_address = 0.0.0.0/' -i /etc/couchdb/default.ini 10 | EXPOSE 5984 11 | ENTRYPOINT "/usr/bin/couchdb" 12 | CMD ["-a", "/etc/couchdb/default.ini", "-a", "/etc/couchdb/local.ini", "-b", "-r", "5", "-p", "/var/run/couchdb/couchdb.pid", "-o", "/dev/null", "-e", "/dev/null", "-R"] 13 | -------------------------------------------------------------------------------- /database/couchdb/couchdb_1.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN echo "deb http://archive.ubuntu.com/ubuntu precise main" >> /etc/apt/sources.list && \ 3 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates main" >> /etc/apt/sources.list && \ 4 | echo "deb http://security.ubuntu.com/ubuntu precise-security main" >> /etc/apt/sources.list && \ 5 | echo "deb http://archive.ubuntu.com/ubuntu precise universe" >> /etc/apt/sources.list && \ 6 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates universe" >> /etc/apt/sources.list && \ 7 | apt-get -qq update && \ 8 | apt-get -y install build-essential libicu-dev libcurl4-gnutls-dev libtool erlang-dev erlang zip libmozjs-dev wget && \ 9 | wget http://apache.mirrors.pair.com/couchdb/source/1.4.0/apache-couchdb-1.4.0.tar.gz && \ 10 | tar xzf apache-couchdb-1.4.0.tar.gz && \ 11 | rm apache-couchdb-1.4.0.tar.gz && \ 12 | cd apache-couchdb-1.4.0 && \ 13 | ./configure && \ 14 | make && \ 15 | make install && \ 16 | cd .. && \ 17 | rm -rf apache-couchdb-1.4.0 && \ 18 | 19 | useradd -d /usr/local/var/lib/couchdb couchdb && \ 20 | chown -R couchdb:couchdb /usr/local/etc/couchdb && \ 21 | chown -R couchdb:couchdb /usr/local/var/lib/couchdb && \ 22 | chown -R couchdb:couchdb /usr/local/var/log/couchdb && \ 23 | chown -R couchdb:couchdb /usr/local/var/run/couchdb && \ 24 | chmod -R 0770 /usr/local/etc/couchdb && \ 25 | chmod -R 0770 /usr/local/var/lib/couchdb && \ 26 | chmod -R 0770 /usr/local/var/log/couchdb && \ 27 | chmod -R 0770 /usr/local/var/run/couchdb && \ 28 | sed -e 's/^bind_address = .*$/bind_address = 0.0.0.0/' -i /usr/local/etc/couchdb/default.ini 29 | EXPOSE 5984 30 | ENTRYPOINT "/usr/local/bin/couchdb" 31 | 32 | # see http://jswiki.lab-01.com/wiki/doku.php?id=install-couch-ubuntu 33 | -------------------------------------------------------------------------------- /database/couchdb/couchdb_1.5/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN echo "deb http://archive.ubuntu.com/ubuntu precise main" >> /etc/apt/sources.list && \ 3 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates main" >> /etc/apt/sources.list && \ 4 | echo "deb http://security.ubuntu.com/ubuntu precise-security main" >> /etc/apt/sources.list && \ 5 | echo "deb http://archive.ubuntu.com/ubuntu precise universe" >> /etc/apt/sources.list && \ 6 | echo "deb http://archive.ubuntu.com/ubuntu precise-updates universe" >> /etc/apt/sources.list && \ 7 | apt-get -qq update && \ 8 | apt-get -y install build-essential libicu-dev libcurl4-gnutls-dev libtool erlang-dev erlang zip libmozjs-dev wget && \ 9 | wget http://apache.mirrors.pair.com/couchdb/source/1.5.0/apache-couchdb-1.5.0.tar.gz && \ 10 | tar xzf apache-couchdb-1.5.0.tar.gz && \ 11 | rm apache-couchdb-1.5.0.tar.gz && \ 12 | cd apache-couchdb-1.5.0 && \ 13 | ./configure && \ 14 | make && \ 15 | make install && \ 16 | cd .. && \ 17 | rm -rf apache-couchdb-1.5.0 && \ 18 | 19 | useradd -d /usr/local/var/lib/couchdb couchdb && \ 20 | chown -R couchdb:couchdb /usr/local/etc/couchdb && \ 21 | chown -R couchdb:couchdb /usr/local/var/lib/couchdb && \ 22 | chown -R couchdb:couchdb /usr/local/var/log/couchdb && \ 23 | chown -R couchdb:couchdb /usr/local/var/run/couchdb && \ 24 | chmod -R 0770 /usr/local/etc/couchdb && \ 25 | chmod -R 0770 /usr/local/var/lib/couchdb && \ 26 | chmod -R 0770 /usr/local/var/log/couchdb && \ 27 | chmod -R 0770 /usr/local/var/run/couchdb && \ 28 | sed -e 's/^bind_address = .*$/bind_address = 0.0.0.0/' -i /usr/local/etc/couchdb/default.ini 29 | EXPOSE 5984 30 | ENTRYPOINT "/usr/local/bin/couchdb" 31 | 32 | # see http://jswiki.lab-01.com/wiki/doku.php?id=install-couch-ubuntu 33 | -------------------------------------------------------------------------------- /database/elasticsearch/elasticsearch_0.20/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && apt-get install -y openjdk-6-jdk wget && \ 3 | wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.20.6.tar.gz && \ 4 | tar xzf elasticsearch-0.20.6.tar.gz && \ 5 | mv elasticsearch-0.20.6 elasticsearch && \ 6 | mv elasticsearch /opt 7 | EXPOSE 9200 8 | ENTRYPOINT ["/opt/elasticsearch/bin/elasticsearch"] 9 | CMD ["-f", "-Xmx2g", "-Xms2g", "-Des.index.store.type=memory"] 10 | -------------------------------------------------------------------------------- /database/elasticsearch/elasticsearch_0.90.8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | 3 | ENV DEBIAN_FRONTEND noninteractive 4 | 5 | RUN apt-get -qq update && apt-get install -y openjdk-6-jdk wget 6 | RUN wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.90.8.tar.gz 7 | RUN tar xzf elasticsearch-0.90.8.tar.gz 8 | RUN mv elasticsearch-0.90.8 /opt/elasticsearch 9 | 10 | EXPOSE 9200 11 | ENTRYPOINT ["/opt/elasticsearch/bin/elasticsearch"] 12 | CMD ["-f", "-Des.index.store.type=memory"] 13 | -------------------------------------------------------------------------------- /database/elasticsearch/elasticsearch_0.90/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && apt-get install -y openjdk-6-jdk wget && \ 3 | wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.90.7.tar.gz && \ 4 | tar xzf elasticsearch-0.90.7.tar.gz && \ 5 | mv elasticsearch-0.90.7 elasticsearch && \ 6 | mv elasticsearch /opt 7 | EXPOSE 9200 8 | ENTRYPOINT ["/opt/elasticsearch/bin/elasticsearch"] 9 | CMD ["-f", "-Des.index.store.type=memory"] 10 | -------------------------------------------------------------------------------- /database/elasticsearch/elasticsearch_1.0.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | 3 | ENV DEBIAN_FRONTEND noninteractive 4 | 5 | RUN apt-get -qq update && apt-get install -y openjdk-6-jdk wget 6 | RUN wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-1.0.1.tar.gz 7 | RUN tar xzf elasticsearch-1.0.1.tar.gz 8 | RUN mv elasticsearch-1.0.1 /opt/elasticsearch 9 | RUN rm elasticsearch-1.0.1.tar.gz 10 | 11 | EXPOSE 9200 12 | ENTRYPOINT ["/opt/elasticsearch/bin/elasticsearch"] 13 | CMD ["-Des.index.store.type=memory"] 14 | # Note that there is no -f flag from the commandline -------------------------------------------------------------------------------- /database/memcached/memcached_1.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu 2 | RUN apt-get -qq update && apt-get -y install gcc make wget libevent-dev && \ 3 | wget --quiet http://memcached.googlecode.com/files/memcached-1.4.15.tar.gz && \ 4 | tar xzf memcached-1.4.15.tar.gz && \ 5 | rm memcached-1.4.15.tar.gz && \ 6 | cd memcached-* && \ 7 | ./configure --prefix=/usr/local && \ 8 | make install && \ 9 | cd .. && rm -rf memcached-* 10 | EXPOSE 11211 11 | ENTRYPOINT ["/usr/local/bin/memcached"] 12 | CMD ["-u", "root", "-m", "64"] 13 | -------------------------------------------------------------------------------- /database/mongodb/mongodb_2.2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && apt-get -y install wget && \ 3 | wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.2.6.tgz && \ 4 | tar xzf mongodb-linux-x86_64-2.2.6.tgz && \ 5 | install -t /usr/bin mongodb-linux-x86_64-2.2.6/bin/* && \ 6 | mkdir -p /data/db /var/lib/mongodb/ && \ 7 | rm mongodb-linux-x86_64-2.2.6.tgz && \ 8 | rm -rf mongodb-linux-x86_64-2.2.6 9 | EXPOSE 27017 10 | ENTRYPOINT ["usr/bin/mongod"] 11 | CMD ["--noprealloc", "--smallfiles"] 12 | 13 | -------------------------------------------------------------------------------- /database/mongodb/mongodb_2.4/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && apt-get -y install wget && \ 3 | wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.4.8.tgz && \ 4 | tar xzf mongodb-linux-x86_64-2.4.8.tgz && \ 5 | install -t /usr/bin mongodb-linux-x86_64-2.4.8/bin/* && \ 6 | mkdir -p /data/db /var/lib/mongodb/ && \ 7 | rm mongodb-linux-x86_64-2.4.8.tgz && \ 8 | rm -rf mongodb-linux-x86_64-2.4.8 9 | EXPOSE 27017 10 | ENTRYPOINT ["usr/bin/mongod"] 11 | CMD ["--noprealloc", "--smallfiles"] 12 | -------------------------------------------------------------------------------- /database/mysql/mysql_5.5-jp/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM bradrydzewski/mysql:5.5 2 | 3 | ENV TZ Asia/Tokyo 4 | -------------------------------------------------------------------------------- /database/mysql/mysql_5.5/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | 3 | # https://github.com/dotcloud/docker/issues/1024 4 | RUN dpkg-divert --local --rename --add /sbin/initctl && \ 5 | ln -s /bin/true /sbin/initctl && \ 6 | apt-get -qq update && \ 7 | DEBIAN_FRONTEND=noninteractive apt-get install -y mysql-server && \ 8 | sed -i -e"s/^bind-address\s*=\s*127.0.0.1/bind-address = 0.0.0.0/" /etc/mysql/my.cnf && \ 9 | /bin/bash -c "/usr/sbin/mysqld &" && \ 10 | sleep 10 && \ 11 | mysql -u root -e 'drop database test' && \ 12 | echo "GRANT ALL ON *.* TO root@'%' IDENTIFIED BY '' WITH GRANT OPTION; FLUSH PRIVILEGES" | mysql 13 | 14 | EXPOSE 3306 15 | ENTRYPOINT "/usr/sbin/mysqld" 16 | -------------------------------------------------------------------------------- /database/neo4j/neo4j_1.9/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | 3 | RUN echo "deb http://archive.ubuntu.com/ubuntu/ precise main restricted" >> /etc/apt/sources.list && \ 4 | echo "deb-src http://archive.ubuntu.com/ubuntu/ precise main restricted" >> /etc/apt/sources.list && \ 5 | echo "deb http://archive.ubuntu.com/ubuntu/ precise universe" >> /etc/apt/sources.list && \ 6 | echo "deb-src http://archive.ubuntu.com/ubuntu/ precise universe" >> /etc/apt/sources.list && \ 7 | 8 | apt-get -qq update && \ 9 | apt-get -y install software-properties-common python-software-properties wget lsof && \ 10 | 11 | add-apt-repository ppa:webupd8team/java && \ 12 | apt-get -qq update && \ 13 | echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections && \ 14 | apt-get -y install oracle-java7-installer && \ 15 | 16 | wget http://dist.neo4j.org/neo4j-community-1.9.5-unix.tar.gz && \ 17 | tar xzf neo4j-community-1.9.5-unix.tar.gz && \ 18 | rm neo4j-community-1.9.5-unix.tar.gz && \ 19 | mv neo4j-community-1.9.5 /opt/neo4j && \ 20 | echo "org.neo4j.server.webserver.address=0.0.0.0" >> /opt/neo4j/conf/neo4j-server.properties 21 | EXPOSE 7474 22 | 23 | ENTRYPOINT ["/bin/bash"] 24 | CMD ["-c", "/opt/neo4j/bin/neo4j console"] 25 | 26 | # see http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html 27 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && \ 3 | LC_ALL=C DEBIAN_FRONTEND=noninteractive apt-get install -y -qq postgresql-9.1 postgresql-contrib-9.1 && \ 4 | mkdir -p /usr/local/pgsql/data 5 | ADD pg_hba.conf /etc/postgresql/9.1/main/pg_hba.conf 6 | ADD postgresql.conf /etc/postgresql/9.1/main/postgresql.conf 7 | #ADD server.key /var/lib/postgresql/9.1/main/server.key 8 | RUN chmod og-rwx /var/lib/postgresql/9.1/main/server.key && chown postgres /var/lib/postgresql/9.1/main/server.key 9 | USER postgres 10 | EXPOSE 5432 11 | ENTRYPOINT ["/usr/lib/postgresql/9.1/bin/postgres", "-D", "/var/lib/postgresql/9.1/main", "-c", "config_file=/etc/postgresql/9.1/main/postgresql.conf", "-c", "listen_addresses=*" ] 12 | 13 | 14 | #ENTRYPOINT ["/bin/bash", "-c", "whoami && /usr/lib/postgresql/9.1/bin/postgres -D /var/lib/postgresql/9.1/main -c config_file=/etc/postgresql/9.1/main/postgresql.conf -c listen_addresses=*" ] 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.1/pg_hba.conf: -------------------------------------------------------------------------------- 1 | host all all 0.0.0.0/0 trust 2 | local all all trust 3 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.1/postgresql.conf: -------------------------------------------------------------------------------- 1 | # ----------------------------- 2 | # PostgreSQL configuration file 3 | # ----------------------------- 4 | # 5 | # This file consists of lines of the form: 6 | # 7 | # name = value 8 | # 9 | # (The "=" is optional.) Whitespace may be used. Comments are introduced with 10 | # "#" anywhere on a line. The complete list of parameter names and allowed 11 | # values can be found in the PostgreSQL documentation. 12 | # 13 | # The commented-out settings shown in this file represent the default values. 14 | # Re-commenting a setting is NOT sufficient to revert it to the default value; 15 | # you need to reload the server. 16 | # 17 | # This file is read on server startup and when the server receives a SIGHUP 18 | # signal. If you edit the file on a running system, you have to SIGHUP the 19 | # server for the changes to take effect, or use "pg_ctl reload". Some 20 | # parameters, which are marked below, require a server shutdown and restart to 21 | # take effect. 22 | # 23 | # Any parameter can also be given as a command-line option to the server, e.g., 24 | # "postgres -c log_connections=on". Some parameters can be changed at run time 25 | # with the "SET" SQL command. 26 | # 27 | # Memory units: kB = kilobytes Time units: ms = milliseconds 28 | # MB = megabytes s = seconds 29 | # GB = gigabytes min = minutes 30 | # h = hours 31 | # d = days 32 | 33 | 34 | #------------------------------------------------------------------------------ 35 | # FILE LOCATIONS 36 | #------------------------------------------------------------------------------ 37 | 38 | # The default values of these variables are driven from the -D command-line 39 | # option or PGDATA environment variable, represented here as ConfigDir. 40 | 41 | data_directory = '/var/lib/postgresql/9.1/main' # use data in another directory 42 | # (change requires restart) 43 | hba_file = '/etc/postgresql/9.1/main/pg_hba.conf' # host-based authentication file 44 | # (change requires restart) 45 | ident_file = '/etc/postgresql/9.1/main/pg_ident.conf' # ident configuration file 46 | # (change requires restart) 47 | 48 | # If external_pid_file is not explicitly set, no extra PID file is written. 49 | external_pid_file = '/var/run/postgresql/9.1-main.pid' # write an extra PID file 50 | # (change requires restart) 51 | 52 | #------------------------------------------------------------------------------ 53 | # CONNECTIONS AND AUTHENTICATION 54 | #------------------------------------------------------------------------------ 55 | 56 | # - Connection Settings - 57 | 58 | #listen_addresses = 'localhost' # what IP address(es) to listen on; 59 | # comma-separated list of addresses; 60 | # defaults to 'localhost', '*' = all 61 | # (change requires restart) 62 | port = 5432 # (change requires restart) 63 | max_connections = 100 # (change requires restart) 64 | # Note: Increasing max_connections costs ~400 bytes of shared memory per 65 | # connection slot, plus lock space (see max_locks_per_transaction). 66 | #superuser_reserved_connections = 3 # (change requires restart) 67 | unix_socket_directory = '/var/run/postgresql' # (change requires restart) 68 | #unix_socket_group = '' # (change requires restart) 69 | #unix_socket_permissions = 0777 # begin with 0 to use octal notation 70 | # (change requires restart) 71 | #bonjour = off # advertise server via Bonjour 72 | # (change requires restart) 73 | #bonjour_name = '' # defaults to the computer name 74 | # (change requires restart) 75 | 76 | # - Security and Authentication - 77 | 78 | #authentication_timeout = 1min # 1s-600s 79 | #ssl = true # (change requires restart) 80 | #ssl_ciphers = 'ALL:!ADH:!LOW:!EXP:!MD5:@STRENGTH' # allowed SSL ciphers 81 | # (change requires restart) 82 | #ssl_renegotiation_limit = 512MB # amount of data between renegotiations 83 | #password_encryption = on 84 | #db_user_namespace = off 85 | 86 | # Kerberos and GSSAPI 87 | #krb_server_keyfile = '' 88 | #krb_srvname = 'postgres' # (Kerberos only) 89 | #krb_caseins_users = off 90 | 91 | # - TCP Keepalives - 92 | # see "man 7 tcp" for details 93 | 94 | #tcp_keepalives_idle = 0 # TCP_KEEPIDLE, in seconds; 95 | # 0 selects the system default 96 | #tcp_keepalives_interval = 0 # TCP_KEEPINTVL, in seconds; 97 | # 0 selects the system default 98 | #tcp_keepalives_count = 0 # TCP_KEEPCNT; 99 | # 0 selects the system default 100 | 101 | #------------------------------------------------------------------------------ 102 | # RESOURCE USAGE (except WAL) 103 | #------------------------------------------------------------------------------ 104 | 105 | # - Memory - 106 | 107 | shared_buffers = 24MB # min 128kB 108 | # (change requires restart) 109 | #temp_buffers = 8MB # min 800kB 110 | #max_prepared_transactions = 0 # zero disables the feature 111 | # (change requires restart) 112 | # Note: Increasing max_prepared_transactions costs ~600 bytes of shared memory 113 | # per transaction slot, plus lock space (see max_locks_per_transaction). 114 | # It is not advisable to set max_prepared_transactions nonzero unless you 115 | # actively intend to use prepared transactions. 116 | #work_mem = 1MB # min 64kB 117 | #maintenance_work_mem = 16MB # min 1MB 118 | #max_stack_depth = 2MB # min 100kB 119 | 120 | # - Kernel Resource Usage - 121 | 122 | #max_files_per_process = 1000 # min 25 123 | # (change requires restart) 124 | #shared_preload_libraries = '' # (change requires restart) 125 | 126 | # - Cost-Based Vacuum Delay - 127 | 128 | #vacuum_cost_delay = 0ms # 0-100 milliseconds 129 | #vacuum_cost_page_hit = 1 # 0-10000 credits 130 | #vacuum_cost_page_miss = 10 # 0-10000 credits 131 | #vacuum_cost_page_dirty = 20 # 0-10000 credits 132 | #vacuum_cost_limit = 200 # 1-10000 credits 133 | 134 | # - Background Writer - 135 | 136 | #bgwriter_delay = 200ms # 10-10000ms between rounds 137 | #bgwriter_lru_maxpages = 100 # 0-1000 max buffers written/round 138 | #bgwriter_lru_multiplier = 2.0 # 0-10.0 multipler on buffers scanned/round 139 | 140 | # - Asynchronous Behavior - 141 | 142 | #effective_io_concurrency = 1 # 1-1000. 0 disables prefetching 143 | 144 | #------------------------------------------------------------------------------ 145 | # WRITE AHEAD LOG 146 | #------------------------------------------------------------------------------ 147 | 148 | # - Settings - 149 | 150 | #wal_level = minimal # minimal, archive, or hot_standby 151 | # (change requires restart) 152 | #fsync = on # turns forced synchronization on or off 153 | #synchronous_commit = on # synchronization level; on, off, or local 154 | #wal_sync_method = fsync # the default is the first option 155 | # supported by the operating system: 156 | # open_datasync 157 | # fdatasync (default on Linux) 158 | # fsync 159 | # fsync_writethrough 160 | # open_sync 161 | #full_page_writes = on # recover from partial page writes 162 | #wal_buffers = -1 # min 32kB, -1 sets based on shared_buffers 163 | # (change requires restart) 164 | #wal_writer_delay = 200ms # 1-10000 milliseconds 165 | 166 | #commit_delay = 0 # range 0-100000, in microseconds 167 | #commit_siblings = 5 # range 1-1000 168 | 169 | # - Checkpoints - 170 | 171 | #checkpoint_segments = 3 # in logfile segments, min 1, 16MB each 172 | #checkpoint_timeout = 5min # range 30s-1h 173 | #checkpoint_completion_target = 0.5 # checkpoint target duration, 0.0 - 1.0 174 | #checkpoint_warning = 30s # 0 disables 175 | 176 | # - Archiving - 177 | 178 | #archive_mode = off # allows archiving to be done 179 | # (change requires restart) 180 | #archive_command = '' # command to use to archive a logfile segment 181 | #archive_timeout = 0 # force a logfile segment switch after this 182 | # number of seconds; 0 disables 183 | 184 | #------------------------------------------------------------------------------ 185 | # REPLICATION 186 | #------------------------------------------------------------------------------ 187 | 188 | # - Master Server - 189 | 190 | # These settings are ignored on a standby server 191 | 192 | #max_wal_senders = 0 # max number of walsender processes 193 | # (change requires restart) 194 | #wal_sender_delay = 1s # walsender cycle time, 1-10000 milliseconds 195 | #wal_keep_segments = 0 # in logfile segments, 16MB each; 0 disables 196 | #vacuum_defer_cleanup_age = 0 # number of xacts by which cleanup is delayed 197 | #replication_timeout = 60s # in milliseconds; 0 disables 198 | #synchronous_standby_names = '' # standby servers that provide sync rep 199 | # comma-separated list of application_name 200 | # from standby(s); '*' = all 201 | 202 | # - Standby Servers - 203 | 204 | # These settings are ignored on a master server 205 | 206 | #hot_standby = off # "on" allows queries during recovery 207 | # (change requires restart) 208 | #max_standby_archive_delay = 30s # max delay before canceling queries 209 | # when reading WAL from archive; 210 | # -1 allows indefinite delay 211 | #max_standby_streaming_delay = 30s # max delay before canceling queries 212 | # when reading streaming WAL; 213 | # -1 allows indefinite delay 214 | #wal_receiver_status_interval = 10s # send replies at least this often 215 | # 0 disables 216 | #hot_standby_feedback = off # send info from standby to prevent 217 | # query conflicts 218 | 219 | #------------------------------------------------------------------------------ 220 | # QUERY TUNING 221 | #------------------------------------------------------------------------------ 222 | 223 | # - Planner Method Configuration - 224 | 225 | #enable_bitmapscan = on 226 | #enable_hashagg = on 227 | #enable_hashjoin = on 228 | #enable_indexscan = on 229 | #enable_material = on 230 | #enable_mergejoin = on 231 | #enable_nestloop = on 232 | #enable_seqscan = on 233 | #enable_sort = on 234 | #enable_tidscan = on 235 | 236 | # - Planner Cost Constants - 237 | 238 | #seq_page_cost = 1.0 # measured on an arbitrary scale 239 | #random_page_cost = 4.0 # same scale as above 240 | #cpu_tuple_cost = 0.01 # same scale as above 241 | #cpu_index_tuple_cost = 0.005 # same scale as above 242 | #cpu_operator_cost = 0.0025 # same scale as above 243 | #effective_cache_size = 128MB 244 | 245 | # - Genetic Query Optimizer - 246 | 247 | #geqo = on 248 | #geqo_threshold = 12 249 | #geqo_effort = 5 # range 1-10 250 | #geqo_pool_size = 0 # selects default based on effort 251 | #geqo_generations = 0 # selects default based on effort 252 | #geqo_selection_bias = 2.0 # range 1.5-2.0 253 | #geqo_seed = 0.0 # range 0.0-1.0 254 | 255 | # - Other Planner Options - 256 | 257 | #default_statistics_target = 100 # range 1-10000 258 | #constraint_exclusion = partition # on, off, or partition 259 | #cursor_tuple_fraction = 0.1 # range 0.0-1.0 260 | #from_collapse_limit = 8 261 | #join_collapse_limit = 8 # 1 disables collapsing of explicit 262 | # JOIN clauses 263 | 264 | 265 | #------------------------------------------------------------------------------ 266 | # ERROR REPORTING AND LOGGING 267 | #------------------------------------------------------------------------------ 268 | 269 | # - Where to Log - 270 | 271 | #log_destination = 'stderr' # Valid values are combinations of 272 | # stderr, csvlog, syslog, and eventlog, 273 | # depending on platform. csvlog 274 | # requires logging_collector to be on. 275 | 276 | # This is used when logging to stderr: 277 | #logging_collector = off # Enable capturing of stderr and csvlog 278 | # into log files. Required to be on for 279 | # csvlogs. 280 | # (change requires restart) 281 | 282 | # These are only used if logging_collector is on: 283 | #log_directory = 'pg_log' # directory where log files are written, 284 | # can be absolute or relative to PGDATA 285 | #log_filename = 'postgresql-%Y-%m-%d_%H%M%S.log' # log file name pattern, 286 | # can include strftime() escapes 287 | #log_file_mode = 0600 # creation mode for log files, 288 | # begin with 0 to use octal notation 289 | #log_truncate_on_rotation = off # If on, an existing log file with the 290 | # same name as the new log file will be 291 | # truncated rather than appended to. 292 | # But such truncation only occurs on 293 | # time-driven rotation, not on restarts 294 | # or size-driven rotation. Default is 295 | # off, meaning append to existing files 296 | # in all cases. 297 | #log_rotation_age = 1d # Automatic rotation of logfiles will 298 | # happen after that time. 0 disables. 299 | #log_rotation_size = 10MB # Automatic rotation of logfiles will 300 | # happen after that much log output. 301 | # 0 disables. 302 | 303 | # These are relevant when logging to syslog: 304 | #syslog_facility = 'LOCAL0' 305 | #syslog_ident = 'postgres' 306 | 307 | #silent_mode = off # Run server silently. 308 | # DO NOT USE without syslog or 309 | # logging_collector 310 | # (change requires restart) 311 | 312 | 313 | # - When to Log - 314 | 315 | #client_min_messages = notice # values in order of decreasing detail: 316 | # debug5 317 | # debug4 318 | # debug3 319 | # debug2 320 | # debug1 321 | # log 322 | # notice 323 | # warning 324 | # error 325 | 326 | #log_min_messages = warning # values in order of decreasing detail: 327 | # debug5 328 | # debug4 329 | # debug3 330 | # debug2 331 | # debug1 332 | # info 333 | # notice 334 | # warning 335 | # error 336 | # log 337 | # fatal 338 | # panic 339 | 340 | #log_min_error_statement = error # values in order of decreasing detail: 341 | # debug5 342 | # debug4 343 | # debug3 344 | # debug2 345 | # debug1 346 | # info 347 | # notice 348 | # warning 349 | # error 350 | # log 351 | # fatal 352 | # panic (effectively off) 353 | 354 | #log_min_duration_statement = -1 # -1 is disabled, 0 logs all statements 355 | # and their durations, > 0 logs only 356 | # statements running at least this number 357 | # of milliseconds 358 | 359 | 360 | # - What to Log - 361 | 362 | #debug_print_parse = off 363 | #debug_print_rewritten = off 364 | #debug_print_plan = off 365 | #debug_pretty_print = on 366 | #log_checkpoints = off 367 | #log_connections = off 368 | #log_disconnections = off 369 | #log_duration = off 370 | #log_error_verbosity = default # terse, default, or verbose messages 371 | #log_hostname = off 372 | log_line_prefix = '%t ' # special values: 373 | # %a = application name 374 | # %u = user name 375 | # %d = database name 376 | # %r = remote host and port 377 | # %h = remote host 378 | # %p = process ID 379 | # %t = timestamp without milliseconds 380 | # %m = timestamp with milliseconds 381 | # %i = command tag 382 | # %e = SQL state 383 | # %c = session ID 384 | # %l = session line number 385 | # %s = session start timestamp 386 | # %v = virtual transaction ID 387 | # %x = transaction ID (0 if none) 388 | # %q = stop here in non-session 389 | # processes 390 | # %% = '%' 391 | # e.g. '<%u%%%d> ' 392 | #log_lock_waits = off # log lock waits >= deadlock_timeout 393 | #log_statement = 'none' # none, ddl, mod, all 394 | #log_temp_files = -1 # log temporary files equal or larger 395 | # than the specified size in kilobytes; 396 | # -1 disables, 0 logs all temp files 397 | #log_timezone = '(defaults to server environment setting)' 398 | 399 | #------------------------------------------------------------------------------ 400 | # RUNTIME STATISTICS 401 | #------------------------------------------------------------------------------ 402 | 403 | # - Query/Index Statistics Collector - 404 | 405 | #track_activities = on 406 | #track_counts = on 407 | #track_functions = none # none, pl, all 408 | #track_activity_query_size = 1024 # (change requires restart) 409 | #update_process_title = on 410 | #stats_temp_directory = 'pg_stat_tmp' 411 | 412 | 413 | # - Statistics Monitoring - 414 | 415 | #log_parser_stats = off 416 | #log_planner_stats = off 417 | #log_executor_stats = off 418 | #log_statement_stats = off 419 | 420 | #------------------------------------------------------------------------------ 421 | # AUTOVACUUM PARAMETERS 422 | #------------------------------------------------------------------------------ 423 | 424 | #autovacuum = on # Enable autovacuum subprocess? 'on' 425 | # requires track_counts to also be on. 426 | #log_autovacuum_min_duration = -1 # -1 disables, 0 logs all actions and 427 | # their durations, > 0 logs only 428 | # actions running at least this number 429 | # of milliseconds. 430 | #autovacuum_max_workers = 3 # max number of autovacuum subprocesses 431 | # (change requires restart) 432 | #autovacuum_naptime = 1min # time between autovacuum runs 433 | #autovacuum_vacuum_threshold = 50 # min number of row updates before 434 | # vacuum 435 | #autovacuum_analyze_threshold = 50 # min number of row updates before 436 | # analyze 437 | #autovacuum_vacuum_scale_factor = 0.2 # fraction of table size before vacuum 438 | #autovacuum_analyze_scale_factor = 0.1 # fraction of table size before analyze 439 | #autovacuum_freeze_max_age = 200000000 # maximum XID age before forced vacuum 440 | # (change requires restart) 441 | #autovacuum_vacuum_cost_delay = 20ms # default vacuum cost delay for 442 | # autovacuum, in milliseconds; 443 | # -1 means use vacuum_cost_delay 444 | #autovacuum_vacuum_cost_limit = -1 # default vacuum cost limit for 445 | # autovacuum, -1 means use 446 | # vacuum_cost_limit 447 | 448 | #------------------------------------------------------------------------------ 449 | # CLIENT CONNECTION DEFAULTS 450 | #------------------------------------------------------------------------------ 451 | 452 | # - Statement Behavior - 453 | 454 | #search_path = '"$user",public' # schema names 455 | #default_tablespace = '' # a tablespace name, '' uses the default 456 | #temp_tablespaces = '' # a list of tablespace names, '' uses 457 | # only default tablespace 458 | #check_function_bodies = on 459 | #default_transaction_isolation = 'read committed' 460 | #default_transaction_read_only = off 461 | #default_transaction_deferrable = off 462 | #session_replication_role = 'origin' 463 | #statement_timeout = 0 # in milliseconds, 0 is disabled 464 | #vacuum_freeze_min_age = 50000000 465 | #vacuum_freeze_table_age = 150000000 466 | #bytea_output = 'hex' # hex, escape 467 | #xmlbinary = 'base64' 468 | #xmloption = 'content' 469 | 470 | # - Locale and Formatting - 471 | 472 | datestyle = 'iso, mdy' 473 | #intervalstyle = 'postgres' 474 | #timezone = '(defaults to server environment setting)' 475 | #timezone_abbreviations = 'Default' # Select the set of available time zone 476 | # abbreviations. Currently, there are 477 | # Default 478 | # Australia 479 | # India 480 | # You can create your own file in 481 | # share/timezonesets/. 482 | #extra_float_digits = 0 # min -15, max 3 483 | #client_encoding = sql_ascii # actually, defaults to database 484 | # encoding 485 | 486 | # These settings are initialized by initdb, but they can be changed. 487 | lc_messages = 'C' # locale for system error message 488 | # strings 489 | lc_monetary = 'C' # locale for monetary formatting 490 | lc_numeric = 'C' # locale for number formatting 491 | lc_time = 'C' # locale for time formatting 492 | 493 | # default configuration for text search 494 | default_text_search_config = 'pg_catalog.english' 495 | 496 | # - Other Defaults - 497 | 498 | #dynamic_library_path = '$libdir' 499 | #local_preload_libraries = '' 500 | 501 | 502 | #------------------------------------------------------------------------------ 503 | # LOCK MANAGEMENT 504 | #------------------------------------------------------------------------------ 505 | 506 | #deadlock_timeout = 1s 507 | #max_locks_per_transaction = 64 # min 10 508 | # (change requires restart) 509 | # Note: Each lock table slot uses ~270 bytes of shared memory, and there are 510 | # max_locks_per_transaction * (max_connections + max_prepared_transactions) 511 | # lock table slots. 512 | #max_pred_locks_per_transaction = 64 # min 10 513 | # (change requires restart) 514 | 515 | #------------------------------------------------------------------------------ 516 | # VERSION/PLATFORM COMPATIBILITY 517 | #------------------------------------------------------------------------------ 518 | 519 | # - Previous PostgreSQL Versions - 520 | 521 | #array_nulls = on 522 | #backslash_quote = safe_encoding # on, off, or safe_encoding 523 | #default_with_oids = off 524 | #escape_string_warning = on 525 | #lo_compat_privileges = off 526 | #quote_all_identifiers = off 527 | #sql_inheritance = on 528 | #standard_conforming_strings = on 529 | #synchronize_seqscans = on 530 | 531 | # - Other Platforms and Clients - 532 | 533 | #transform_null_equals = off 534 | 535 | 536 | #------------------------------------------------------------------------------ 537 | # ERROR HANDLING 538 | #------------------------------------------------------------------------------ 539 | 540 | #exit_on_error = off # terminate session on any error? 541 | #restart_after_crash = on # reinitialize after backend crash? 542 | 543 | 544 | #------------------------------------------------------------------------------ 545 | # CUSTOMIZED OPTIONS 546 | #------------------------------------------------------------------------------ 547 | 548 | #custom_variable_classes = '' # list of custom variable class names 549 | 550 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && \ 3 | apt-get install -y -qq python-software-properties software-properties-common wget && \ 4 | echo "deb http://apt.postgresql.org/pub/repos/apt/ precise-pgdg main" > /etc/apt/sources.list.d/pgdg.list && \ 5 | wget --quiet --no-check-certificate -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - && \ 6 | apt-get -qq update && \ 7 | LC_ALL=C DEBIAN_FRONTEND=noninteractive apt-get install -y -qq postgresql-9.3 postgresql-contrib-9.3 8 | ADD pg_hba.conf /etc/postgresql/9.3/main/pg_hba.conf 9 | ADD postgresql.conf /etc/postgresql/9.3/main/postgresql.conf 10 | USER postgres 11 | EXPOSE 5432 12 | ENTRYPOINT ["/usr/lib/postgresql/9.3/bin/postgres", "-D", "/var/lib/postgresql/9.3/main", "-c", "config_file=/etc/postgresql/9.3/main/postgresql.conf", "-c", "listen_addresses=*"] 13 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.3/pg_hba.conf: -------------------------------------------------------------------------------- 1 | host all all 0.0.0.0/0 trust 2 | local all all trust 3 | -------------------------------------------------------------------------------- /database/postgres/postgres_9.3/postgresql.conf: -------------------------------------------------------------------------------- 1 | # ----------------------------- 2 | # PostgreSQL configuration file 3 | # ----------------------------- 4 | # 5 | # This file consists of lines of the form: 6 | # 7 | # name = value 8 | # 9 | # (The "=" is optional.) Whitespace may be used. Comments are introduced with 10 | # "#" anywhere on a line. The complete list of parameter names and allowed 11 | # values can be found in the PostgreSQL documentation. 12 | # 13 | # The commented-out settings shown in this file represent the default values. 14 | # Re-commenting a setting is NOT sufficient to revert it to the default value; 15 | # you need to reload the server. 16 | # 17 | # This file is read on server startup and when the server receives a SIGHUP 18 | # signal. If you edit the file on a running system, you have to SIGHUP the 19 | # server for the changes to take effect, or use "pg_ctl reload". Some 20 | # parameters, which are marked below, require a server shutdown and restart to 21 | # take effect. 22 | # 23 | # Any parameter can also be given as a command-line option to the server, e.g., 24 | # "postgres -c log_connections=on". Some parameters can be changed at run time 25 | # with the "SET" SQL command. 26 | # 27 | # Memory units: kB = kilobytes Time units: ms = milliseconds 28 | # MB = megabytes s = seconds 29 | # GB = gigabytes min = minutes 30 | # h = hours 31 | # d = days 32 | 33 | 34 | #------------------------------------------------------------------------------ 35 | # FILE LOCATIONS 36 | #------------------------------------------------------------------------------ 37 | 38 | # The default values of these variables are driven from the -D command-line 39 | # option or PGDATA environment variable, represented here as ConfigDir. 40 | 41 | data_directory = '/var/lib/postgresql/9.3/main' # use data in another directory 42 | # (change requires restart) 43 | hba_file = '/etc/postgresql/9.3/main/pg_hba.conf' # host-based authentication file 44 | # (change requires restart) 45 | ident_file = '/etc/postgresql/9.3/main/pg_ident.conf' # ident configuration file 46 | # (change requires restart) 47 | 48 | # If external_pid_file is not explicitly set, no extra PID file is written. 49 | external_pid_file = '/var/run/postgresql/9.3-main.pid' # write an extra PID file 50 | # (change requires restart) 51 | 52 | 53 | #------------------------------------------------------------------------------ 54 | # CONNECTIONS AND AUTHENTICATION 55 | #------------------------------------------------------------------------------ 56 | 57 | # - Connection Settings - 58 | 59 | #listen_addresses = 'localhost' # what IP address(es) to listen on; 60 | # comma-separated list of addresses; 61 | # defaults to 'localhost'; use '*' for all 62 | # (change requires restart) 63 | port = 5432 # (change requires restart) 64 | max_connections = 100 # (change requires restart) 65 | # Note: Increasing max_connections costs ~400 bytes of shared memory per 66 | # connection slot, plus lock space (see max_locks_per_transaction). 67 | #superuser_reserved_connections = 3 # (change requires restart) 68 | unix_socket_directories = '/var/run/postgresql' # comma-separated list of directories 69 | # (change requires restart) 70 | #unix_socket_group = '' # (change requires restart) 71 | #unix_socket_permissions = 0777 # begin with 0 to use octal notation 72 | # (change requires restart) 73 | #bonjour = off # advertise server via Bonjour 74 | # (change requires restart) 75 | #bonjour_name = '' # defaults to the computer name 76 | # (change requires restart) 77 | 78 | # - Security and Authentication - 79 | 80 | #authentication_timeout = 1min # 1s-600s 81 | ssl = true # (change requires restart) 82 | #ssl_ciphers = 'DEFAULT:!LOW:!EXP:!MD5:@STRENGTH' # allowed SSL ciphers 83 | # (change requires restart) 84 | #ssl_renegotiation_limit = 512MB # amount of data between renegotiations 85 | ssl_cert_file = '/etc/ssl/certs/ssl-cert-snakeoil.pem' # (change requires restart) 86 | ssl_key_file = '/etc/ssl/private/ssl-cert-snakeoil.key' # (change requires restart) 87 | #ssl_ca_file = '' # (change requires restart) 88 | #ssl_crl_file = '' # (change requires restart) 89 | #password_encryption = on 90 | #db_user_namespace = off 91 | 92 | # Kerberos and GSSAPI 93 | #krb_server_keyfile = '' 94 | #krb_srvname = 'postgres' # (Kerberos only) 95 | #krb_caseins_users = off 96 | 97 | # - TCP Keepalives - 98 | # see "man 7 tcp" for details 99 | 100 | #tcp_keepalives_idle = 0 # TCP_KEEPIDLE, in seconds; 101 | # 0 selects the system default 102 | #tcp_keepalives_interval = 0 # TCP_KEEPINTVL, in seconds; 103 | # 0 selects the system default 104 | #tcp_keepalives_count = 0 # TCP_KEEPCNT; 105 | # 0 selects the system default 106 | 107 | 108 | #------------------------------------------------------------------------------ 109 | # RESOURCE USAGE (except WAL) 110 | #------------------------------------------------------------------------------ 111 | 112 | # - Memory - 113 | 114 | shared_buffers = 128MB # min 128kB 115 | # (change requires restart) 116 | #temp_buffers = 8MB # min 800kB 117 | #max_prepared_transactions = 0 # zero disables the feature 118 | # (change requires restart) 119 | # Note: Increasing max_prepared_transactions costs ~600 bytes of shared memory 120 | # per transaction slot, plus lock space (see max_locks_per_transaction). 121 | # It is not advisable to set max_prepared_transactions nonzero unless you 122 | # actively intend to use prepared transactions. 123 | #work_mem = 1MB # min 64kB 124 | #maintenance_work_mem = 16MB # min 1MB 125 | #max_stack_depth = 2MB # min 100kB 126 | 127 | # - Disk - 128 | 129 | #temp_file_limit = -1 # limits per-session temp file space 130 | # in kB, or -1 for no limit 131 | 132 | # - Kernel Resource Usage - 133 | 134 | #max_files_per_process = 1000 # min 25 135 | # (change requires restart) 136 | #shared_preload_libraries = '' # (change requires restart) 137 | 138 | # - Cost-Based Vacuum Delay - 139 | 140 | #vacuum_cost_delay = 0 # 0-100 milliseconds 141 | #vacuum_cost_page_hit = 1 # 0-10000 credits 142 | #vacuum_cost_page_miss = 10 # 0-10000 credits 143 | #vacuum_cost_page_dirty = 20 # 0-10000 credits 144 | #vacuum_cost_limit = 200 # 1-10000 credits 145 | 146 | # - Background Writer - 147 | 148 | #bgwriter_delay = 200ms # 10-10000ms between rounds 149 | #bgwriter_lru_maxpages = 100 # 0-1000 max buffers written/round 150 | #bgwriter_lru_multiplier = 2.0 # 0-10.0 multipler on buffers scanned/round 151 | 152 | # - Asynchronous Behavior - 153 | 154 | #effective_io_concurrency = 1 # 1-1000; 0 disables prefetching 155 | 156 | 157 | #------------------------------------------------------------------------------ 158 | # WRITE AHEAD LOG 159 | #------------------------------------------------------------------------------ 160 | 161 | # - Settings - 162 | 163 | #wal_level = minimal # minimal, archive, or hot_standby 164 | # (change requires restart) 165 | #fsync = on # turns forced synchronization on or off 166 | #synchronous_commit = on # synchronization level; 167 | # off, local, remote_write, or on 168 | #wal_sync_method = fsync # the default is the first option 169 | # supported by the operating system: 170 | # open_datasync 171 | # fdatasync (default on Linux) 172 | # fsync 173 | # fsync_writethrough 174 | # open_sync 175 | #full_page_writes = on # recover from partial page writes 176 | #wal_buffers = -1 # min 32kB, -1 sets based on shared_buffers 177 | # (change requires restart) 178 | #wal_writer_delay = 200ms # 1-10000 milliseconds 179 | 180 | #commit_delay = 0 # range 0-100000, in microseconds 181 | #commit_siblings = 5 # range 1-1000 182 | 183 | # - Checkpoints - 184 | 185 | #checkpoint_segments = 3 # in logfile segments, min 1, 16MB each 186 | #checkpoint_timeout = 5min # range 30s-1h 187 | #checkpoint_completion_target = 0.5 # checkpoint target duration, 0.0 - 1.0 188 | #checkpoint_warning = 30s # 0 disables 189 | 190 | # - Archiving - 191 | 192 | #archive_mode = off # allows archiving to be done 193 | # (change requires restart) 194 | #archive_command = '' # command to use to archive a logfile segment 195 | # placeholders: %p = path of file to archive 196 | # %f = file name only 197 | # e.g. 'test ! -f /mnt/server/archivedir/%f && cp %p /mnt/server/archivedir/%f' 198 | #archive_timeout = 0 # force a logfile segment switch after this 199 | # number of seconds; 0 disables 200 | 201 | 202 | #------------------------------------------------------------------------------ 203 | # REPLICATION 204 | #------------------------------------------------------------------------------ 205 | 206 | # - Sending Server(s) - 207 | 208 | # Set these on the master and on any standby that will send replication data. 209 | 210 | #max_wal_senders = 0 # max number of walsender processes 211 | # (change requires restart) 212 | #wal_keep_segments = 0 # in logfile segments, 16MB each; 0 disables 213 | #wal_sender_timeout = 60s # in milliseconds; 0 disables 214 | 215 | # - Master Server - 216 | 217 | # These settings are ignored on a standby server. 218 | 219 | #synchronous_standby_names = '' # standby servers that provide sync rep 220 | # comma-separated list of application_name 221 | # from standby(s); '*' = all 222 | #vacuum_defer_cleanup_age = 0 # number of xacts by which cleanup is delayed 223 | 224 | # - Standby Servers - 225 | 226 | # These settings are ignored on a master server. 227 | 228 | #hot_standby = off # "on" allows queries during recovery 229 | # (change requires restart) 230 | #max_standby_archive_delay = 30s # max delay before canceling queries 231 | # when reading WAL from archive; 232 | # -1 allows indefinite delay 233 | #max_standby_streaming_delay = 30s # max delay before canceling queries 234 | # when reading streaming WAL; 235 | # -1 allows indefinite delay 236 | #wal_receiver_status_interval = 10s # send replies at least this often 237 | # 0 disables 238 | #hot_standby_feedback = off # send info from standby to prevent 239 | # query conflicts 240 | #wal_receiver_timeout = 60s # time that receiver waits for 241 | # communication from master 242 | # in milliseconds; 0 disables 243 | 244 | 245 | #------------------------------------------------------------------------------ 246 | # QUERY TUNING 247 | #------------------------------------------------------------------------------ 248 | 249 | # - Planner Method Configuration - 250 | 251 | #enable_bitmapscan = on 252 | #enable_hashagg = on 253 | #enable_hashjoin = on 254 | #enable_indexscan = on 255 | #enable_indexonlyscan = on 256 | #enable_material = on 257 | #enable_mergejoin = on 258 | #enable_nestloop = on 259 | #enable_seqscan = on 260 | #enable_sort = on 261 | #enable_tidscan = on 262 | 263 | # - Planner Cost Constants - 264 | 265 | #seq_page_cost = 1.0 # measured on an arbitrary scale 266 | #random_page_cost = 4.0 # same scale as above 267 | #cpu_tuple_cost = 0.01 # same scale as above 268 | #cpu_index_tuple_cost = 0.005 # same scale as above 269 | #cpu_operator_cost = 0.0025 # same scale as above 270 | #effective_cache_size = 128MB 271 | 272 | # - Genetic Query Optimizer - 273 | 274 | #geqo = on 275 | #geqo_threshold = 12 276 | #geqo_effort = 5 # range 1-10 277 | #geqo_pool_size = 0 # selects default based on effort 278 | #geqo_generations = 0 # selects default based on effort 279 | #geqo_selection_bias = 2.0 # range 1.5-2.0 280 | #geqo_seed = 0.0 # range 0.0-1.0 281 | 282 | # - Other Planner Options - 283 | 284 | #default_statistics_target = 100 # range 1-10000 285 | #constraint_exclusion = partition # on, off, or partition 286 | #cursor_tuple_fraction = 0.1 # range 0.0-1.0 287 | #from_collapse_limit = 8 288 | #join_collapse_limit = 8 # 1 disables collapsing of explicit 289 | # JOIN clauses 290 | 291 | 292 | #------------------------------------------------------------------------------ 293 | # ERROR REPORTING AND LOGGING 294 | #------------------------------------------------------------------------------ 295 | 296 | # - Where to Log - 297 | 298 | #log_destination = 'stderr' # Valid values are combinations of 299 | # stderr, csvlog, syslog, and eventlog, 300 | # depending on platform. csvlog 301 | # requires logging_collector to be on. 302 | 303 | # This is used when logging to stderr: 304 | #logging_collector = off # Enable capturing of stderr and csvlog 305 | # into log files. Required to be on for 306 | # csvlogs. 307 | # (change requires restart) 308 | 309 | # These are only used if logging_collector is on: 310 | #log_directory = 'pg_log' # directory where log files are written, 311 | # can be absolute or relative to PGDATA 312 | #log_filename = 'postgresql-%Y-%m-%d_%H%M%S.log' # log file name pattern, 313 | # can include strftime() escapes 314 | #log_file_mode = 0600 # creation mode for log files, 315 | # begin with 0 to use octal notation 316 | #log_truncate_on_rotation = off # If on, an existing log file with the 317 | # same name as the new log file will be 318 | # truncated rather than appended to. 319 | # But such truncation only occurs on 320 | # time-driven rotation, not on restarts 321 | # or size-driven rotation. Default is 322 | # off, meaning append to existing files 323 | # in all cases. 324 | #log_rotation_age = 1d # Automatic rotation of logfiles will 325 | # happen after that time. 0 disables. 326 | #log_rotation_size = 10MB # Automatic rotation of logfiles will 327 | # happen after that much log output. 328 | # 0 disables. 329 | 330 | # These are relevant when logging to syslog: 331 | #syslog_facility = 'LOCAL0' 332 | #syslog_ident = 'postgres' 333 | 334 | # This is only relevant when logging to eventlog (win32): 335 | #event_source = 'PostgreSQL' 336 | 337 | # - When to Log - 338 | 339 | #client_min_messages = notice # values in order of decreasing detail: 340 | # debug5 341 | # debug4 342 | # debug3 343 | # debug2 344 | # debug1 345 | # log 346 | # notice 347 | # warning 348 | # error 349 | 350 | #log_min_messages = warning # values in order of decreasing detail: 351 | # debug5 352 | # debug4 353 | # debug3 354 | # debug2 355 | # debug1 356 | # info 357 | # notice 358 | # warning 359 | # error 360 | # log 361 | # fatal 362 | # panic 363 | 364 | #log_min_error_statement = error # values in order of decreasing detail: 365 | # debug5 366 | # debug4 367 | # debug3 368 | # debug2 369 | # debug1 370 | # info 371 | # notice 372 | # warning 373 | # error 374 | # log 375 | # fatal 376 | # panic (effectively off) 377 | 378 | #log_min_duration_statement = -1 # -1 is disabled, 0 logs all statements 379 | # and their durations, > 0 logs only 380 | # statements running at least this number 381 | # of milliseconds 382 | 383 | 384 | # - What to Log - 385 | 386 | #debug_print_parse = off 387 | #debug_print_rewritten = off 388 | #debug_print_plan = off 389 | #debug_pretty_print = on 390 | #log_checkpoints = off 391 | #log_connections = off 392 | #log_disconnections = off 393 | #log_duration = off 394 | #log_error_verbosity = default # terse, default, or verbose messages 395 | #log_hostname = off 396 | log_line_prefix = '%t ' # special values: 397 | # %a = application name 398 | # %u = user name 399 | # %d = database name 400 | # %r = remote host and port 401 | # %h = remote host 402 | # %p = process ID 403 | # %t = timestamp without milliseconds 404 | # %m = timestamp with milliseconds 405 | # %i = command tag 406 | # %e = SQL state 407 | # %c = session ID 408 | # %l = session line number 409 | # %s = session start timestamp 410 | # %v = virtual transaction ID 411 | # %x = transaction ID (0 if none) 412 | # %q = stop here in non-session 413 | # processes 414 | # %% = '%' 415 | # e.g. '<%u%%%d> ' 416 | #log_lock_waits = off # log lock waits >= deadlock_timeout 417 | #log_statement = 'none' # none, ddl, mod, all 418 | #log_temp_files = -1 # log temporary files equal or larger 419 | # than the specified size in kilobytes; 420 | # -1 disables, 0 logs all temp files 421 | log_timezone = 'UTC' 422 | 423 | 424 | #------------------------------------------------------------------------------ 425 | # RUNTIME STATISTICS 426 | #------------------------------------------------------------------------------ 427 | 428 | # - Query/Index Statistics Collector - 429 | 430 | #track_activities = on 431 | #track_counts = on 432 | #track_io_timing = off 433 | #track_functions = none # none, pl, all 434 | #track_activity_query_size = 1024 # (change requires restart) 435 | #update_process_title = on 436 | #stats_temp_directory = 'pg_stat_tmp' 437 | 438 | 439 | # - Statistics Monitoring - 440 | 441 | #log_parser_stats = off 442 | #log_planner_stats = off 443 | #log_executor_stats = off 444 | #log_statement_stats = off 445 | 446 | 447 | #------------------------------------------------------------------------------ 448 | # AUTOVACUUM PARAMETERS 449 | #------------------------------------------------------------------------------ 450 | 451 | #autovacuum = on # Enable autovacuum subprocess? 'on' 452 | # requires track_counts to also be on. 453 | #log_autovacuum_min_duration = -1 # -1 disables, 0 logs all actions and 454 | # their durations, > 0 logs only 455 | # actions running at least this number 456 | # of milliseconds. 457 | #autovacuum_max_workers = 3 # max number of autovacuum subprocesses 458 | # (change requires restart) 459 | #autovacuum_naptime = 1min # time between autovacuum runs 460 | #autovacuum_vacuum_threshold = 50 # min number of row updates before 461 | # vacuum 462 | #autovacuum_analyze_threshold = 50 # min number of row updates before 463 | # analyze 464 | #autovacuum_vacuum_scale_factor = 0.2 # fraction of table size before vacuum 465 | #autovacuum_analyze_scale_factor = 0.1 # fraction of table size before analyze 466 | #autovacuum_freeze_max_age = 200000000 # maximum XID age before forced vacuum 467 | # (change requires restart) 468 | #autovacuum_multixact_freeze_max_age = 400000000 # maximum Multixact age 469 | # before forced vacuum 470 | # (change requires restart) 471 | #autovacuum_vacuum_cost_delay = 20ms # default vacuum cost delay for 472 | # autovacuum, in milliseconds; 473 | # -1 means use vacuum_cost_delay 474 | #autovacuum_vacuum_cost_limit = -1 # default vacuum cost limit for 475 | # autovacuum, -1 means use 476 | # vacuum_cost_limit 477 | 478 | 479 | #------------------------------------------------------------------------------ 480 | # CLIENT CONNECTION DEFAULTS 481 | #------------------------------------------------------------------------------ 482 | 483 | # - Statement Behavior - 484 | 485 | #search_path = '"$user",public' # schema names 486 | #default_tablespace = '' # a tablespace name, '' uses the default 487 | #temp_tablespaces = '' # a list of tablespace names, '' uses 488 | # only default tablespace 489 | #check_function_bodies = on 490 | #default_transaction_isolation = 'read committed' 491 | #default_transaction_read_only = off 492 | #default_transaction_deferrable = off 493 | #session_replication_role = 'origin' 494 | #statement_timeout = 0 # in milliseconds, 0 is disabled 495 | #lock_timeout = 0 # in milliseconds, 0 is disabled 496 | #vacuum_freeze_min_age = 50000000 497 | #vacuum_freeze_table_age = 150000000 498 | #vacuum_multixact_freeze_min_age = 5000000 499 | #vacuum_multixact_freeze_table_age = 150000000 500 | #bytea_output = 'hex' # hex, escape 501 | #xmlbinary = 'base64' 502 | #xmloption = 'content' 503 | 504 | # - Locale and Formatting - 505 | 506 | datestyle = 'iso, mdy' 507 | #intervalstyle = 'postgres' 508 | timezone = 'UTC' 509 | #timezone_abbreviations = 'Default' # Select the set of available time zone 510 | # abbreviations. Currently, there are 511 | # Default 512 | # Australia 513 | # India 514 | # You can create your own file in 515 | # share/timezonesets/. 516 | #extra_float_digits = 0 # min -15, max 3 517 | #client_encoding = sql_ascii # actually, defaults to database 518 | # encoding 519 | 520 | # These settings are initialized by initdb, but they can be changed. 521 | lc_messages = 'C' # locale for system error message 522 | # strings 523 | lc_monetary = 'C' # locale for monetary formatting 524 | lc_numeric = 'C' # locale for number formatting 525 | lc_time = 'C' # locale for time formatting 526 | 527 | # default configuration for text search 528 | default_text_search_config = 'pg_catalog.english' 529 | 530 | # - Other Defaults - 531 | 532 | #dynamic_library_path = '$libdir' 533 | #local_preload_libraries = '' 534 | 535 | 536 | #------------------------------------------------------------------------------ 537 | # LOCK MANAGEMENT 538 | #------------------------------------------------------------------------------ 539 | 540 | #deadlock_timeout = 1s 541 | #max_locks_per_transaction = 64 # min 10 542 | # (change requires restart) 543 | # Note: Each lock table slot uses ~270 bytes of shared memory, and there are 544 | # max_locks_per_transaction * (max_connections + max_prepared_transactions) 545 | # lock table slots. 546 | #max_pred_locks_per_transaction = 64 # min 10 547 | # (change requires restart) 548 | 549 | 550 | #------------------------------------------------------------------------------ 551 | # VERSION/PLATFORM COMPATIBILITY 552 | #------------------------------------------------------------------------------ 553 | 554 | # - Previous PostgreSQL Versions - 555 | 556 | #array_nulls = on 557 | #backslash_quote = safe_encoding # on, off, or safe_encoding 558 | #default_with_oids = off 559 | #escape_string_warning = on 560 | #lo_compat_privileges = off 561 | #quote_all_identifiers = off 562 | #sql_inheritance = on 563 | #standard_conforming_strings = on 564 | #synchronize_seqscans = on 565 | 566 | # - Other Platforms and Clients - 567 | 568 | #transform_null_equals = off 569 | 570 | 571 | #------------------------------------------------------------------------------ 572 | # ERROR HANDLING 573 | #------------------------------------------------------------------------------ 574 | 575 | #exit_on_error = off # terminate session on any error? 576 | #restart_after_crash = on # reinitialize after backend crash? 577 | 578 | 579 | #------------------------------------------------------------------------------ 580 | # CONFIG FILE INCLUDES 581 | #------------------------------------------------------------------------------ 582 | 583 | # These options allow settings to be loaded from files other than the 584 | # default postgresql.conf. 585 | 586 | #include_dir = 'conf.d' # include files ending in '.conf' from 587 | # directory 'conf.d' 588 | #include_if_exists = 'exists.conf' # include file only if it exists 589 | #include = 'special.conf' # include file 590 | 591 | 592 | #------------------------------------------------------------------------------ 593 | # CUSTOMIZED OPTIONS 594 | #------------------------------------------------------------------------------ 595 | 596 | # Add settings for extensions here 597 | -------------------------------------------------------------------------------- /database/redis/redis_2.6/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu 2 | RUN apt-get -qq update && apt-get -y install gcc make wget && \ 3 | wget --quiet http://download.redis.io/releases/redis-2.6.17.tar.gz && \ 4 | tar xzf redis-2.6.17.tar.gz && \ 5 | cd redis-2.6.17 && \ 6 | make && \ 7 | install -t /usr/bin src/redis-server && \ 8 | cd .. && \ 9 | rm redis-2.6.17.tar.gz && rm -rf redis-2.6.17 && \ 10 | mkdir /etc/redis && \ 11 | wget --quiet --no-check-certificate http://raw.github.com/antirez/redis/2.6/redis.conf -O /etc/redis/redis.conf 12 | EXPOSE 6379 13 | ENTRYPOINT ["/usr/bin/redis-server"] -------------------------------------------------------------------------------- /database/redis/redis_2.8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu 2 | RUN apt-get -qq update && apt-get -y install gcc make wget && \ 3 | wget --quiet http://download.redis.io/releases/redis-2.8.8.tar.gz && \ 4 | tar xzf redis-2.8.8.tar.gz && \ 5 | cd redis-2.8.8 && \ 6 | make && \ 7 | install -t /usr//bin src/redis-server && \ 8 | cd .. && \ 9 | rm redis-2.8.8.tar.gz && rm -rf redis-2.8.8 && \ 10 | mkdir /etc/redis && \ 11 | wget --quiet --no-check-certificate http://raw.github.com/antirez/redis/2.8/redis.conf -O /etc/redis/redis.conf 12 | EXPOSE 6379 13 | ENTRYPOINT ["/usr/bin/redis-server"] -------------------------------------------------------------------------------- /database/riak/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN apt-get -qq update && apt-get install -y curl && \ 3 | curl http://apt.basho.com/gpg/basho.apt.key | apt-key add - && \ 4 | echo deb http://apt.basho.com precise main > /etc/apt/sources.list.d/basho.list && \ 5 | apt-get update && \ 6 | apt-get install -y riak 7 | 8 | EXPOSE 8098 9 | ENTRYPOINT ["/usr/sbin/riak"] 10 | CMD ["start"] 11 | 12 | 13 | # see https://index.docker.io/u/guillermo/riak/ 14 | # see http://docs.docker.io/en/latest/examples/running_riak_service/ 15 | -------------------------------------------------------------------------------- /service/rabbitmq/rabbitmq_3.2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:precise 2 | RUN echo "deb http://archive.ubuntu.com/ubuntu/ precise main restricted" >> /etc/apt/sources.list && \ 3 | echo "deb-src http://archive.ubuntu.com/ubuntu/ precise main restricted" >> /etc/apt/sources.list && \ 4 | echo "deb http://archive.ubuntu.com/ubuntu/ precise universe" >> /etc/apt/sources.list && \ 5 | echo "deb-src http://archive.ubuntu.com/ubuntu/ precise universe" >> /etc/apt/sources.list && \ 6 | dpkg-divert --local --rename --add /sbin/initctl && \ 7 | ln -s /bin/true /sbin/initctl && \ 8 | cd /tmp && \ 9 | apt-get -qq update && \ 10 | apt-get -y install wget erlang-nox erlang-dev erlang logrotate && \ 11 | wget http://www.rabbitmq.com/releases/rabbitmq-server/v3.2.1/rabbitmq-server_3.2.1-1_all.deb && \ 12 | dpkg -i rabbitmq-server_3.2.1-1_all.deb && \ 13 | rm rabbitmq-server_3.2.1-1_all.deb && \ 14 | rabbitmq-plugins enable rabbitmq_management 15 | EXPOSE 5672 15672 16 | ENTRYPOINT "/usr/sbin/rabbitmq-server" 17 | 18 | -------------------------------------------------------------------------------- /ubuntu/rootfs/etc/apt/apt.conf.d/90forceyes: -------------------------------------------------------------------------------- 1 | APT::Get::Assume-Yes "true";APT::Get::force-yes "true"; -------------------------------------------------------------------------------- /ubuntu/rootfs/etc/bash.bashrc: -------------------------------------------------------------------------------- 1 | # System-wide .bashrc file for interactive bash(1) shells. 2 | 3 | # To enable the settings / commands in this file for login shells as well, 4 | # this file has to be sourced in /etc/profile. 5 | 6 | # Load default environemnt scripts to be used by the Drone 7 | # continuous integration system. 8 | if [ -d /etc/drone.d ]; then 9 | for i in /etc/drone.d/*.sh; do 10 | if [ -r $i ]; then 11 | . $i 12 | fi 13 | done 14 | unset i 15 | fi 16 | 17 | # If not running interactively, don't do anything 18 | [ -z "$PS1" ] && return 19 | 20 | # check the window size after each command and, if necessary, 21 | # update the values of LINES and COLUMNS. 22 | shopt -s checkwinsize 23 | 24 | # set variable identifying the chroot you work in (used in the prompt below) 25 | if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then 26 | debian_chroot=$(cat /etc/debian_chroot) 27 | fi 28 | 29 | # set a fancy prompt (non-color, overwrite the one in /etc/profile) 30 | PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' 31 | 32 | # Commented out, don't overwrite xterm -T "title" -n "icontitle" by default. 33 | # If this is an xterm set the title to user@host:dir 34 | #case "$TERM" in 35 | #xterm*|rxvt*) 36 | # PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME}: ${PWD}\007"' 37 | # ;; 38 | #*) 39 | # ;; 40 | #esac 41 | 42 | # enable bash completion in interactive shells 43 | #if [ -f /etc/bash_completion ] && ! shopt -oq posix; then 44 | # . /etc/bash_completion 45 | #fi 46 | 47 | # sudo hint 48 | if [ ! -e "$HOME/.sudo_as_admin_successful" ] && [ ! -e "$HOME/.hushlogin" ] ; then 49 | case " $(groups) " in *\ admin\ *) 50 | if [ -x /usr/bin/sudo ]; then 51 | cat <<-EOF 52 | To run a command as administrator (user "root"), use "sudo ". 53 | See "man sudo_root" for details. 54 | 55 | EOF 56 | fi 57 | esac 58 | fi 59 | 60 | # if the command-not-found package is installed, use it 61 | if [ -x /usr/lib/command-not-found -o -x /usr/share/command-not-found/command-not-found ]; then 62 | function command_not_found_handle { 63 | # check because c-n-f could've been removed in the meantime 64 | if [ -x /usr/lib/command-not-found ]; then 65 | /usr/bin/python /usr/lib/command-not-found -- "$1" 66 | return $? 67 | elif [ -x /usr/share/command-not-found/command-not-found ]; then 68 | /usr/bin/python /usr/share/command-not-found/command-not-found -- "$1" 69 | return $? 70 | else 71 | printf "%s: command not found\n" "$1" >&2 72 | return 127 73 | fi 74 | } 75 | fi 76 | -------------------------------------------------------------------------------- /ubuntu/rootfs/etc/init.d/xvfb: -------------------------------------------------------------------------------- 1 | XVFB=/usr/bin/Xvfb 2 | XVFBARGS=":99 -ac -screen 0 1024x768x24" 3 | PIDFILE=/tmp/cucumber_xvfb_99.pid 4 | case "$1" in 5 | start) 6 | echo -n "Starting virtual X frame buffer: Xvfb" 7 | /sbin/start-stop-daemon --start --quiet --pidfile $PIDFILE --make-pidfile --background --exec $XVFB -- $XVFBARGS 8 | echo "." 9 | ;; 10 | stop) 11 | echo -n "Stopping virtual X frame buffer: Xvfb" 12 | /sbin/start-stop-daemon --stop --quiet --pidfile $PIDFILE 13 | rm -f $PIDFILE 14 | echo "." 15 | ;; 16 | restart) 17 | $0 stop 18 | $0 start 19 | ;; 20 | *) 21 | echo "Usage: /etc/init.d/xvfb {start|stop|restart}" 22 | exit 1 23 | esac 24 | exit 0 25 | -------------------------------------------------------------------------------- /ubuntu/rootfs/etc/resolv.conf: -------------------------------------------------------------------------------- 1 | nameserver 4.2.2.2 2 | nameserver 8.8.8.8 -------------------------------------------------------------------------------- /ubuntu/rootfs/etc/sudoers: -------------------------------------------------------------------------------- 1 | # 2 | # This file MUST be edited with the 'visudo' command as root. 3 | # 4 | # Please consider adding local content in /etc/sudoers.d/ instead of 5 | # directly modifying this file. 6 | # 7 | # See the man page for details on how to write a sudoers file. 8 | # 9 | Defaults env_reset 10 | Defaults secure_path="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" 11 | 12 | # Host alias specification 13 | 14 | # User alias specification 15 | 16 | # Cmnd alias specification 17 | 18 | # User privilege specification 19 | root ALL=(ALL:ALL) ALL 20 | ubuntu ALL=NOPASSWD: ALL 21 | 22 | # Members of the admin group may gain root privileges 23 | %admin ALL=(ALL) ALL 24 | 25 | # Allow members of group sudo to execute any command 26 | %sudo ALL=(ALL:ALL) ALL 27 | 28 | # See sudoers(5) for more information on "#include" directives: 29 | 30 | #includedir /etc/sudoers.d 31 | -------------------------------------------------------------------------------- /ubuntu/rootfs/home/ubuntu/.bashrc: -------------------------------------------------------------------------------- 1 | # ~/.bashrc: executed by bash(1) for non-login shells. 2 | # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) 3 | # for examples 4 | 5 | # Load default environemnt scripts to be used by the Drone 6 | # continuous integration system. 7 | if [ -d /etc/drone.d ]; then 8 | for i in /etc/drone.d/*.sh; do 9 | if [ -r $i ]; then 10 | . $i 11 | fi 12 | done 13 | unset i 14 | fi 15 | 16 | # If not running interactively, don't do anything 17 | [ -z "$PS1" ] && return 18 | 19 | # don't put duplicate lines or lines starting with space in the history. 20 | # See bash(1) for more options 21 | HISTCONTROL=ignoreboth 22 | 23 | # append to the history file, don't overwrite it 24 | shopt -s histappend 25 | 26 | # for setting history length see HISTSIZE and HISTFILESIZE in bash(1) 27 | HISTSIZE=1000 28 | HISTFILESIZE=2000 29 | 30 | # check the window size after each command and, if necessary, 31 | # update the values of LINES and COLUMNS. 32 | shopt -s checkwinsize 33 | 34 | # If set, the pattern "**" used in a pathname expansion context will 35 | # match all files and zero or more directories and subdirectories. 36 | #shopt -s globstar 37 | 38 | # make less more friendly for non-text input files, see lesspipe(1) 39 | [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" 40 | 41 | # set variable identifying the chroot you work in (used in the prompt below) 42 | if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then 43 | debian_chroot=$(cat /etc/debian_chroot) 44 | fi 45 | 46 | # set a fancy prompt (non-color, unless we know we "want" color) 47 | case "$TERM" in 48 | xterm-color) color_prompt=yes;; 49 | esac 50 | 51 | # uncomment for a colored prompt, if the terminal has the capability; turned 52 | # off by default to not distract the user: the focus in a terminal window 53 | # should be on the output of commands, not on the prompt 54 | #force_color_prompt=yes 55 | 56 | if [ -n "$force_color_prompt" ]; then 57 | if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then 58 | # We have color support; assume it's compliant with Ecma-48 59 | # (ISO/IEC-6429). (Lack of such support is extremely rare, and such 60 | # a case would tend to support setf rather than setaf.) 61 | color_prompt=yes 62 | else 63 | color_prompt= 64 | fi 65 | fi 66 | 67 | if [ "$color_prompt" = yes ]; then 68 | PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' 69 | else 70 | PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' 71 | fi 72 | unset color_prompt force_color_prompt 73 | 74 | # If this is an xterm set the title to user@host:dir 75 | case "$TERM" in 76 | xterm*|rxvt*) 77 | PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1" 78 | ;; 79 | *) 80 | ;; 81 | esac 82 | 83 | # enable color support of ls and also add handy aliases 84 | if [ -x /usr/bin/dircolors ]; then 85 | test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" 86 | alias ls='ls --color=auto' 87 | #alias dir='dir --color=auto' 88 | #alias vdir='vdir --color=auto' 89 | 90 | alias grep='grep --color=auto' 91 | alias fgrep='fgrep --color=auto' 92 | alias egrep='egrep --color=auto' 93 | fi 94 | 95 | # some more ls aliases 96 | alias ll='ls -alF' 97 | alias la='ls -A' 98 | alias l='ls -CF' 99 | 100 | # Add an "alert" alias for long running commands. Use like so: 101 | # sleep 10; alert 102 | alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"' 103 | 104 | # Alias definitions. 105 | # You may want to put all your additions into a separate file like 106 | # ~/.bash_aliases, instead of adding them here directly. 107 | # See /usr/share/doc/bash-doc/examples in the bash-doc package. 108 | 109 | if [ -f ~/.bash_aliases ]; then 110 | . ~/.bash_aliases 111 | fi 112 | 113 | # enable programmable completion features (you don't need to enable 114 | # this, if it's already enabled in /etc/bash.bashrc and /etc/profile 115 | # sources /etc/bash.bashrc). 116 | if [ -f /etc/bash_completion ] && ! shopt -oq posix; then 117 | . /etc/bash_completion 118 | fi -------------------------------------------------------------------------------- /ubuntu/rootfs/home/ubuntu/.gitconfig: -------------------------------------------------------------------------------- 1 | [user] 2 | name = drone 3 | email = build@drone.io -------------------------------------------------------------------------------- /ubuntu/rootfs/home/ubuntu/.ssh/config: -------------------------------------------------------------------------------- 1 | StrictHostKeyChecking no -------------------------------------------------------------------------------- /ubuntu/rootfs/root/.gitconfig: -------------------------------------------------------------------------------- 1 | [user] 2 | name = drone 3 | email = build@drone.io -------------------------------------------------------------------------------- /ubuntu/rootfs/root/.ssh/config: -------------------------------------------------------------------------------- 1 | StrictHostKeyChecking no -------------------------------------------------------------------------------- /ubuntu/setup.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Creates a container using an Ubuntu Cloud ISO and then 3 | # imports into Docker. This will provide an image that 4 | # is nearly identical to an Amazon (or Rackspace) Ubuntu AMI. 5 | 6 | DOCKER_USER=bradrydzewski 7 | UBUNTU_RELEASE=precise 8 | CONTAINER_NAME=ubuntu 9 | CONTAINER_DIR=/var/lib/lxc/$CONTAINER_NAME/rootfs 10 | 11 | # make sure container and image don't already exist 12 | set +e 13 | lxc-stop -n $CONTAINER_NAME 14 | lxc-destroy -n $CONTAINER_NAME 15 | docker rmi $DOCKER_USER/$CONTAINER_NAME 16 | set -e 17 | 18 | # create the default LXC container (takes ~10 minutes) 19 | lxc-create -n $CONTAINER_NAME -t ubuntu-cloud -- -r $UBUNTU_RELEASE 20 | 21 | # upstart workaround for docker 22 | # see https://github.com/dotcloud/docker/issues/1024 23 | chroot $CONTAINER_DIR dpkg-divert --local --rename --add /sbin/initctl 24 | chroot $CONTAINER_DIR ln -s /bin/true /sbin/initctl 25 | 26 | # override configurations 27 | #chroot $CONTAINER_DIR mkdir -p /home/ubuntu/.ssh 28 | #chroot $CONTAINER_DIR mkdir -p /root/.ssh 29 | #cat rootfs/etc/bash.bashrc > $CONTAINER_DIR/etc/bash.bashrc 30 | #cat rootfs/etc/sudoers > $CONTAINER_DIR/etc/sudoers 31 | #cat rootfs/etc/init.d/xvfb > $CONTAINER_DIR/etc/init.d/xvfb 32 | #cat rootfs/etc/apt/apt.conf.d/90forceyes > $CONTAINER_DIR/etc/apt/apt.conf.d/90forceyes 33 | #cat rootfs/root/.gitconfig > $CONTAINER_DIR/root/.gitconfig 34 | #cat rootfs/root/.ssh/config > $CONTAINER_DIR/root/.ssh/config 35 | #cat rootfs/home/ubuntu/.gitconfig > $CONTAINER_DIR/home/ubuntu/.gitconfig 36 | #cat rootfs/home/ubuntu/.ssh/config > $CONTAINER_DIR/home/ubuntu/.ssh/config 37 | #chroot $CONTAINER_DIR chown -R ubuntu:ubuntu /home/ubuntu 38 | 39 | # backup the symlinked resolv.conf 40 | # and override default resolve.conf 41 | #mv $CONTAINER_DIR/etc/resolv.conf $CONTAINER_DIR/etc/resolv.conf.bak 42 | #cat rootfs/etc/resolv.conf > $CONTAINER_DIR/etc/resolv.conf 43 | 44 | # install essential command binaries (scm, xserver) 45 | #chroot $CONTAINER_DIR apt-get update 46 | #chroot $CONTAINER_DIR apt-get -y install git git-core subversion mercurial bzr fossil xvfb socat 47 | 48 | # remove resolv.conf and restore backup 49 | #chroot $CONTAINER_DIR rm /etc/resolv.conf 50 | #mv $CONTAINER_DIR/etc/resolv.conf.bak $CONTAINER_DIR/etc/resolv.conf 51 | 52 | # tar the container 53 | tar -czf $CONTAINER_NAME.tar -C $CONTAINER_DIR . 54 | 55 | # import the container into docker 56 | cat $CONTAINER_NAME.tar | docker import - $DOCKER_USER/$CONTAINER_NAME 57 | 58 | # cleanup after ourselves ... 59 | # destroy the container 60 | # delete the tar file 61 | rm $CONTAINER_NAME.tar 62 | lxc-destroy -n $CONTAINER_NAME --------------------------------------------------------------------------------