Skip to content

Instantly share code, notes, and snippets.

View rgodishela's full-sized avatar

Ramesh Godishela rgodishela

  • https://github.com/salesforce
  • Hyderabad, India
View GitHub Profile
Vagrant Cheatsheet
box = manages boxes: installation, removal, etc.
connect = connect to a remotely shared Vagrant environment
destroy = stops and deletes all traces of the vagrant machine
docker-logs = outputs the logs from the Docker container
docker-run = run a one-off command in the context of a container
global-status = outputs status Vagrant environments for this user
halt = stops the vagrant machine
help= shows the help for a subcommand
init = initializes a new Vagrant environment by creating a Vagrantfile
Jenkins
Installing Jenkins
sudo wget -q -O - http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key | sudo apt-key add -
sudo sh -c 'echo deb http://pkg.jenkins-ci.org/debian binary/ > /etc/apt/sources.list.d/jenkins.list’
sudo apt-get update
sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install git
sudo apt-get install jenkins
Docker Tips and Tricks
Docker Tutorials
Getting Started:Installation
Ubuntu :
1. Log into your Ubuntu installation as a user with sudo privileges.
2. Verify that you have wget installed.
$ which wget
3. If wget isn’t installed, install it after updating your manager:
$ sudo apt-get update $ sudo apt-get install wget
@rgodishela
rgodishela / Docker Cheatsheet
Last active April 23, 2017 16:34
Docker Cheatsheet
DOCKER OPERATIONS
CONTAINER LOGGING
*Container PID1 process output can be viewed with docker logs command.
*will show whatever PID1 writes to stdout
View the output of the containers PID1 process
#docker logs <container name>
View and follow the output
@rgodishela
rgodishela / Datadog troubleshooting
Last active June 8, 2017 05:37
Datadog troubleshooting
Datadog Troubleshooting
Start: sudo /etc/init.d/datadog-agent start
Stop: sudo /etc/init.d/datadog-agent stop
Restart: sudo /etc/init.d/datadog-agent restart
Status: sudo /etc/init.d/datadog-agent status
Info: sudo /etc/init.d/datadog-agent info -v
ps aux |grep datado[g]
ls -l /opt/datadog-agent/run/dogstatsd.pid
The configuration file for the Agent is located at /etc/dd-agent/datadog.conf
@rgodishela
rgodishela / ansible windows configuration
Created April 23, 2017 16:23
ansible windows configuration
==> In Controller Machine
rpm -ivh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum install ansible vim git python-pip -y
pip install "pywinrm>=0.1.1"
==> In Remote Machine
https://raw.githubusercontent.com/ansible/ansible/devel/examples/scripts/ConfigureRemotingForAnsible.ps1
Set-ExecutionPolicy -Scope LocalMachine Unrestricted -Force
==> In WindowsHosts File
@rgodishela
rgodishela / doctl
Created April 23, 2017 16:19
Digital Ocean Command Line Interface
DOCTL
Installation
Option 1 – Download a Release from GitHub
Visit the Releases page for the doctl GitHub project.
https://github.com/digitalocean/doctl/releases
tar xf ~/doctl-1.4.0-linux-amd64.tar.gz
sudo mv ~/doctl /usr/local/bin
Configure
git config --global push.default matching
git config --global user.email "iamrameshjonathan@gmail.com"
git config --global user.name "Ramesh Godishela"
@rgodishela
rgodishela / OpenConnect Installation
Created April 23, 2017 16:12
OpenConnect Installation
OpenConnect Installation:
Go to OpenConnect Downloads Page, Right Click on Latest release to copy the link location.
Download the package into your machine,
wget ftp://ftp.infradead.org/pub/openconnect/openconnect-7.06.tar.gz
Untar the file, tar -xvf openconnect-7.06.tar.gz
Go into the directory, cd openconnect-7.06
Create VPNC directory under /etc, mkdir -vp /etc/vpnc
vim /etc/vpnc/vpnc-script
copy the content from http://git.infradead.org/users/dwmw2/vpnc-scripts.git/blob_plain/HEAD:/vpnc-script
@rgodishela
rgodishela / Deployments Terminology
Created April 23, 2017 16:10
Deployments Terminology
Blue-green deployment is a release technique that reduces downtime and risk by running two identical production environments called Blue and Green.
At any time, only one of the environments is live, with the live environment serving all production traffic. For this example, Blue is currently live and Green is idle.
As you prepare a new release of your software, deployment and the final stage of testing takes place in the environment that is not live: in this example, Green. Once you have deployed and fully tested the software in Green, you switch the router so all incoming requests now go to Green instead of Blue. Green is now live, and Blue is idle.
This technique can eliminate downtime due to application deployment. In addition, blue-green deployment reduces risk: if something unexpected happens with your new release on Green, you can immediately roll back to the last version by switching back to Blue.
BROWNFIELD DEPLOYMENTS