Skip to content

Instantly share code, notes, and snippets.

View sudheendrach's full-sized avatar

Sudheendra Chilappagari sudheendrach

View GitHub Profile
/**
* @param {SpecTrack} event The track event
* @param {Object.<string, any>} settings Custom settings
* @return void
*/
async function onTrack(event, settings) {
if (event['event'] === settings.eventName) {
let itemPurchased =
event['properties']['products'][0]['brand'] +
' ' +
@sudheendrach
sudheendrach / server-security.md
Last active August 29, 2015 14:05
Configuring IPTables and Fail2Ban

Installing fail2ban

apt-get install fail2ban

The fail2ban service keeps its configuration files in the /etc/fail2ban directory. There is a file with defaults called jail.conf.

cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.local

Installing nginx, sendmail and iptables for more security apt-get install nginx sendmail iptables-persistent

@sudheendrach
sudheendrach / timezone.md
Last active August 29, 2015 14:05
Changing server timezone

To check your server's current timezone

root@projectx:/sites# date +%Z
EDT

To change

root@projectx:/sites# dpkg-reconfigure tzdata

Asks to select your country/continent first and then city