These are the Kickstarter Engineering and Data role definitions for both teams.
| #!/bin/sh | |
| # Must have boot2docker installed if using Mac OS X | |
| installMachineMac() { | |
| sudo wget --no-check-certificate -O /usr/local/bin/docker-machine http://docker-machine-builds.evanhazlett.com/latest/docker-machine_darwin_amd64 | |
| sudo chmod +x /usr/local/bin/docker-machine | |
| } | |
| installDockerBinMac(){ | |
| sudo wget --no-check-certificate -O /usr/local/bin/docker https://get.docker.com/builds/Darwin/x86_64/docker-latest |
| /** | |
| * Removes the minus sign from the beginning of the string | |
| * | |
| * @param str | |
| * @returns an array with the first item as true if a minus | |
| * was found and the string minus the minus sign. | |
| */ | |
| function stripSign(str) { | |
| // Check if it has a minus sign | |
| let hasMinus = str.charAt(0) === '-'; |
#Container Resource Allocation Options in docker-run
now see: https://docs.docker.com/engine/reference/run/#runtime-constraints-on-resources
You have various options for controlling resources (cpu, memory, disk) in docker. These are principally via the docker-run command options.
##Dynamic CPU Allocation
-c, --cpu-shares=0
CPU shares (relative weight, specify some numeric value which is used to allocate relative cpu share)
| #!/bin/bash | |
| WEB_PORT=8080 | |
| WEB_CONTAINER_NAME="zf2-web" | |
| MYSQL_CONTAINER_NAME="zf2-mysql" | |
| MYSQL_PASSWORD="mypassword" | |
| MYSQL_LOCAL_PORT=13306 |
| upstream project { | |
| server 22.22.22.2:3000; | |
| server 22.22.22.3:3000; | |
| server 22.22.22.5:3000; | |
| } | |
| server { | |
| listen 80; | |
| location / { |
| #https://gorails.com/setup/ubuntu/14.04 | |
| sudo apt-get update | |
| sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties | |
| sudo apt-get install libgdbm-dev libncurses5-dev automake libtool bison libffi-dev | |
| curl -L https://get.rvm.io | bash -s stable | |
| source ~/.rvm/scripts/rvm | |
| echo "source ~/.rvm/scripts/rvm" >> ~/.bashrc | |
| rvm install 2.1.2 | |
| rvm use 2.1.2 --default |
| <?php | |
| class SecureSessionHandler extends SessionHandler { | |
| protected $key, $name, $cookie; | |
| public function __construct($key, $name = 'MY_SESSION', $cookie = []) | |
| { | |
| $this->key = $key; | |
| $this->name = $name; |
These are my notes basically. At first i created this gist just as a reminder for myself. But feel free to use this for your project as a starting point. If you have questions you can find me on twitter @thomasf https://twitter.com/thomasf This is how i used it on a Debian Wheezy testing (https://www.debian.org/releases/testing/)
Discuss, ask questions, etc. here https://news.ycombinator.com/item?id=7445545
| .fa-bounce { | |
| display: inline-block; | |
| position: relative; | |
| -moz-animation: bounce 1s infinite linear; | |
| -o-animation: bounce 1s infinite linear; | |
| -webkit-animation: bounce 1s infinite linear; | |
| animation: bounce 1s infinite linear; | |
| } | |
| @-webkit-keyframes bounce { |