Skip to content

Instantly share code, notes, and snippets.

View yesoreyeram's full-sized avatar

Sriram yesoreyeram

View GitHub Profile
@yesoreyeram
yesoreyeram / mass-aggregation-change.sh
Created September 12, 2016 16:51 — forked from kirbysayshi/mass-aggregation-change.sh
quick examples of how to change many many wsp (graphite/whisper) files settings
for f in $(find $1 -iname "*.wsp"); do
if [ -a $f ];
then /opt/graphite/bin/whisper-set-aggregation-method.py $f max;
fi;
done
@yesoreyeram
yesoreyeram / .gitignore
Created February 28, 2017 11:52 — forked from karmi/.gitignore
Example Nginx configurations for Elasticsearch (https://www.elastic.co/blog/playing-http-tricks-nginx)
nginx/
!nginx/.gitkeep
!nginx/logs/.gitkeep
src/
tmp/
@yesoreyeram
yesoreyeram / install_graphite_ubuntu.txt
Last active March 8, 2017 23:18
Graphite DB with apache setup for Ubuntu 16 LTS
######################################
# Update and install requied packages
######################################
sudo apt-get update && sudo apt-get upgrade --yes
sudo apt-get install build-essential graphite-web graphite-carbon python-dev apache2 libapache2-mod-wsgi libpq-dev python-psycopg2 --yes
######################################
# Setup Carbon
######################################
@yesoreyeram
yesoreyeram / tips.md
Last active August 7, 2017 15:39
Ubuntu

Add user

sudo adduser username

user to sudo

sudo usermod -aG sudo username

sudo auto password

@yesoreyeram
yesoreyeram / README.md
Last active March 8, 2017 10:07
Docker Compose file for clustered graphite and grafana implementation.

This implementation shared a common local folder for whisper data

@yesoreyeram
yesoreyeram / docker-installation-ubuntu.txt
Last active March 2, 2018 23:28
Docker installation step for ubuntu 16
# Extract from the following sites
# https://docs.docker.com/engine/installation/linux/ubuntu/
# https://docs.docker.com/compose/install/
# https://docs.docker.com/machine/install-machine/
Install docker on Ubuntu
=========================
sudo apt-get update
@yesoreyeram
yesoreyeram / script.sh
Last active July 13, 2017 16:56
Mono Installation for Ubuntu & Octopus Deploy
# update hostname in hosts file (Will help to fix “sudo: unable to resolve hostname” issue while installing)
echo $(hostname -I | cut -d\ -f1) $(hostname) | sudo tee -a /etc/hosts
# Install mono (required for octopus to connect)
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb http://download.mono-project.com/repo/ubuntu xenial main" | sudo tee /etc/apt/sources.list.d/mono-official.list
sudo apt-get update
sudo apt-get install mono-devel --allow-unauthenticated -–yes
#!/bin/bash
# update hostname in hosts file (Will help to fix “sudo: unable to resolve hostname” issue while installing)
echo $(hostname -I | cut -d\ -f1) $(hostname) | tee -a /etc/hosts
# Install mono (required for octopus to connect)
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF
echo "deb http://download.mono-project.com/repo/ubuntu xenial main" | tee /etc/apt/sources.list.d/mono-official.list
apt-get update
apt-get install mono-devel --yes --allow-unauthenticated
exit 0
@yesoreyeram
yesoreyeram / DockerFile
Last active July 25, 2017 15:49
Ubuntu Docker file with OMI, DSC and SSH
FROM ubuntu:16.04
MAINTAINER Sriramajeyam Sugumaran "http://sriramajeyam.com"
SHELL ["/bin/sh", "-c"]
RUN apt-get update -y
RUN apt-get install -y openssh-server rpm libpam0g-dev libkrb5-dev wget openssl python libcurl4-gnutls-dev cron sudo nano
RUN mkdir /tmp/installation
ADD ./packages/packages-microsoft-prod.deb /tmp/installation/
ADD ./packages/omi-1.1.0.ssl_100.x64.deb /tmp/installation/
@yesoreyeram
yesoreyeram / index.js
Last active August 3, 2017 10:40
Configuration Manager
var fs = require('fs');
var _ = require("lodash");
var ini = require('ini');
var baseConfig, overrideConfig;
var replaceIniConfig = function(configuration) {
try {
fs.readFile(configuration.base, function(err, content) {
if (err) {