Skip to content

Instantly share code, notes, and snippets.

Sokratis Galiatsis sokratisg

Block or report user

Report or block sokratisg

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
dschaaff / notifySlack.groovy
Created Feb 9, 2018
jenkins pipeline library for slack notifications with nice formatting
View notifySlack.groovy
#!/usr/bin/env groovy
* notify slack and set message based on build status
import net.sf.json.JSONArray;
import net.sf.json.JSONObject;
import hudson.tasks.test.AbstractTestResultAction;
import hudson.model.Actionable;
pbabics /
Created Nov 11, 2016
Manual garbage collector for gitlab registry, it removes old revisions that are not referenced by any tag
GITLAB_CTL_COMMAND=`which gitlab-ctl`
Eyjafjallajokull /
Last active Dec 12, 2019
AWS EBS - Find unused snapshots

This script can help you find and remove unused AWS snapshots and volumes.

There is hardcoded list of regions that it searches, adjust the value to suit your needs.

Use snapshot-report to generate report.csv containing information about all snapshots. snapshot-cleanup lets you interactively delete snapshot if it finds it is referencing unexisting resources.

./ --help
mrw34 / gist:b12531d1a8df25f6c170
Last active Jul 29, 2019
Trello JSON to CSV conversion using jq
View gist:b12531d1a8df25f6c170
jq -r '["List", "Card"], ((reduce .lists[] as $list ({}; .[$] = $ as $lists | .cards[] | select(.closed != true) | [$lists[.idList],.name]) | @csv' <nw3RUeLl.json
ndemengel /
Last active Aug 24, 2016 — forked from jjmaestro/
Add weeks support to jjmaestro's script
#!/usr/bin/env python
# -*- coding: utf-8 -*-
def archive_to_bytes(archive):
def to_seconds(s):
's': 1,
'm': 1 * 60,
'h': 1 * 60 * 60,

G1GC v.s. CMS for Cassandra 2.0

Many people have asked me about using the G1 garbage collector with Cassandra. Since most of my customers are running 2.0 in production the test is with 2.0 for now. Once I script it up I'll re-run the numbers with 2.1.

I also need to re-test with Java 7 and the Oracle JDKs.


Gromph / gist:5f4db73b0f38775bc2f0
Last active Sep 9, 2019
Install Cabot on CentOS7 using uwsgi, nginx, and mysql
View gist:5f4db73b0f38775bc2f0
The Cabot quick start instructions are for auto installing on ubuntu using fabric, gunicorn, postgres.
I wanted to install manually on CentOS 7 running with uwsgi, nginx, mysql, and use our own mail server for
alerts instead of Amazon SES
These are my notes on how I did that.
These notes aren't a complete walkthrough, and a few steps may be missing or wrong, but I thought they might
be helpful anyways.
1. adduser www
passwd www
zmwangx / Postfix: sender-dependent SASL
Last active Oct 1, 2019
Postfix: sender-dependent SASL authentication — relay to multiple SMTP hosts, or relay to the same host but authenticate as different users (e.g., two Gmail accounts)
View Postfix: sender-dependent SASL

This is a sequel to "Postfix: relay to authenticated SMTP".

I would like to send mail from two different Gmail accounts using Postfix. Here is the relevant section in the Postfix documentation: Configuring Sender-Dependent SASL authentication.

As a concrete example, here's how to set up two Gmail accounts (only relevant sections of the config files are listed below):

    # sender-dependent sasl authentication
    smtp_sender_dependent_authentication = yes
    sender_dependent_relayhost_maps = hash:/etc/postfix/sender_relay
View haproxy.cfg
log logstash local0 #Change logstash to your naming
chroot /var/lib/haproxy
user haproxy
group haproxy
maxconn 4000
jkreps / benchmark-commands.txt
Last active Nov 25, 2019
Kafka Benchmark Commands
View benchmark-commands.txt
bin/ --zookeeper --create --topic test-rep-one --partitions 6 --replication-factor 1
bin/ --zookeeper --create --topic test --partitions 6 --replication-factor 3
Single thread, no replication
bin/ test7 50000000 100 -1 acks=1 buffer.memory=67108864 batch.size=8196
You can’t perform that action at this time.