This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ################################################################### | |
| # TODO: | |
| # add logging and ses email alerts for deployment failed and passed. | |
| # Also pipe in the log file to logstash etc. | |
| # Also write test cases | |
| # Make all of the deployment task async and return to the POST request immediately. | |
| # Already uses auto-reload - flask debug=True provides auto-reload out of t | |
| # You will need to | |
| # cd ~ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| docker stop $(docker ps -a -q) | |
| docker rm $(docker ps -a -q) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # docker build -t="rails" . | |
| FROM ubuntu:12.04 | |
| RUN apt-get update | |
| ## MYSQL | |
| RUN apt-get install -y -q mysql-client libmysqlclient-dev | |
| ## RUBY |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from fabric.api import * | |
| env.hosts = ['host.name.com'] | |
| env.user = 'user' | |
| env.key_filename = '/path/to/keyfile.pem' | |
| def local_uname(): | |
| local('uname -a') | |
| def remote_uname(): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from fabric.api import * | |
| from fabric.context_managers import settings | |
| hosts = ['10.10.6.234', '10.10.6.65'] | |
| env.user = 'ubuntu' | |
| env.key_filename = '/home/as/work/credentials/pipeline.pem' | |
| def local_uname(): | |
| local('uname -a') | |
| def remote_uname(): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| add-apt-repository ppa:webupd8team/java | |
| apt-get update | |
| apt-get install oracle-java8-installer | |
| apt-get install oracle-java8-set-default |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # But first install Java version update 20 | |
| wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-1.5.2.zip | |
| apt-get install unzip | |
| unzip elasticsearch-1.5.2 -d /usr/local/elasticsearch | |
| cd /usr/local/elasticsearch/elasticsearch-1.5.2/ | |
| bin/plugin -install elasticsearch/elasticsearch-cloud-aws/2.4.1 | |
| bin/plugin -i elasticsearch/marvel/latest | |
| echo "ulimit -n 32000" > /etc/rc.local # we need to increase the max file descriptors from 4096 to 32k | |
| echo "export ES_HEAP_SIZE=30g" > /etc/rc.local # keep heap size half of the total available RAM. Should be under 32g to avoid jvm issues. | |
| echo "cd /usr/local/elasticsearch/elasticsearch-1.5.2/ && bin/elasticsearch -d" >> /etc/rc.local |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| yum groupinstall "Development Tools" | |
| yum install kernel-devel kernel-headers dkms | |
| yum install pciutils | |
| lspci -nn | grep VGA # to check your NVIDIA product version | |
| yum update | |
| sudo sh NVIDIA-Linux-x86_64-340.32.run --kernel-source-path /usr/src/kernels/3.10.0-123.6.3.el7.x86_64 | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Installing NVIDIA Official Driver | |
| yum groupinstall "Development Tools" | |
| yum install kernel-devel kernel-headers dkms | |
| yum install pciutils | |
| lspci -nn | grep VGA # to check your NVIDIA product version | |
| yum update # For kernel source etc | |
| sudo sh NVIDIA-Linux-x86_64-340.32.run --kernel-source-path /usr/src/kernels/3.10.0-123.6.3.el7.x86_64 | |
| # NVIDIA Driver got installed successfully! | |
| # Installing NICE DCV |