Skip to content

Instantly share code, notes, and snippets.

iapilgrim pilgrim2go

Block or report user

Report or block pilgrim2go

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
pilgrim2go / graphUndirected.ipynb
Created Apr 8, 2019 — forked from anirudhjayaraman/graphUndirected.ipynb
Python Implementation of Undirected Graphs (Adjacency List and Adjacency Matrix)
View graphUndirected.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
pilgrim2go /
Created Mar 6, 2019 — forked from robertsosinski/
DataDog script for collecting PostgreSQL stats
# Create the datadog user with select only permissions:
# CREATE USER datadog WITH PASSWORD '<complex_password>';
# Grant select permissions on a table or view that you want to monitor:
# GRANT SELECT ON <schema>.<table> TO datadog;
# Grant permissions for a specific column on a table or view that you want to monitor:
# GRANT SELECT (id, name) ON <schema>.<table> TO datadog;
# Let non-superusers look at pg_stat_activity in a read-only fashon.
pilgrim2go / buildspec.yml
Created Oct 16, 2018 — forked from QuinnyPig/buildspec.yml
The buildspec.yml that deploys Last Week in AWS.
View buildspec.yml
version: 0.2
- echo Entered the install phase...
- pip install -r requirements.txt
- echo Entered the build phase...
pilgrim2go /
Created Sep 26, 2018 — forked from rcillo/
This gist contains code that attaches an ENI to a running EC2 instance and configures the network accordingly
# -*- coding: utf-8 -*-\
The MIT License (MIT)
Copyright (c) 2015 Zalando SE
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
pilgrim2go /
Created Sep 20, 2018 — forked from SQLadmin/
AWS Athena create auto partition for CloudTrail logs on Daily Basis
# Lambda function to create partition for Cloudtrail log on daily basis.
# You need to schedule it in AWS Lambda.
AWS Athena Create Partitions Automatically
Version 1.0
Author: SqlAdmin
pilgrim2go / .gitlab-ci.yml
Created Sep 10, 2018 — forked from foklepoint/.gitlab-ci.yml
Build and Push images to GCP Container Registry with Gitlab CI
View .gitlab-ci.yml
image: docker:latest
# When using dind, it's wise to use the overlayfs driver for
# improved performance.
IMAGE_NAME: image_id
pilgrim2go /
Created Aug 30, 2018 — forked from fnzv/
Parsing HAProxy Logs with goaccess
goaccess -f haproxy.log --log-format='%^ %^ %^:%^:%^ %^ %^[%^]: %h:%^ [%d:%t.%^] %^ %^ %^/%^/%^/%^/%L %s %b %^ %^ %^ %^/%^/%^/%^/%^ %^/%^ "%r"' --date-format='%d/%b/%Y' --time-format='%H:%M:%S' -q
pilgrim2go /
Created Aug 3, 2018 — forked from sa-jbrooks/
Security Group Cleanup using boto3
#!/usr/bin/env python
import boto3
import argparse
def lookup_by_id(sgid):
sg = ec2.get_all_security_groups(group_ids=sgid)
return sg[0].name
pilgrim2go /
Created Jul 19, 2018
Extract entities using NLTK
import nltk
def extract_entity_names(t):
entity_names = []
if hasattr(t, 'label') and t.label:
if t.label() == 'NE':
entity_names.append(' '.join([child[0] for child in t]))
pilgrim2go /
Created Jun 29, 2018
Docker IP and Container Name
# One line command to list container name with its IP
# From
for i in `docker ps -q`; do echo $i; echo " : "; docker inspect $i | grep -i ipaddress | grep -v null | cut -d ':' -f 2; done
You can’t perform that action at this time.