Skip to content

Instantly share code, notes, and snippets.

VERSION=0.20.6
sudo apt-get update
sudo apt-get install openjdk-6-jdk
wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-$VERSION.deb
sudo dpkg -i elasticsearch-$VERSION.deb
# be sure you add "action.disable_delete_all_indices" : true to the config!!
zooklubba@Ubuntu-1404-trusty-64-minimal:~$ sudo apt-get install docker.io
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
aufs-tools cgroup-lite
The following NEW packages will be installed:
aufs-tools cgroup-lite docker.io
0 upgraded, 3 newly installed, 0 to remove and 3 not upgraded.
Need to get 0 B/3822 kB of archives.
@davols
davols / Apparmor bug
Last active May 28, 2019 18:11
AppArmor bug
sudo apt-get install apparmor
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
apparmor-docs apparmor-utils
The following NEW packages will be installed:
apparmor
0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded.
Need to get 0 B/319 kB of archives.
@davols
davols / arenamer.py
Created March 6, 2016 10:56
Script to rename files (graphics) from iOS format to Android dpi folders.
#!/usr/bin/python
# -*- coding: utf-8 -*-
import argparse
import os
import shutil
'''
call with a path that contains files that are named
according to iOS format. Renames and moves the files
@davols
davols / PhonecallReceiver.java
Created October 5, 2017 08:48 — forked from ftvs/PhonecallReceiver.java
Detecting an incoming call coming to an Android device. Remember to set the appropriate permissions in AndroidManifest.xml as suggested in the Stackoverflow link. Usage example in comments. Source: http://stackoverflow.com/a/15564021/264619 Explanation: http://gabesechansoftware.com/is-the-phone-ringing/#more-8
package com.gabesechan.android.reusable.receivers;
import java.util.Date;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.telephony.TelephonyManager;
public abstract class PhonecallReceiver extends BroadcastReceiver {