Skip to content

Instantly share code, notes, and snippets.

@omarsar
omarsar / kibana_cheat_sheet.md
Last active October 23, 2018 06:46
Kibana Dev Tools Cheat Sheet

Kibana Cheat Sheet

Some helpful commands for Kibana using the Dev Tools feature:

GET _all

GET twitter/tweet/_count

GET my_index
@nikallass
nikallass / Kali 2017.1 x64, Docker-ce Install script
Last active January 3, 2024 11:12
Kali 2017.1 x64, Docker-ce Install script
#!/bin/bash
# update apt-get
export DEBIAN_FRONTEND="noninteractive"
sudo apt-get update
# remove previously installed Docker
sudo apt-get remove docker docker-engine docker.io* lxc-docker*
# install dependencies 4 cert
@ssaunier
ssaunier / sidekiq.config
Created September 24, 2015 09:30
Running Sidekiq on AWS Elastic Beanstalk (Put that file in `.ebextensions` folder)
# Sidekiq interaction and startup script
commands:
create_post_dir:
command: "mkdir -p /opt/elasticbeanstalk/hooks/appdeploy/post"
ignoreErrors: true
files:
"/opt/elasticbeanstalk/hooks/appdeploy/post/50_restart_sidekiq.sh":
mode: "000755"
owner: root
group: root
@Chocksy
Chocksy / searchkick_reindex_resume.rb
Last active September 5, 2023 06:46
Searchkick reindex with resume
namespace :searchkick do
desc "maybe reindex without running out of memory?"
task :altindex, [:start_index, :batch_size, :new_index_name] => :environment do |t, args|
ActiveRecord::Base.logger = Logger.new(STDOUT)
count = Item.count
start = args[:start_index].to_i || 0
batch_size = args[:batch_size].to_i || 1000
# we create a new index or take one already present
if args[:new_index_name]
@KunihikoKido
KunihikoKido / japanese_template.json
Last active April 2, 2020 04:12
Elasticsearch - Dynamic Mapping for Japanese
{
"japanese_template": {
"template": "*ja",
"settings": {
"analysis": {
"filter": {
"romaji": {
"type": "kuromoji_readingform",
"use_romaji": true
}
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active June 17, 2024 23:43
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@jeffkreeftmeijer
jeffkreeftmeijer / 1.png
Last active November 3, 2023 00:56
Ruby image diff
1.png