Skip to content

Instantly share code, notes, and snippets.

View addingama's full-sized avatar

Addin Gama Bertaqwa addingama

View GitHub Profile
@addingama
addingama / SalesCountry.md
Last active April 20, 2021 03:42
Panduan Running WordCount.java pada Hadoop
@addingama
addingama / hadoop-hdfs-notes.md
Last active August 7, 2019 07:07
Hadoop HDFS Notes

Hadoop Notes

HDFS

Commands

  • Check hdfs directory content on root directory /
@addingama
addingama / hadoop-multinode.md
Last active December 11, 2023 01:38
Steps to install Hadoop 3.2.0 to Ubuntu Server

Hadoop 3.2.0 Multi Node Configuration

Please make sure you already have working hadoop installation on your first VM. If not please follow this installation guide

We will make 1 master and 1 slave hadoop cluster. We can create another VM by cloning existing VM.

Clone VM to create another node

  • Open Virtual Box and make sure the VM not running
{
"font_size": 16,
"translate_tabs_to_spaces": true,
"indent_to_bracket": true,
"highlight_line": true,
"trim_trailing_white_space_on_save": true,
"ensure_newline_at_eof_on_save": true,
"shift_tab_unindent": true,
"copy_with_empty_selection": false,
"drag_text": false,
@addingama
addingama / vhost-laravel.conf
Created April 10, 2016 10:56
Sample vhost for laravel
<VirtualHost *:80>
ServerName domain.com
ServerAlias domain.com
ServerAdmin support@domain.com
DocumentRoot /home/deploy/domain-dir/public
<Directory /home/deploy/domain-dir/public>
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
@addingama
addingama / ArduinoCustomHeader
Created June 12, 2015 10:28
CUstom header untuk menyembunyikan api key pada header
#include <SPI.h>
#include <Ethernet.h>
#include <PubSubClient.h>
// Update these with values suitable for your network.
byte mac[] = { 0xDE, 0xED, 0xBA, 0xFE, 0xFE, 0xED };
byte ip[] = { 192, 168, 137, 2 };
byte dns2[] = {8, 8, 8, 8};
byte gateway[] = { 192, 168, 137, 1 };
String api_key = "API_KEY";
@addingama
addingama / ESP8266 With Modified Header
Created June 12, 2015 06:57
ESP8266 With Modified Header
-- format program untuk konek ke geeknesia.com
conn=net.createConnection(net.TCP, 0)
conn:connect(3000,'54.179.149.183')
conn:send("GET /api/data?attributes={\"motion\":\""..pinState.."\"}\r\n\r\n")
conn:send("api_key : "..API_KEY.."\r\n\r\n")
end
// WpUser.php model
<?php
App::uses('AppModel', 'Model');
require(DIRNAME(ROOT).WP_DIR.'wp-load.php');
class WpUser extends AppModel {
}
// User controller: login
public function login() {
// ini di dalam adapter. class view holder di buat jadi inner class
static class ViewHolder {
TextView name;
TextView meter;
TextView statusMeter;
TextView statusSegel;
TextView statusData;
TextView id;
ImageView fotoMeter;
LinearLayout btn_delete;
vagrant@vagrant-ubuntu-trusty-64:/var/www/vagrant$ sudo npm install -g n n s
table
npm http GET https://registry.npmjs.org/n
npm http GET https://registry.npmjs.org/stable
npm http 304 https://registry.npmjs.org/n
npm http 304 https://registry.npmjs.org/stable
/usr/local/bin/n -> /usr/local/lib/node_modules/n/bin/n
stable@0.1.5 /usr/local/lib/node_modules/stable
n@1.2.13 /usr/local/lib/node_modules/n