Skip to content

Instantly share code, notes, and snippets.

Achmad Nasirudin Sandi achmadns

Block or report user

Report or block achmadns

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
achmadns /
Created Oct 9, 2017
Show retention policies on InfluxDB through CLI
for x in `influx -execute 'show databases' | grep -v -e ^name -e --- -e ^_internal`;do printf "RETENTION POLICIES ON $x \n"; influx -execute "SHOW RETENTION POLICIES ON $x";done
achmadns /
Created May 12, 2017
Print and Iterate Shell Script Parameters
: '
$ ./ 4 2 3 4 5 6
4 2 3 4 5 6
View graph-for-identity-access-management.adoc

Entitlements and Access Control Management

This interactive Neo4j graph tutorial covers entitlements and access control scenarios.

# assuming we want forward message published to exchange ams.* from broker A to broker B
# there is no any configuration update on broker A except credential needed by B to connect the upstream
# see for details
# do these on broker B
# enable rabbitmq federation plugin
rabbitmq-plugins enable rabbitmq_federation
# these action should be run with sudo level
# activate management plugin first
rabbitmq-plugins enable rabbitmq_management
# restart the rabbitmq-server
service rabbitmq-server restart
# download the rabbitmqadmin script locally
sudo apt-get install -y leafpad vim-gnome scribes gedit cream scite geany bluefish kwrite nedit tea
sudo apt-get install -y lyx
achmadns / jvm-setting.txt
Created Nov 19, 2015
Common jvm setting
View jvm-setting.txt
Proxy setting through jvm opts
-Dhttp.proxyHost= -Dhttp.proxyPort=3128 -Dhttp.nonProxyHosts=localhost|
achmadns /
Last active Nov 17, 2015
Git related command
# push current branch into origin
git push origin `git status | grep branch | awk '{print $3}'`
# add all modified files
git status | grep modified | sed -re 's:^(.+\:)(.+):\2:' | xargs git add && git status
# list all project under specific group and grep the ssh url
curl --insecure -s "$GIT_TOKEN" | jq '.projects[].ssh_url_to_repo'
achmadns / sinopia-private-bower.json
Created Oct 10, 2015
PM2 config example for Sinopia and Private Bower.
View sinopia-private-bower.json
"apps" : [{
"name" : "sinopia",
"script" : "/home/achmad/.nvm/versions/node/v0.12.0/bin/sinopia",
"args" : [],
"watch" : false,
"node_args" : "",
"merge_logs" : true,
"env": {
# simple example
java -Dcom.sun.akuma.Daemon=daemonized -jar /app/softwares/jenkins-1.613.war --daemon
# tuned jvm settings
nohup /app/.jenv/candidates/java/1.8.0_60/bin/java -Xms3G -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:-OmitStackTraceInFastThrow -Dcom.sun.akuma.Daemon=daemonized -jar /app/softwares/jenkins-1.613.war --daemon &> /dev/null &
You can’t perform that action at this time.